privilege escalation

Checking if current user is allowed to run any command as root.

sudo -l

we can see that our current user charles is allowed to /usr/bin/gcore as root user with a password.

change directory for current shell

Information about the binary file.

It can be used to generate core dumps of running processes. Such files often contains sensitive information such as open files content, cryptographic keys, passwords, etc. This command produces a binary file named core. $PID , that is then often filtered with strings to narrow down relevant information.

Let's search for process having sensitive information.

I can see a process with binary name as password-store . According to me this can have sensitive information. So, I will dump this process data.

I will use the strings command to display the content, as this is binary file data and its information is not in a human-readable format.

Information

From the output, I got the password of the root user.

Using this credential, I will switch to root user.

I will again stabalize the shell.

Last updated

Was this helpful?