mirror of
https://github.com/hackerschoice/thc-tips-tricks-hacks-cheat-sheet.git
synced 2026-08-28 02:40:24 +02:00
Update README.md
This commit is contained in:
@@ -1067,15 +1067,20 @@ exec python -c 'import pty; pty.spawn("/bin/bash")'
|
|||||||
```sh
|
```sh
|
||||||
# On the target host spwan a PTY using any of the above examples:
|
# On the target host spwan a PTY using any of the above examples:
|
||||||
python -c 'import pty; pty.spawn("/bin/bash")'
|
python -c 'import pty; pty.spawn("/bin/bash")'
|
||||||
|
|
||||||
# Now Press Ctrl-Z to suspend the connection and return to your own terminal.
|
# Now Press Ctrl-Z to suspend the connection and return to your own terminal.
|
||||||
|
```
|
||||||
|
|
||||||
|
```
|
||||||
# On your terminal execute:
|
# On your terminal execute:
|
||||||
stty raw -echo opost; fg
|
stty raw -echo opost; fg
|
||||||
|
```
|
||||||
|
|
||||||
|
```
|
||||||
# On target host
|
# On target host
|
||||||
export SHELL=/bin/bash
|
export SHELL=/bin/bash
|
||||||
export TERM=xterm-256colorreset
|
export TERM=xterm-256color
|
||||||
stty rows 24 columns 80
|
reset
|
||||||
|
stty rows 24 columns 180
|
||||||
# Pimp up your prompt
|
# Pimp up your prompt
|
||||||
PS1='{THC} USERS=$(who | wc -l) LOAD=$(cut -f1 -d" " /proc/loadavg) PS=$(ps -e --no-headers|wc -l) \[\e[36m\]\u\[\e[m\]@\[\e[32m\]\h:\[\e[33;1m\]\w \[\e[0;31m\]\$\[\e[m\] '
|
PS1='{THC} USERS=$(who | wc -l) LOAD=$(cut -f1 -d" " /proc/loadavg) PS=$(ps -e --no-headers|wc -l) \[\e[36m\]\u\[\e[m\]@\[\e[32m\]\h:\[\e[33;1m\]\w \[\e[0;31m\]\$\[\e[m\] '
|
||||||
```
|
```
|
||||||
|
|||||||
Reference in New Issue
Block a user