vortex0: Take Two

After many days of doing things that are often done by people who entertain doing things, I finally did them. One of these things was the revising the old vortex#0 game. Specifically, I wanted to answer the following question:

Can you implement this script without using anything but bash?

My initial answer was “no”, but I can certainly try, and see what I learn along the way. To start with, I’ve grabbed the old script, cleaned it up a bit and added some versioning:


The first thing I tried to do was to remove the dependency on the ‘socat’ tool. After a bit of reading man panges, it turns out that bash actually supports native TCP/IP functionality (among quite a few other things). Specifically, if we go to the bash man page, we get the following:


After a little bit of fiddling around, we can remove the socat dependency from our vortex0 script, as follows:


In a nutshell, we simply replace socat with file descriptor 9, attached to the vortex.labs.overthewire.org system.  The rest is essentially the same thing. We think it’s a pretty neat trick, and the applications of this (bash’s support for special filenames like this) are fairly interesting.

About Nima Talebi

Joke with the jesters, tickle the trolls, banter with the bards.
This entry was posted in Computers, Jesting. Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.