I'm currently researching my home router (D-Link 2760-U) which has a (kind-of) proprietary ISP firmware. What I'm trying to achieve is understanding how the router is persisting it's configuration settings across reboots.
mount
output:
/dev/mtdblock0 on / type squashfs (ro,relatime)
/proc on /proc type proc (rw,relatime)
tmpfs on /var type tmpfs (rw,relatime,size=420k)
tmpfs on /mnt type tmpfs (rw,relatime,size=16k)
sysfs on /sys type sysfs (rw,relatime)
I did nvram show
and it does contain some wireless configuration such as the encryption in use, wireless modes, pre-shared key but that's about it. Obviously the router has other configurations (such as DNS, PPP, Port forwards etc) that must be stored elsewhere.
As it can be observed, all mounted filesystems are volatile and thus configuration cannot be stored in them.
Where can the information be saved besides filesystem and NVRAM? How do I go about finding this out?
nvram show
some kind of ascii, or binary stuff that needs a command likestrings
to read? If it's binary, the other configuration might be right there but unreadable.cat /proc/mtd
?dev: size erasesize name
mtd0: 00608000 00608000 "Physically mapped flash"
. /dev/ has mtd[0-1] and mtdblock[0-7].