command-line-murders/i-0afc7b85b73ec3dc4
by SadServersMore by SadServers
cat: /etc/sudoers: Permission denied admin@i-092d4cf55fa0651c2:~$ sudo python3 webserver.py We trust you have received the usual lecture from the local System Administrator. It usually boils down to these three things: #1) Respect the privacy of others. #2) Think before you type. #3) With great power comes great responsibility. [sudo] password for admin: sudo: a password is required admin@i-092d4cf55fa0651c2:~$ ls agent webserver.py admin@i-092d4cf55fa0651c2:~$ ps aux |grep webserver
paris/i-092d4cf55fa0651c2 04:06
by SadServersNAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT nvme0n1 259:0 0 8G 0 disk ├─nvme0n1p1 259:1 0 7.9G 0 part / ├─nvme0n1p14 259:2 0 3M 0 part └─nvme0n1p15 259:3 0 124M 0 part /boot/efi nvme2n1 259:4 0 1G 0 disk └─test_vg-lvol0_rimage_1 254:1 0 1020M 0 lvm └─test_vg-lvol0 254:2 0 2G 0 lvm nvme1n1 259:5 0 1G 0 disk └─test_vg-lvol0_rimage_0 254:0 0 1020M 0 lvm └─test_vg-lvol0 254:2 0 2G 0 lvm admin@i-05f20f1fd6dc9dcd5:~$ sudo mkfs.ext4 test_vg-lvol0 mke2fs 1.46.2 (28-Feb-2021) The file test_vg-lvol0 does not exist and no size was specified. admin@i-05f20f1fd6dc9dcd5:~$ sudo mkfs.ext4 test_vg-lvol0
kihei/i-05f20f1fd6dc9dcd5 05:41
by SadServersdrwxr-xr-x 3 root root 16384 Jan 1 1970 data -rw-r--r-- 1 root root 5368709120 Sep 17 17:28 datafile -rwxr-xr-x 1 admin root 2207109 Sep 17 17:28 kihei admin@i-0e45767b31594566c:~$ chmod 777 data chmod: changing permissions of 'data': Operation not permitted admin@i-0e45767b31594566c:~$ sudo chmod 777 data admin@i-0e45767b31594566c:~$ ./kihei -v Deleting file /home/admin/data/newdatafile... panic: remove /home/admin/data/newdatafile: permission denied goroutine 1 [running]: main.main() ./main.go:50 +0x48d admin@i-0e45767b31594566c:~$ rm /home/admin/data/newdatafile rm: remove write-protected regular empty file '/home/admin/data/newdatafile'? n