Screenshots of Netcat and DSlinux in action

April 11th, 2006

I compiled some pictures that show DynaStab connecting to my DS via the internet 3000 miles away on the east coast. Thank you DynaStab for the pictures and testing the DS as a server!

You may think after seeing the “127.0.0.1″ that this is a hoax. The reason DynaStability needed to connect to localhost is due to the strict firewall that I am behind and cannot change settings on. We accomplished the connection via a SSH tunneling procedure. If I was not behind such a firewall, DynaStab or anyone else could have easily connected by typing the DS’ IP in the netcat command prompt.

 This is a small snapshot of a dmesg output to show that what machine type the server is. As you can see, it is a Nintendo DS:

dmesg

 

 This is the full dmesg output given from the Nintendo DS:

dmesg Full

 

 This is a snapshot showing that a PC or DS user can connect via telnet or netcat session to play a text based adventure:

 Text-Based Adventure Server

 

This is a blog that shows how to make the Nintendo DS a standalone webserver that can serve html, text-based adventure games, and a lot more. Sound has even been streamed from DS to DS (it did sound weird since there was no buffering though) Pictures are included. Other uses of netcat can be used for port scanning and remote shell logins. This has been tested via DS to DS and DS to PC and PC to DS across the United States via the internet.

Netcat Tutorial and Binary Update

March 23rd, 2006

With help from the supportive DS homebrew community I was able to learn how to compile programs for DSlinux. I decided to get netcat working on the DS since it is one of my favorite command line programs. In doing so, DSlinux is capable of using all the functionality of the “TCP/IP Swiss-Army Knife.” Remember to type “nc –h” for options. Here are some tools you can use it for:

Online Role-Playing Game:

On the DS type this in your /usr/bin/ directory:

nc -v -l -p 3333 -e advent4
On your client connect with this command:

nc -v 192.168.1.104 3333

———————————————————-
Remote shell (using a PC as a client):

On the DS cd to your /bin directory and type the following command and touch enter:

nc –l –n –v –p 3333 –e login

 

After doing so, netcat hill tell you that it is listening on port 3333 which means the DS is now awaiting a client to attach via port 3333.

On your client (using any system [UNIX, WINDOWS, or even another DS] with a copy of netcat):

nc 192.168.1.104 3333

 

After pressing enter you should now be connected to the DS and should be seeing “login:” on your screen. Type in “root” and press enter.

ON THE SERVER DS,

Touch type the password for DSlinux and touch enter. If you did this correctly, you will now see a pound sign on the client computer, “#”. Congratulations you now have a remote shell to your DS!

———————————————————-

Port scanning:

Enter this on the DS:

nc –v –w 2 –z 192.168.1.1 20-30

To scan 192.168.1.1 ports 20 through 30 for open ports.

———————————————————-

Small webserver: (Thanks go to DynaStab for adding a –c function)

Create a script in your home directory on the DS with this in it:

while [ 1 = 1 ]

do

nc -l -p 80 -n -vv -c done Run this script with the index.html file in the same folder.
———————————————————-

File transer:

Client:

nc –v 192.168.1.1 3333 > file.anyextension

Server:

nc –v –c –p 3333 –l

 

——————————————————

Here is an updated version of the binary with some scripts written by DynaStab. Thanks to DynaStab, netcat now notices the end of a file so it enhances its ability as a server when you use “-c”. Also enabled is the “-e” function that excecutes any file after a client connects. Examples are shown above.

http://www.drunkencoders.com/hosted/zank/uploads/DSlinux_netcat.zip

Scripts for netcat

March 22nd, 2006

Once I get ftp access to my blog (which may be later tonight) I will also upload scripts that allow you to use netcat as an irc client, webproxy, web searcher, prober, and much more.

 I am still working on a patch to include netcat into the DSlinux CVS. It is taking longer than expected because I am using a remote shell to do all this, and I do not have the correct permissions to run certain perl scripts yet.

Netcat for dsLinux

March 22nd, 2006

I just learned how to start compiling programs for dsLinux. I now have a working binary thanks to Rusty’s generosity and patience to help teach me. I look forword to providing more binaries in the future. Feel free to comment or ask for certain linux networking tools for me to compile for you. My ultimate goal is packet capture through kismet or some other method. I believe sgstair is working on his own custom built solution, and I hope to hear from him about it. Maybe we will see tcpdump in the future. I will ask stsp if he needs a patch since this was already in the uClinux tree.

The binary for now can be found at:

 http://crackrock.org/nc

This binary will be hosted by Rusty until I can fix WordPress to allow me to upload files.

Back to “Normal”

March 18th, 2006

Now that I have my desktop back up and running I can focus on porting some programs to DSlinux to help make the DS a wifi diagnostic tool. Unfortunately, I am new to linux but I have been learning non-stop since I recieved a old pc and installed linux. Ubuntu helped ease me into the world of linux.