From nmap, there is http service opened.

Local Picture

This is the web page. Take a look at its cookie.

Local Picture

When I urldecode and base64 decode it, its original content appears.

Local Picture

It is running Node.js and the cookie is serialized. I found a blog post to create a serialized object for RCE with Node.js.

Local Picture

Copy the payload to username, base64 encode, and urlencode it. Take it as the cookie for the request, and I get a reverse shell as sun.

Local Picture

Local Picture

There is a file script.py.

Local Picture

And there is output.txt, created by root, contains the output from script.py. It can be the output of a cronjob. I modify script.py to create a reverse shell. Five minutes later, I get the reverse shell as root.

Local Picture

Local Picture