Vu1nT0tal / IoT-vulhub

IoT固件漏洞复现环境
https://vulntotal-team.github.io/IoT-vulhub/
GNU General Public License v3.0
1.17k stars 173 forks source link

ssh: connect to host 127.0.0.1 port 1234: Connection refused #16

Closed Vxer-Lee closed 2 years ago

Vxer-Lee commented 3 years ago

环境:

D-Link/CVE-2019-17621

我构建好了所有的镜像,然后按照教程启动容器时候,发现报错exited with code 0

:~/IoT-vulhub/D-Link/CVE-2019-17621$ docker-compose -f docker-compose-firmae.yml up
Creating dlink-firmae ... done
Attaching to dlink-firmae
dlink-firmae  | 
dlink-firmae  | Scan Time:     2021-08-03 10:52:55
dlink-firmae  | Target File:   /bin/sh
dlink-firmae  | MD5 Checksum:  e02ea3c3450d44126c46d658fa9e654c
dlink-firmae  | Signatures:    411
dlink-firmae  | 
dlink-firmae  | DECIMAL       HEXADECIMAL     DESCRIPTION
dlink-firmae  | --------------------------------------------------------------------------------
dlink-firmae  | 0             0x0             ELF, 64-bit LSB shared object, AMD x86-64, version 1 (SYSV)
dlink-firmae  | 121509        0x1DAA5         Unix path: /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
dlink-firmae  | 
dlink-firmae  | 
dlink-firmae  | Scan Time:     2021-08-03 10:52:55
dlink-firmae  | Target File:   /root/run.sh
dlink-firmae  | MD5 Checksum:  9a755098ab0058be71245bf6063fc25d
dlink-firmae  | Signatures:    411
dlink-firmae  | 
dlink-firmae  | DECIMAL       HEXADECIMAL     DESCRIPTION
dlink-firmae  | --------------------------------------------------------------------------------
dlink-firmae  | 0             0x0             Executable script, shebang: "/bin/bash"
dlink-firmae  | 33            0x21            Unix path: /etc/init.d/ssh start
dlink-firmae  | 
dlink-firmae exited with code 0

123

jerrymajerry commented 2 years ago

修改docker-compose-firmadyne.yml 在services下添加 tty: true

Erebua commented 2 years ago

修改docker-compose-firmadyne.yml 在services下添加 tty: true

@jerrymajerry @firmianay 师傅,加了这项之后,重新buildup还是出现上图的情况

Erebua commented 2 years ago

修改docker-compose-firmadyne.yml 在services下添加 tty: true

@jerrymajerry @firmianay 师傅,加了这项之后,重新buildup还是出现上图的情况

version: "3"

services:
    firmadyne-emu:
        container_name: dlink-firmadyne
        build:
            context: .
            dockerfile: ./firmadyne-emu/Dockerfile
        tty: true
        privileged: true
        ports:
            - "1234:22"
1222schm commented 2 years ago

建议删除之前下载的依赖,在重新安装