I've been playing around with a router d-link dwr-921 and found some vulnerabilities in the web interface. I still haven't managed to get shell access and now I'm thinking about modifying the firmware since I can access the administration panel.
So far, I've downloaded the latest firmware from d-link, disassembled it using this tool chain and examined the output. On a partition called rootfs/, on which the web interface is located, are several .htm files. These files, however, also contain binary code aside from html, css and javascript which is used to apply settings on the router. How may I find out what binary format is the router using? I'm guessing that it's ARM but haven't tried to disassemble it yet.
I was thinking of compiling a standalone ssh server, add it to the rootfs/ and create an .htm file that sets it up as a cron job for later use.
Can you think of another approach?