nuclei-templates/code/privilege-escalation/linux/writable-etc-passwd.yaml

31 lines
647 B
YAML

id: writable-etc-passwd
info:
name: /etc/passwd writable - Privilege Escalation
author: daffainfo
severity: high
reference:
- https://book.hacktricks.xyz/linux-hardening/privilege-escalation#writable-etc-passwd
metadata:
verified: true
tags: code,linux,privesc
self-contained: true
code:
- engine:
- sh
- bash
source: |
[ -w "/etc/passwd" ] && echo "Writable" || echo "Not writable"
matchers:
- type: word
part: code_1_response
words:
- "Writable"
- type: word
part: code_1_response
words:
- "Not writable"
negative: true