From 27f7b6318b795ebfc638a58dd3d2d691cbf6c261 Mon Sep 17 00:00:00 2001 From: Hari <73809867+harivansh-afk@users.noreply.github.com> Date: Wed, 8 Apr 2026 12:30:04 -0400 Subject: [PATCH] feat: guestOS docker config (#3) --- Dockerfile | 62 +++++++ README.md | 49 ++++++ defaults/.bashrc | 15 ++ defaults/.profile | 3 + defaults/.zshrc | 42 +++++ microagent-desktop-session.sh | 23 +++ microagent-init.sh | 40 +++++ microagent-network-up.sh | 48 ++++++ sshd_config | 22 +++ terminfo/xterm-ghostty.terminfo | 81 ++++++++++ terminfo/xterm-kitty.terminfo | 275 ++++++++++++++++++++++++++++++++ 11 files changed, 660 insertions(+) create mode 100644 Dockerfile create mode 100644 README.md create mode 100644 defaults/.bashrc create mode 100644 defaults/.profile create mode 100644 defaults/.zshrc create mode 100644 microagent-desktop-session.sh create mode 100644 microagent-init.sh create mode 100644 microagent-network-up.sh create mode 100644 sshd_config create mode 100644 terminfo/xterm-ghostty.terminfo create mode 100644 terminfo/xterm-kitty.terminfo diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..cd90de7 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,62 @@ +FROM public.ecr.aws/docker/library/ubuntu:24.04 + +SHELL ["/bin/bash", "-o", "pipefail", "-c"] + +ENV DEBIAN_FRONTEND=noninteractive + +RUN apt-get update && apt-get install -y --no-install-recommends \ + ca-certificates \ + curl \ + dbus-x11 \ + eza \ + fonts-dejavu-core \ + git \ + iproute2 \ + jitterentropy-rngd \ + net-tools \ + ncurses-bin \ + novnc \ + openbox \ + openssh-server \ + sudo \ + zsh \ + zsh-autosuggestions \ + zsh-syntax-highlighting \ + websockify \ + x11-utils \ + x11-xserver-utils \ + x11vnc \ + xauth \ + xterm \ + xvfb \ + && rm -rf /var/lib/apt/lists/* + +RUN useradd --create-home --shell /bin/bash node \ + && passwd -d node \ + && mkdir -p /home/node/.ssh \ + && chown -R node:node /home/node \ + && usermod -aG sudo node \ + && printf 'node ALL=(ALL) NOPASSWD:ALL\n' >/etc/sudoers.d/node \ + && chmod 440 /etc/sudoers.d/node + +COPY docker/guest/sshd_config /etc/ssh/sshd_config +COPY docker/guest/microagent-init.sh /usr/local/bin/microagent-init +COPY docker/guest/microagent-desktop-session.sh /usr/local/bin/microagent-desktop-session +COPY docker/guest/microagent-network-up.sh /usr/local/bin/microagent-network-up +COPY docker/guest/defaults/.zshrc /home/node/.zshrc +COPY docker/guest/defaults/.bashrc /home/node/.bashrc +COPY docker/guest/defaults/.profile /home/node/.profile +COPY docker/guest/terminfo/xterm-ghostty.terminfo /tmp/xterm-ghostty.terminfo +COPY docker/guest/terminfo/xterm-kitty.terminfo /tmp/xterm-kitty.terminfo + +RUN chmod 755 /usr/local/bin/microagent-init /usr/local/bin/microagent-desktop-session /usr/local/bin/microagent-network-up \ + && chown node:node /home/node/.zshrc /home/node/.bashrc /home/node/.profile \ + && usermod -s /usr/bin/zsh node \ + && install -d /opt/zsh/pure \ + && curl -fsSL https://raw.githubusercontent.com/sindresorhus/pure/v1.27.0/pure.zsh -o /opt/zsh/pure/pure.zsh \ + && curl -fsSL https://raw.githubusercontent.com/sindresorhus/pure/v1.27.0/async.zsh -o /opt/zsh/pure/async.zsh \ + && tic -x -o /usr/share/terminfo /tmp/xterm-ghostty.terminfo \ + && tic -x -o /usr/share/terminfo /tmp/xterm-kitty.terminfo \ + && rm -f /tmp/xterm-ghostty.terminfo /tmp/xterm-kitty.terminfo + +CMD ["/usr/local/bin/microagent-init"] diff --git a/README.md b/README.md new file mode 100644 index 0000000..f98e75c --- /dev/null +++ b/README.md @@ -0,0 +1,49 @@ +# Guest Image + +This directory is a selective extraction point from the old +`agentcomputer/docker/computer` guest. + +It is intentionally not a wholesale copy. + +The first version only targets the minimal `microagentcomputer` guest contract: + +- SSH on `2222` +- browser desktop access on `6080` +- user root access via `sudo` + +The goal here is to keep the guest small, explicit, and easy to reason about, +while still reusing the proven parts of the old image where they are actually +useful. + +## Import Rules + +Keep: + +- SSH server configuration +- desktop packages needed for a visible session +- `x11vnc` +- `noVNC` and `websockify` +- entropy support + +Do not import yet: + +- sandbox-agent +- agent-ui +- workspace/runtime shims +- old AgentComputer bootstrap services +- old multi-port service surface + +## Expected Ports + +- `2222` for SSH +- `6080` for browser VNC + +## Runtime Shape + +The guest is expected to boot from a normal Firecracker kernel plus rootfs and +start through a small custom init script rather than the older AgentComputer +runtime stack. That PID 1 helper is responsible for: + +- bringing up guest networking +- starting SSH and desktop services +- staying alive as the runtime supervisor for the VM diff --git a/defaults/.bashrc b/defaults/.bashrc new file mode 100644 index 0000000..80d7a17 --- /dev/null +++ b/defaults/.bashrc @@ -0,0 +1,15 @@ +case $- in + *i*) ;; + *) return ;; +esac + +computer_prompt_name() { + printf '%s' "${COMPUTER_NAME:-${COMPUTER_HANDLE:-microagentcomputer}}" +} + +alias ls='eza --group-directories-first --icons=auto' +alias la='eza -a --group-directories-first --icons=auto' +alias ll='eza -lah --git --group-directories-first --icons=auto' +alias lt='eza --tree --level=2 --group-directories-first --icons=auto' + +export PS1="\[\033[01;32m\]\$(computer_prompt_name)\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ " diff --git a/defaults/.profile b/defaults/.profile new file mode 100644 index 0000000..09a5fb9 --- /dev/null +++ b/defaults/.profile @@ -0,0 +1,3 @@ +if [ -n "${BASH_VERSION:-}" ] && [ -f "$HOME/.bashrc" ]; then + . "$HOME/.bashrc" +fi diff --git a/defaults/.zshrc b/defaults/.zshrc new file mode 100644 index 0000000..a2ddb15 --- /dev/null +++ b/defaults/.zshrc @@ -0,0 +1,42 @@ +HISTFILE="${HOME}/.zsh_history" +HISTSIZE=50000 +SAVEHIST=50000 + +setopt append_history +setopt extended_history +setopt hist_ignore_all_dups +setopt hist_reduce_blanks +setopt share_history + +bindkey -v + +computer_prompt_name() { + printf '%s' "${COMPUTER_NAME:-${COMPUTER_HANDLE:-microagentcomputer}}" +} + +alias ls='eza --group-directories-first --icons=auto' +alias la='eza -a --group-directories-first --icons=auto' +alias ll='eza -lah --git --group-directories-first --icons=auto' +alias lt='eza --tree --level=2 --group-directories-first --icons=auto' + +if [ -r /usr/share/zsh-autosuggestions/zsh-autosuggestions.zsh ]; then + source /usr/share/zsh-autosuggestions/zsh-autosuggestions.zsh +fi + +if [ -r /usr/share/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh ]; then + source /usr/share/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh +fi + +if [ -r /opt/zsh/pure/pure.zsh ] && [ -r /opt/zsh/pure/async.zsh ]; then + fpath=(/opt/zsh/pure $fpath) + autoload -Uz promptinit + promptinit + if prompt pure >/dev/null 2>&1; then + zstyle ':prompt:pure:path' color blue + PROMPT='%F{green}$(computer_prompt_name)%f ${PROMPT}' + else + PROMPT='%F{green}$(computer_prompt_name)%f %F{blue}%~%f %# ' + fi +else + PROMPT='%F{green}$(computer_prompt_name)%f %F{blue}%~%f %# ' +fi diff --git a/microagent-desktop-session.sh b/microagent-desktop-session.sh new file mode 100644 index 0000000..8bc0537 --- /dev/null +++ b/microagent-desktop-session.sh @@ -0,0 +1,23 @@ +#!/usr/bin/env bash +set -euo pipefail + +export DISPLAY=:0 + +Xvfb "$DISPLAY" -screen 0 1280x800x24 >/tmp/xvfb.log 2>&1 & +XVFB_PID=$! + +for _ in $(seq 1 50); do + if xdpyinfo -display "$DISPLAY" >/dev/null 2>&1; then + break + fi + sleep 0.1 +done + +runuser -u node -- env DISPLAY="$DISPLAY" openbox >/tmp/openbox.log 2>&1 & +runuser -u node -- env DISPLAY="$DISPLAY" xterm -fa Monospace -fs 12 >/tmp/xterm.log 2>&1 & + +x11vnc -display "$DISPLAY" -rfbport 5900 -forever -shared -nopw >/tmp/x11vnc.log 2>&1 & +websockify --web=/usr/share/novnc 6080 localhost:5900 >/tmp/websockify.log 2>&1 & + +trap 'kill $XVFB_PID || true; kill 0 || true; exit 0' INT TERM +wait -n diff --git a/microagent-init.sh b/microagent-init.sh new file mode 100644 index 0000000..527322e --- /dev/null +++ b/microagent-init.sh @@ -0,0 +1,40 @@ +#!/usr/bin/env bash +set -euo pipefail + +mountpoint -q /proc || mount -t proc proc /proc +mountpoint -q /sys || mount -t sysfs sysfs /sys +mountpoint -q /dev || mount -t devtmpfs devtmpfs /dev +mountpoint -q /run || mount -t tmpfs tmpfs /run + +mkdir -p /tmp /var/tmp /run/sshd /var/log +chmod 1777 /tmp /var/tmp + +# PID 1 is the guest supervisor: it brings up the minimum runtime surface and +# stays alive to keep the VM services attached to a single lifecycle root. +if ! /usr/local/bin/microagent-network-up >/var/log/network.log 2>&1; then + cat /var/log/network.log >&2 || true + exit 1 +fi + +if [ ! -f /etc/ssh/ssh_host_ed25519_key ]; then + ssh-keygen -A +fi + +if [ -f /etc/microagent/authorized_keys ]; then + install -d -m 0700 -o node -g node /home/node/.ssh + install -m 0600 -o node -g node /etc/microagent/authorized_keys /home/node/.ssh/authorized_keys +fi + +if command -v jitterentropy-rngd >/dev/null 2>&1; then + jitterentropy-rngd -v >/var/log/jitterentropy.log 2>&1 & +fi + +/usr/sbin/sshd -D -e >/var/log/sshd.log 2>&1 & +/usr/local/bin/microagent-desktop-session >/var/log/desktop.log 2>&1 & + +trap 'kill 0 || true; exit 0' INT TERM +wait -n +status=$? +kill 0 || true +wait || true +exit "$status" diff --git a/microagent-network-up.sh b/microagent-network-up.sh new file mode 100644 index 0000000..51b1952 --- /dev/null +++ b/microagent-network-up.sh @@ -0,0 +1,48 @@ +#!/usr/bin/env bash +set -euo pipefail + +wait_for_primary_interface() { + local attempt=0 + while [ "$attempt" -lt 100 ]; do + local iface + iface="$(find /sys/class/net -mindepth 1 -maxdepth 1 -printf '%f\n' | grep -v '^lo$' | head -n1 || true)" + if [ -n "$iface" ]; then + printf '%s\n' "$iface" + return 0 + fi + attempt=$((attempt + 1)) + sleep 0.1 + done + return 1 +} + +u32_to_ipv4() { + local value="$1" + printf '%d.%d.%d.%d' \ + $(((value >> 24) & 255)) \ + $(((value >> 16) & 255)) \ + $(((value >> 8) & 255)) \ + $((value & 255)) +} + +primary_iface="$(wait_for_primary_interface)" +mac="$(cat "/sys/class/net/${primary_iface}/address")" +IFS=':' read -r mac0 mac1 mac2 mac3 mac4 mac5 <<<"$mac" + +guest_u32=$((((16#${mac2}) << 24) | ((16#${mac3}) << 16) | ((16#${mac4}) << 8) | (16#${mac5}))) +gateway_u32=$((guest_u32 - 1)) + +guest_ip="$(u32_to_ipv4 "$guest_u32")" +gateway_ip="$(u32_to_ipv4 "$gateway_u32")" + +ip link set dev lo up +ip link set dev "$primary_iface" up +ip addr replace "${guest_ip}/30" dev "$primary_iface" +ip route replace default via "$gateway_ip" dev "$primary_iface" + +if [ -w /etc/resolv.conf ]; then + cat >/etc/resolv.conf <<'EOF' +nameserver 1.1.1.1 +nameserver 8.8.8.8 +EOF +fi diff --git a/sshd_config b/sshd_config new file mode 100644 index 0000000..27a7e83 --- /dev/null +++ b/sshd_config @@ -0,0 +1,22 @@ +Port 2222 +ListenAddress 0.0.0.0 + +HostKey /etc/ssh/ssh_host_ed25519_key +HostKey /etc/ssh/ssh_host_rsa_key + +PermitRootLogin no +PubkeyAuthentication yes +PasswordAuthentication no +KbdInteractiveAuthentication no +UsePAM no +AuthorizedKeysFile .ssh/authorized_keys +StrictModes no + +SyslogFacility AUTH +LogLevel INFO +PrintMotd no + +ClientAliveInterval 30 +ClientAliveCountMax 3 + +PidFile /run/sshd.pid diff --git a/terminfo/xterm-ghostty.terminfo b/terminfo/xterm-ghostty.terminfo new file mode 100644 index 0000000..20a3f3a --- /dev/null +++ b/terminfo/xterm-ghostty.terminfo @@ -0,0 +1,81 @@ +# Reconstructed via `infocmp -x xterm-ghostty` from Ghostty 1.3.0. +xterm-ghostty|ghostty|Ghostty, + am, bce, ccc, hs, km, mc5i, mir, msgr, npc, xenl, AX, Su, Tc, XT, fullkbd, + colors#256, cols#80, it#8, lines#24, pairs#32767, + acsc=++\,\,--..00``aaffgghhiijjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~, + bel=^G, blink=\E[5m, bold=\E[1m, cbt=\E[Z, civis=\E[?25l, + clear=\E[H\E[2J, cnorm=\E[?12l\E[?25h, cr=^M, + csr=\E[%i%p1%d;%p2%dr, cub=\E[%p1%dD, cub1=^H, + cud=\E[%p1%dB, cud1=^J, cuf=\E[%p1%dC, cuf1=\E[C, + cup=\E[%i%p1%d;%p2%dH, cuu=\E[%p1%dA, cuu1=\E[A, + cvvis=\E[?12;25h, dch=\E[%p1%dP, dch1=\E[P, dim=\E[2m, + dl=\E[%p1%dM, dl1=\E[M, dsl=\E]2;\007, ech=\E[%p1%dX, + ed=\E[J, el=\E[K, el1=\E[1K, flash=\E[?5h$<100/>\E[?5l, + fsl=^G, home=\E[H, hpa=\E[%i%p1%dG, ht=^I, hts=\EH, + ich=\E[%p1%d@, ich1=\E[@, il=\E[%p1%dL, il1=\E[L, ind=^J, + indn=\E[%p1%dS, + initc=\E]4;%p1%d;rgb\:%p2%{255}%*%{1000}%/%2.2X/%p3%{255}%*%{1000}%/%2.2X/%p4%{255}%*%{1000}%/%2.2X\E\\, + invis=\E[8m, kDC=\E[3;2~, kEND=\E[1;2F, kHOM=\E[1;2H, + kIC=\E[2;2~, kLFT=\E[1;2D, kNXT=\E[6;2~, kPRV=\E[5;2~, + kRIT=\E[1;2C, kbs=\177, kcbt=\E[Z, kcub1=\EOD, kcud1=\EOB, + kcuf1=\EOC, kcuu1=\EOA, kdch1=\E[3~, kend=\EOF, kent=\EOM, + kf1=\EOP, kf10=\E[21~, kf11=\E[23~, kf12=\E[24~, + kf13=\E[1;2P, kf14=\E[1;2Q, kf15=\E[1;2R, kf16=\E[1;2S, + kf17=\E[15;2~, kf18=\E[17;2~, kf19=\E[18;2~, kf2=\EOQ, + kf20=\E[19;2~, kf21=\E[20;2~, kf22=\E[21;2~, + kf23=\E[23;2~, kf24=\E[24;2~, kf25=\E[1;5P, kf26=\E[1;5Q, + kf27=\E[1;5R, kf28=\E[1;5S, kf29=\E[15;5~, kf3=\EOR, + kf30=\E[17;5~, kf31=\E[18;5~, kf32=\E[19;5~, + kf33=\E[20;5~, kf34=\E[21;5~, kf35=\E[23;5~, + kf36=\E[24;5~, kf37=\E[1;6P, kf38=\E[1;6Q, kf39=\E[1;6R, + kf4=\EOS, kf40=\E[1;6S, kf41=\E[15;6~, kf42=\E[17;6~, + kf43=\E[18;6~, kf44=\E[19;6~, kf45=\E[20;6~, + kf46=\E[21;6~, kf47=\E[23;6~, kf48=\E[24;6~, + kf49=\E[1;3P, kf5=\E[15~, kf50=\E[1;3Q, kf51=\E[1;3R, + kf52=\E[1;3S, kf53=\E[15;3~, kf54=\E[17;3~, + kf55=\E[18;3~, kf56=\E[19;3~, kf57=\E[20;3~, + kf58=\E[21;3~, kf59=\E[23;3~, kf6=\E[17~, kf60=\E[24;3~, + kf61=\E[1;4P, kf62=\E[1;4Q, kf63=\E[1;4R, kf7=\E[18~, + kf8=\E[19~, kf9=\E[20~, khome=\EOH, kich1=\E[2~, + kind=\E[1;2B, kmous=\E[<, knp=\E[6~, kpp=\E[5~, + kri=\E[1;2A, oc=\E]104\007, op=\E[39;49m, rc=\E8, + rep=%p1%c\E[%p2%{1}%-%db, rev=\E[7m, ri=\EM, + rin=\E[%p1%dT, ritm=\E[23m, rmacs=\E(B, rmam=\E[?7l, + rmcup=\E[?1049l, rmir=\E[4l, rmkx=\E[?1l\E>, rmso=\E[27m, + rmul=\E[24m, rs1=\E]\E\\\Ec, sc=\E7, + setab=\E[%?%p1%{8}%<%t4%p1%d%e%p1%{16}%<%t10%p1%{8}%-%d%e48;5;%p1%d%;m, + setaf=\E[%?%p1%{8}%<%t3%p1%d%e%p1%{16}%<%t9%p1%{8}%-%d%e38;5;%p1%d%;m, + sgr=%?%p9%t\E(0%e\E(B%;\E[0%?%p6%t;1%;%?%p5%t;2%;%?%p2%t;4%;%?%p1%p3%|%t;7%;%?%p4%t;5%;%?%p7%t;8%;m, + sgr0=\E(B\E[m, sitm=\E[3m, smacs=\E(0, smam=\E[?7h, + smcup=\E[?1049h, smir=\E[4h, smkx=\E[?1h\E=, smso=\E[7m, + smul=\E[4m, tbc=\E[3g, tsl=\E]2;, u6=\E[%i%d;%dR, u7=\E[6n, + u8=\E[?%[;0123456789]c, u9=\E[c, vpa=\E[%i%p1%dd, + BD=\E[?2004l, BE=\E[?2004h, Clmg=\E[s, + Cmg=\E[%i%p1%d;%p2%ds, Dsmg=\E[?69l, E3=\E[3J, + Enmg=\E[?69h, Ms=\E]52;%p1%s;%p2%s\007, PE=\E[201~, + PS=\E[200~, RV=\E[>c, Se=\E[2 q, + Setulc=\E[58\:2\:\:%p1%{65536}%/%d\:%p1%{256}%/%{255}%&%d\:%p1%{255}%&%d%;m, + Smulx=\E[4\:%p1%dm, Ss=\E[%p1%d q, + Sync=\E[?2026%?%p1%{1}%-%tl%eh%;, + XM=\E[?1006;1000%?%p1%{1}%=%th%el%;, XR=\E[>0q, + fd=\E[?1004l, fe=\E[?1004h, kDC3=\E[3;3~, kDC4=\E[3;4~, + kDC5=\E[3;5~, kDC6=\E[3;6~, kDC7=\E[3;7~, kDN=\E[1;2B, + kDN3=\E[1;3B, kDN4=\E[1;4B, kDN5=\E[1;5B, kDN6=\E[1;6B, + kDN7=\E[1;7B, kEND3=\E[1;3F, kEND4=\E[1;4F, + kEND5=\E[1;5F, kEND6=\E[1;6F, kEND7=\E[1;7F, + kHOM3=\E[1;3H, kHOM4=\E[1;4H, kHOM5=\E[1;5H, + kHOM6=\E[1;6H, kHOM7=\E[1;7H, kIC3=\E[2;3~, kIC4=\E[2;4~, + kIC5=\E[2;5~, kIC6=\E[2;6~, kIC7=\E[2;7~, kLFT3=\E[1;3D, + kLFT4=\E[1;4D, kLFT5=\E[1;5D, kLFT6=\E[1;6D, + kLFT7=\E[1;7D, kNXT3=\E[6;3~, kNXT4=\E[6;4~, + kNXT5=\E[6;5~, kNXT6=\E[6;6~, kNXT7=\E[6;7~, + kPRV3=\E[5;3~, kPRV4=\E[5;4~, kPRV5=\E[5;5~, + kPRV6=\E[5;6~, kPRV7=\E[5;7~, kRIT3=\E[1;3C, + kRIT4=\E[1;4C, kRIT5=\E[1;5C, kRIT6=\E[1;6C, + kRIT7=\E[1;7C, kUP=\E[1;2A, kUP3=\E[1;3A, kUP4=\E[1;4A, + kUP5=\E[1;5A, kUP6=\E[1;6A, kUP7=\E[1;7A, kxIN=\E[I, + kxOUT=\E[O, rmxx=\E[29m, rv=\E\\[[0-9]+;[0-9]+;[0-9]+c, + setrgbb=\E[48\:2\:%p1%d\:%p2%d\:%p3%dm, + setrgbf=\E[38\:2\:%p1%d\:%p2%d\:%p3%dm, smxx=\E[9m, + xm=\E[<%i%p3%d;%p1%d;%p2%d;%?%p4%tM%em%;, + xr=\EP>\\|[ -~]+a\E\\, diff --git a/terminfo/xterm-kitty.terminfo b/terminfo/xterm-kitty.terminfo new file mode 100644 index 0000000..00a9be8 --- /dev/null +++ b/terminfo/xterm-kitty.terminfo @@ -0,0 +1,275 @@ +# Vendored from https://github.com/kovidgoyal/kitty/blob/master/terminfo/kitty.terminfo +xterm-kitty|KovIdTTY, + Su, + Tc, + XF, + am, + bw, + ccc, + fullkbd, + hs, + km, + mc5i, + mir, + msgr, + npc, + xenl, + colors#256, + cols#80, + it#8, + lines#24, + pairs#32767, + BD=\E[?2004l, + BE=\E[?2004h, + Cr=\E]112\007, + Cs=\E]12;%p1%s\007, + Ms=\E]52;%p1%s;%p2%s\E\\, + PE=\E[201~, + PS=\E[200~, + RV=\E[>c, + Se=\E[2\sq, + Setulc=\E[58:2:%p1%{65536}%/%d:%p1%{256}%/%{255}%&%d:%p1%{255}%&%d%;m, + Smulx=\E[4:%p1%dm, + Ss=\E[%p1%d\sq, + Sync=\EP=%p1%ds\E\\, + XR=\E[>0q, + acsc=++\,\,--..00``aaffgghhiijjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~, + bel=^G, + blink=\E[5m, + bold=\E[1m, + cbt=\E[Z, + civis=\E[?25l, + clear=\E[H\E[2J, + cnorm=\E[?12h\E[?25h, + cr=^M, + csr=\E[%i%p1%d;%p2%dr, + cub=\E[%p1%dD, + cub1=^H, + cud=\E[%p1%dB, + cud1=^J, + cuf=\E[%p1%dC, + cuf1=\E[C, + cup=\E[%i%p1%d;%p2%dH, + cuu=\E[%p1%dA, + cuu1=\E[A, + cvvis=\E[?12;25h, + dch=\E[%p1%dP, + dch1=\E[P, + dim=\E[2m, + dl=\E[%p1%dM, + dl1=\E[M, + dsl=\E]2;\E\\, + ech=\E[%p1%dX, + ed=\E[J, + el=\E[K, + el1=\E[1K, + fd=\E[?1004l, + fe=\E[?1004h, + flash=\E[?5h$<100/>\E[?5l, + fsl=^G, + home=\E[H, + hpa=\E[%i%p1%dG, + ht=^I, + hts=\EH, + ich=\E[%p1%d@, + il=\E[%p1%dL, + il1=\E[L, + ind=^J, + indn=\E[%p1%dS, + initc=\E]4;%p1%d;rgb\:%p2%{255}%*%{1000}%/%2.2X/%p3%{255}%*%{1000}%/%2.2X/%p4%{255}%*%{1000}%/%2.2X\E\\, + kBEG=\E[1;2E, + kBEG3=\E[1;3E, + kBEG4=\E[1;4E, + kBEG5=\E[1;5E, + kBEG6=\E[1;6E, + kBEG7=\E[1;7E, + kDC=\E[3;2~, + kDC3=\E[3;3~, + kDC4=\E[3;4~, + kDC5=\E[3;5~, + kDC6=\E[3;6~, + kDC7=\E[3;7~, + kDN=\E[1;2B, + kDN3=\E[1;3B, + kDN4=\E[1;4B, + kDN5=\E[1;5B, + kDN6=\E[1;6B, + kDN7=\E[1;7B, + kEND=\E[1;2F, + kEND3=\E[1;3F, + kEND4=\E[1;4F, + kEND5=\E[1;5F, + kEND6=\E[1;6F, + kEND7=\E[1;7F, + kHOM=\E[1;2H, + kHOM3=\E[1;3H, + kHOM4=\E[1;4H, + kHOM5=\E[1;5H, + kHOM6=\E[1;6H, + kHOM7=\E[1;7H, + kIC=\E[2;2~, + kIC3=\E[2;3~, + kIC4=\E[2;4~, + kIC5=\E[2;5~, + kIC6=\E[2;6~, + kIC7=\E[2;7~, + kLFT=\E[1;2D, + kLFT3=\E[1;3D, + kLFT4=\E[1;4D, + kLFT5=\E[1;5D, + kLFT6=\E[1;6D, + kLFT7=\E[1;7D, + kNXT=\E[6;2~, + kNXT3=\E[6;3~, + kNXT4=\E[6;4~, + kNXT5=\E[6;5~, + kNXT6=\E[6;6~, + kNXT7=\E[6;7~, + kPRV=\E[5;2~, + kPRV3=\E[5;3~, + kPRV4=\E[5;4~, + kPRV5=\E[5;5~, + kPRV6=\E[5;6~, + kPRV7=\E[5;7~, + kRIT=\E[1;2C, + kRIT3=\E[1;3C, + kRIT4=\E[1;4C, + kRIT5=\E[1;5C, + kRIT6=\E[1;6C, + kRIT7=\E[1;7C, + kUP=\E[1;2A, + kUP3=\E[1;3A, + kUP4=\E[1;4A, + kUP5=\E[1;5A, + kUP6=\E[1;6A, + kUP7=\E[1;7A, + kbeg=\EOE, + kbs=\177, + kcbt=\E[Z, + kcub1=\EOD, + kcud1=\EOB, + kcuf1=\EOC, + kcuu1=\EOA, + kdch1=\E[3~, + kend=\EOF, + kf1=\EOP, + kf10=\E[21~, + kf11=\E[23~, + kf12=\E[24~, + kf13=\E[1;2P, + kf14=\E[1;2Q, + kf15=\E[13;2~, + kf16=\E[1;2S, + kf17=\E[15;2~, + kf18=\E[17;2~, + kf19=\E[18;2~, + kf2=\EOQ, + kf20=\E[19;2~, + kf21=\E[20;2~, + kf22=\E[21;2~, + kf23=\E[23;2~, + kf24=\E[24;2~, + kf25=\E[1;5P, + kf26=\E[1;5Q, + kf27=\E[13;5~, + kf28=\E[1;5S, + kf29=\E[15;5~, + kf3=\EOR, + kf30=\E[17;5~, + kf31=\E[18;5~, + kf32=\E[19;5~, + kf33=\E[20;5~, + kf34=\E[21;5~, + kf35=\E[23;5~, + kf36=\E[24;5~, + kf37=\E[1;6P, + kf38=\E[1;6Q, + kf39=\E[13;6~, + kf4=\EOS, + kf40=\E[1;6S, + kf41=\E[15;6~, + kf42=\E[17;6~, + kf43=\E[18;6~, + kf44=\E[19;6~, + kf45=\E[20;6~, + kf46=\E[21;6~, + kf47=\E[23;6~, + kf48=\E[24;6~, + kf49=\E[1;3P, + kf5=\E[15~, + kf50=\E[1;3Q, + kf51=\E[13;3~, + kf52=\E[1;3S, + kf53=\E[15;3~, + kf54=\E[17;3~, + kf55=\E[18;3~, + kf56=\E[19;3~, + kf57=\E[20;3~, + kf58=\E[21;3~, + kf59=\E[23;3~, + kf6=\E[17~, + kf60=\E[24;3~, + kf61=\E[1;4P, + kf62=\E[1;4Q, + kf63=\E[13;4~, + kf7=\E[18~, + kf8=\E[19~, + kf9=\E[20~, + khome=\EOH, + kich1=\E[2~, + kind=\E[1;2B, + kmous=\E[M, + knp=\E[6~, + kpp=\E[5~, + kri=\E[1;2A, + kund=\E[1;2D, + kUN=\E[1;2A, + mc0=\E[i, + mc4=\E[4i, + mc5=\E[5i, + meml=\El, + memu=\Em, + mhpa=\E[%i%p1%d`, + mrcup=\E[%i%p1%d;%p2%df, + nel=\EE, + oc=\E]104\007, + op=\E[39;49m, + rep=%p1%c\E[%p2%{1}%-%db, + rev=\E[7m, + ri=\EM, + rin=\E[%p1%dT, + ritm=\E[23m, + rmacs=\E(B, + rmam=\E[?7l, + rmcup=\E[?1049l, + rmir=\E[4l, + rmkx=\E[?1l\E>, + rmso=\E[27m, + rmul=\E[24m, + rs1=\Ec, + sc=\E7, + setab=\E[%?%p1%{8}%<%t4%p1%d%e48:5:%p1%d%;m, + setaf=\E[%?%p1%{8}%<%t3%p1%d%e38:5:%p1%d%;m, + setrgbb=\E[48:2:%p1%d:%p2%d:%p3%dm, + setrgbf=\E[38:2:%p1%d:%p2%d:%p3%dm, + sgr=%?%p9%t\E(0%e\E(B%;\E[0%?%p6%t;1%;%?%p5%t;2%;%?%p2%t;4%;%?%p1%p3%|%t;7%;%?%p4%t;5%;%?%p7%t;8%;m, + sgr0=\E(B\E[m, + sitm=\E[3m, + smacs=\E(0, + smam=\E[?7h, + smcup=\E[?1049h, + smir=\E[4h, + smkx=\E[?1h\E=, + smso=\E[7m, + smul=\E[4m, + smxx=\E[9m, + tbc=\E[3g, + tsl=\E]2;, + u6=\E[%i%d;%dR, + u7=\E[6n, + u8=\E[?%[;0123456789]c, + u9=\E[c, + vpa=\E[%i%p1%dd, + XM=\E[?1006;1000%?%p1%{1}%=%th%el%;, + xr=\EP>|%p1%s\E\\, + xs=\E]2;%p1%s\E\\,