
Show HN: SSHTron – Play Tron/lightcycle over SSH - zachlatta
http://sshtron.zachlatta.com
======
zachlatta
Hey everyone! My friend and I made this over the weekend.

I'm sorry about all the issues with the freezing and disconnects – the
response has been really overwhelming and the game certainly isn't optimized
for less than ideal network situations. If you're continually getting kicked,
it's probably just because the server is having trouble getting a solid
connection to you. If it helps, the server is in SF right now (though I'm able
to get a solid connection that's playable from NY).

~~~
lucb1e
> If it helps, the server is in SF right now (though I'm able to get a solid
> connection that's playable from NY).

I don't think your audience is 99% silicon valley, or even 99% United States
of American. Having multiple servers might be more advisable than moving it
somewhere ;)

~~~
zachlatta
This is just a fun project we hacked together in the past day to share with
our friends, who are primarily on the west coast. If we were designing it to
scale, we'd certainly do that!

~~~
lucb1e
Certainly, and it's a really cool project and I love it. Just saying, HN
community != (USA | Silicon Valley) :)

------
gouggoug
The usual warning sign here.

Be careful when SSHing into hosts you do not know with an unpatched version of
OpenSSH:

[http://cve.mitre.org/cgi-
bin/cvename.cgi?name=CVE-2016-0777](http://cve.mitre.org/cgi-
bin/cvename.cgi?name=CVE-2016-0777)

edit: @Ao7bei3s comment below gives more information on how to protect
yourself.

~~~
sillysaurus3
Rather than post the equivalent of "Ignore this Show HN," you should post the
steps people can take to protect themselves.

~~~
Ao7bei3s
ssh -o "PreferredAuthentications=password,keyboard-interactive" -o
"UseRoaming=no" root@sshtron.zachlatta.com

Explanation:

Use a recent ssh version (if you've updated in February you're safe), or put
in your .ssh/config file:

    
    
      # CVE-2016-0777
      UseRoaming no
    

Additionally, while you are at it, you can take care of some privacy problems.
These are really not a big deal though.

Don't hand your SSH public key to the server:

    
    
      # Makes SSH not try other keys than ~/.ssh/id_{dsa/ecdsa/rsa}.
      IdentitiesOnly yes
      
      # And move ~/.ssh/id_{dsa/ecdsa/rsa}{,.pub} somewhere else,
      # including it on a per host basis:
      Host *.example.com example.com
        IdentityFile ~/.ssh/my_id_rsa
    

Or you could just disable pubkey authentication for this one connection with
ssh -o "PreferredAuthentications=password,keyboard-interactive".

Including root@ prevents leaking your local username.

If in doubt, man ssh + man ssh_config (they contain other useful things like
"CanonicalizeHostname yes / CanonicalDomains ycombinator.com" / example: ssh
root@news).

(I don't know what's wrong with the internet that we need "how to SSH" posts
now, though. But here it is.)

------
rdancer
Do not redraw the whole display. Use termcap and ncurses to send terminal
escapes. It's unplayable for me, probably because of latency.

Good idea :-)

------
jcr
I think this is a great idea, and it looks like a lot of fun, but
unfortunately, it doesn't work for me. Though I'm sure tested this on "Linux"
and "MacOS X" as you said, the real problem you face is most terminal
emulators are not standards compliant (assuming there _are_ standards for
particular behaviors, and often there aren't any). This means, you got it
working on some terminal emulators, but it won't work on others.

The most standards compliant terminal emulator is actually the original
'xterm' [1] program included as part of X. The xterm FAQ [2] and ncurses FAQ
[3] have lots of useful information. Though getting your code running in xterm
itself will help portability, it won't be the end of your debugging due to the
fact that other terminal emulators have bugs and of course, they often do
things differently. The story about the color blue [4] in the xterm FAQ should
give you an idea of the kinds of problems you'll face.

[1] [http://invisible-island.net/xterm/xterm.html](http://invisible-
island.net/xterm/xterm.html)

[2] [http://invisible-island.net/xterm/xterm.faq.html](http://invisible-
island.net/xterm/xterm.faq.html)

[3] [http://invisible-island.net/ncurses/ncurses.faq.html](http://invisible-
island.net/ncurses/ncurses.faq.html)

[4] [http://invisible-
island.net/xterm/xterm.faq.html#dont_like_b...](http://invisible-
island.net/xterm/xterm.faq.html#dont_like_blue)

------
qrv3w
Hey this is incredible, nice job! Any chance of sharing the source?

Edit: Nevermind - I see it.
[https://github.com/zachlatta/sshtron](https://github.com/zachlatta/sshtron) I
can't believe you made this in 20 hours, amazing!

~~~
zachlatta
Linked on the website in the upper left corner!
[https://github.com/zachlatta/sshtron](https://github.com/zachlatta/sshtron).

------
plugnburn
Great there still are some multiplayer network games for terminal-only
systems. Nice work!

------
stevewillows
Thanks for posting this! It's amazing how something so simple can be so much
fun.

------
131hn
Putty keep crashing with weird errors, any reason for this ?

~~~
0x0
Are you using the latest putty release? Some scary looking security fixes in
the last few versions.
[http://www.chiark.greenend.org.uk/~sgtatham/putty/changes.ht...](http://www.chiark.greenend.org.uk/~sgtatham/putty/changes.html)
and particularly
[http://www.chiark.greenend.org.uk/~sgtatham/putty/wishlist/v...](http://www.chiark.greenend.org.uk/~sgtatham/putty/wishlist/vuln-
ech-overflow.html)

