attify / firmware-analysis-toolkit

Toolkit to emulate firmware and analyse it for security vulnerabilities
MIT License
1.31k stars 251 forks source link

Network interface not working and no IP assigned. #17

Open r00tb3 opened 6 years ago

r00tb3 commented 6 years ago

I'm getting the following error:--

     __           _   
                              / _|         | |  
                             | |_    __ _  | |_ 
                             |  _|  / _` | | __|
                             | |   | (_| | | |_ 
                             |_|    \__,_|  \__|                    

                Welcome to the Firmware Analysis Toolkit - v0.2
    Offensive IoT Exploitation Training  - http://offensiveiotexploitation.com
                  By Attify - https://attify.com  | @attifyme

[?] Enter the name or absolute path of the firmware you want to analyse : /home/r00tb3/Desktop/dir-816/firmware/AP699E8C.CW125A-5-DLINK-R1B011D81870(0519085924)(1).img
[?] Enter the brand of the firmware : dlink
[+] Now going to extract the firmware. Hold on..
[+] Firmware : /home/r00tb3/Desktop/dir-816/firmware/AP699E8C.CW125A-5-DLINK-R1B011D81870(0519085924)(1).img
[+] Brand : dlink
[+] Database image ID : 1
[+] Identifying architecture
[+] Architecture : mipsel
[+] Storing filesystem in database
[+] Building QEMU disk image
[+] Setting up the network connection, please standby
[+] Network interfaces : []
[+] Running the firmware finally
[+] command line : sudo /home/r00tb3/re-tools/firmware-analysis-toolkit/firmadyne/scratch/1/run.sh
[*] Press ENTER to run the firmware...^CTraceback (most recent call last):

Why isn't it enabling any network interface?

How do I get this working and get and IP assigned to it?

Waiting for replies!!

extremecoders-re commented 6 years ago

Unfortunately, not all firmware image work out of the box with firmadyne. Looks like the inferNetwork.sh script failed to detect any interface. Try increasing the timeout value in inferNetwork.sh which is a part of upstream firmadyne.

Steps here

r00tb3 commented 6 years ago

@extremecoders-re The problem is that Init crashes:--

nvram_get_buf: Unable to open key: /firmadyne/libnvram/RESET_TAG!
nvram_get_buf: WebInit
sem_get: Key: 4110002a
sem_get: Key: 4110002a
nvram_get_buf: Unable to open key: /firmadyne/libnvram/WebInit!
nvram_clear: Clearing NVRAM...
sem_lock: Already initialized!

I think I'll have to recompile the libnvram but I don't know how to do it.

Pls, help me with this.

Thanks for the reply!!

extremecoders-re commented 6 years ago

You can include additional entries by modifying config.h.

r00tb3 commented 6 years ago

@extremecoders-re

What additional entries do I have to add?

I'm figuring that out.

extremecoders-re commented 6 years ago

Check the error messages nvram_get_buf: Unable to open key:

DerZc commented 5 years ago

@r00tb3 Have you solved this problem? How did you do?

ghost commented 5 years ago

Is anyone able to solve this problem?

r00tb3 commented 5 years ago

No i haven't solved the problem yet.

anindya14 commented 3 years ago

did you get the solution of it @r00tb3 ?

mark0519 commented 2 years ago

Is anyone able to solve this problem now?

devika6001 commented 9 months ago

@mark0519 are you able to solve this problem?

sdahiasdba commented 5 months ago

@mark0519 @extremecoders-re @anindya14 @r00tb3 @DerZc @mark0519 Anyone solve this problem?!!!