DinoTools / dionaea-docker

16 stars 6 forks source link

How to install it correct? #1

Open Philelis opened 7 years ago

Philelis commented 7 years ago

Hey, I tried to use your dionaea-docker on CentOS 7, but with your commands I got errors ;/

#  docker run -it --rm -v "$PWD/etc":/opt/dionaea/etc/dionaea -p 21:21 -p 42:42 -p 69:69/udp -p 80:80 -p 135:135 -p 443:443 -p 445:445 -p 1433:1433 -p 1723:1723 -p 1883:1883 -p 1900:1900/udp -p 3306:3306 -p 5060:5060 -p 5060:5060/udp -p 5061:5061 -p 11211:11211 dinotools/dionaea-docker
2017-04-13 11:19:05,518 CRIT Supervisor running as root (no user in config file)
2017-04-13 11:19:05,519 WARN Included extra file "/etc/supervisor/conf.d/dionaea.conf" during parsing
2017-04-13 11:19:05,519 WARN Included extra file "/etc/supervisor/conf.d/p0f.conf" during parsing
2017-04-13 11:19:05,527 INFO RPC interface 'supervisor' initialized
2017-04-13 11:19:05,527 CRIT Server 'unix_http_server' running without any HTTP authentication checking
2017-04-13 11:19:05,527 INFO supervisord started with pid 1
2017-04-13 11:19:06,531 INFO spawned: 'dionaea' with pid 7
2017-04-13 11:19:06,536 INFO spawned: 'p0f' with pid 8
2017-04-13 11:19:06,550 INFO exited: dionaea (terminated by SIGTRAP (core dumped); not expected)
2017-04-13 11:19:07,554 INFO spawned: 'dionaea' with pid 9
2017-04-13 11:19:07,555 INFO success: p0f entered RUNNING state, process has stayed up for > than 1 seconds (startsecs)
2017-04-13 11:19:07,564 INFO exited: dionaea (terminated by SIGTRAP (core dumped); not expected)
2017-04-13 11:19:09,569 INFO spawned: 'dionaea' with pid 10
2017-04-13 11:19:09,581 INFO exited: dionaea (terminated by SIGTRAP (core dumped); not expected)
2017-04-13 11:19:12,587 INFO spawned: 'dionaea' with pid 11
2017-04-13 11:19:12,597 INFO exited: dionaea (terminated by SIGTRAP (core dumped); not expected)
2017-04-13 11:19:13,598 INFO gave up: dionaea entered FATAL state, too many start retries too quickly
^C2017-04-13 11:19:21,402 WARN received SIGINT indicating exit request
2017-04-13 11:19:21,402 INFO waiting for p0f to die
2017-04-13 11:19:21,404 INFO stopped: p0f (exit status 15)

I tried it also with this: # docker run --cap-add=NET_BIND_SERVICE --rm=true -p 21:21 -p 42:42 -p 8080:80 -p 135:135 -p 443:443 -p 445:445 -p 1433:1433 -p 3307:3306 -p 5061:5061 -p 5060:5060 -p 69:69/udp -p 5060:5060/udp -v /var/dionaea:/data/dionaea -v /etc/dionaea:/etc/dionaea dinotools/dionaea-docker:latest

And tried to use Hpfeeds and local logging, but there where no files or events.

Could you please help me?

phibos commented 7 years ago

docker run -it --rm -v "$PWD/etc":/opt/dionaea/etc/dionaea -p ...

# docker run --cap-add=NET_BIND_SERVICE --rm=true -p 21:21 -p 42:42 -p 8080:80 -p 135:135 -p 443:443 -p 445:445 -p 1433:1433 -p 3307:3306 -p 5061:5061 -p 5060:5060 -p 69:69/udp -p 5060:5060/udp -v /var/dionaea:/data/dionaea -v /etc/dionaea:/etc/dionaea dinotools/dionaea-docker:latest

To access the files in the container.

# docker ps
CONTAINER ID        IMAGE                             COMMAND                  CREATED             STATUS              PORTS                                                                                                                                                                                                                                                                                                   NAMES
0c5f51595e9c        dinotools/dionaea-docker:latest   "/usr/bin/supervis..."   32 seconds ago      Up 30 seconds       0.0.0.0:21->21/tcp, 0.0.0.0:42->42/tcp, 0.0.0.0:135->135/tcp, 0.0.0.0:443->443/tcp, 0.0.0.0:445->445/tcp, 1723/tcp, 0.0.0.0:1433->1433/tcp, 0.0.0.0:69->69/udp, 1883/tcp, 0.0.0.0:5060-5061->5060-5061/tcp, 0.0.0.0:5060->5060/udp, 11211/tcp, 1900/udp, 0.0.0.0:8080->80/tcp, 0.0.0.0:3307->3306/tcp   youthful_blackwell

Use the container id to start a new shell in the container.

# docker exec -it 0c5f51595e9c /bin/bash
root@0c5f51595e9c:/#

Have a look at /var/log/supervisor/ for the supervisor logs and at /opt/dionaea/var/dionaea for the dionaea logs.