mirror of
https://github.com/AbdullahRizwan101/CTF-Writeups
synced 2024-11-21 19:43:03 +00:00
Update Cheat Sheet.md
This commit is contained in:
parent
496bd71462
commit
46a8aa85bd
1 changed files with 5 additions and 1 deletions
|
@ -226,7 +226,7 @@ sudo /usr/bin/ln
|
|||
```
|
||||
### Escaping restricted Shell (rbash)
|
||||
|
||||
Using vi editor
|
||||
#### Using vi editor
|
||||
|
||||
```
|
||||
: set shell =/bin/sh
|
||||
|
@ -236,6 +236,10 @@ Then setting the PATH variable
|
|||
|
||||
`/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin`
|
||||
|
||||
#### Using -t 'bash --noprofile'
|
||||
|
||||
When logging in with ssh we can using -t to enable pseudo-tty allocation and then we can change the PATH and SHELL varaible
|
||||
|
||||
### Tar Exploitation
|
||||
|
||||
When ever you see a cronjob running with a command `cd /<user>/andre/backup tar -zcf /<folder>/filetar.gz *` go to that folder from which a backup is being created and running these command in that directory <br/ >
|
||||
|
|
Loading…
Reference in a new issue