Hacking DNS323 NAS
by rp
I had recently bought a Network Attached Storage DNS323 which runs two drives of 1tb each and I use them for my ever growing media including photos shot in RAW format. The good thing about this NAS box is that it runs linux and the manufacturer provides a hook to hack the system to run additional software.

I was interested in hacking this box for the following reasons:
- I wanted to be able to run my own svn repo on it, as it was already being mirrored.
- Instead of running this as RAID 1 mirroring, I wanted to get rsync to copy the data across on the other hard disk as RAID 1 has its own issues and I cant take chances with my media.
- I wanted to mod the USB on this NAS box so that I can plug in an external hard disk to copy the data to an additional hdd without having to open anything up or use another computer.
I am listing the steps to get it up and running as a quick start guide for future, to avoid having to go through quite a few pages on the actual wiki page.
Copy fun_plug and fun_plug.tgz to top most level of Volume 1 and restart the NAS box.
The manufacturer has a hook in the framework itself to ensure that it looks for a file for fun_plug and execute it, this adds additional stuff that kickstarts the process, by enabling the telnet process.
Connecting the first time.
Once the box has re-booted, try telnetting to it (you will need to find its ip address, possibly using nmap (sudo nmap -sS -O 192.168.1.0/24). If you get the shell, everything got installed properly.
/#
You are now in!
Secure the box, FIRST
First run the pwconv utility and update the shadow-file
pwconv
and ensure that you promptly change your ‘root’ password as the first thing.
passwd
Now activate the root-user, which comes disabled by default
usermod -s /ffp/bin/sh root
Now ensure that the password gets written down and stored permanently on the drive.
store-passwd.sh
Enable ssh
Its a good idea to run shell sessions over ssh for obvious reasons so disable telnet and enable ssh using the following commands.
chmod a+x /ffp/start/sshd.sh sh /ffp/start/sshd.sh start chmod -x /ffp/start/telnetd.sh #that makes the start script unexecutable
Now reboot to confirm that telnet is off and ssh is on. Try both and if all worked properly you should only have access to login via ssh and not via telnet.
What next?
There are quite a few things you can do now that you have a proper operating system running on it, I shall install a few more packages and post about it and then setup the first three objectives why I started doing it in the first place.
–
Steps mostly taken from: