pr0v3rbs / FirmAE

Towards Large-Scale Emulation of IoT Firmware for Dynamic Analysis
MIT License
603 stars 117 forks source link

How to modify the IP address simulated by the firmware? #77

Open DaDong-G opened 3 months ago

DaDong-G commented 3 months ago

How to modify the IP address simulated by the firmware? When I tried to simulate it with docker, I bound it to 192.168.0.1. No matter how I changed the script, it had no effect. Is there any way to change it to another IP, such as 172.17.0.110?

DaDong-G commented 3 months ago

Or how to modify the port? Every time it is bound to port 80, is there any way to change it?

DaDong-G commented 3 months ago

有人吗?

pr0v3rbs commented 3 months ago

If a network information found in qemu.initial.serial.log, then the related network interface will be created on the actual emulation phase. However, the network was not found, then FirmAE will use 192.168.0.1 as a default network interface.

The IP address can be found in the run.sh script from scratch directory and firmadyne/network.sh script in the image.raw filesystem image. Change the IP address what you want.

Finally, the all port will be connectable from the host to the guest.