1 year ago
#244027
Dovendyr
Failing to connect to my RabbitMQ node thats being run on a VM using erl from my host machine
I'm needing to create a basic CTF using docker-compose that will be spun up on a separate machine. I have been given a service that I have to misconfigure, which will lead to a second vulnerability to get the flag or root etc. My service is Erlang's EPMD and basically the misconfig is to keep the auth cookie default which creates a random 20 character A-Z string, so it should be easy to bruteforce. Misconfiguration aside, even when I set the cookie to a specific string, I cannot connect using erl from my host machine. I've tried all I could find and it always returns with "Shell terminated." The frustrating part is I know it can connect, I used a script from the erl-matter git repo and it authed and created a shell. However I can't connect with:
$ erl -sname test -setcookie topsecret -remsh rabbit@<hostname>
This is the file I'm using:
version: "3.5"
services:
rabbitmq:
image: rabbitmq:3-management-alpine
container_name: "sloth_ctf"
environment:
RABBITMQ_ERLANG_COOKIE: topsecret
RABBITMQ_DEFAULT_USER: admin
RABBITMQ_DEFAULT_PASS: notadmin
ports:
- '5672:5672'
- '15672:15672'
- '4369:4369'
- '25672:25672'
If you need anymore info or clarification I'll try my best to explain.
docker
docker-compose
erlang
erlang-shell
epmd
0 Answers
Your Answer