5 ms·
Show HN: Play Zork with your friends via SSH
- pheasantquiff 5y agoPlay Zork, with your friends (via ssh) $ ssh -p 64100 someusername@sayitwith.ink password: nitfol > /help > /who > !look (login denied? maybe someone else is using that username, try another)
- pheasantquiff 5y agoIf anyone is interested in discussing this (or playing IF on my other server) please get in touch on Revolt. I am @JesusMachineSantana. Here is an invitation to my "Guild" https://app.revolt.chat/invite/Xm9jmNDv https://app.revolt.chat/invite/Xm9jmNDv Maybe you have to sign up on the main page first, not sure. https://revolt.chat/ https://revolt.chat/ Of course, it's also possible to chat on the SSH server above, though maybe not as convenient. Either way is welcome.
- throwaway47292 5y agoGentle reminder: when sshing into unknown places remember to check your forwarding and dont use your github/etc username.
- pheasantquiff 5y agoSage advice. This is really more suited to IRC but ssh is something everyone has readily available. It has a much lower barried to entry. Isn't a specific effort required to have [port] forwarding? I don't think anyone will do it accidentally, even were I nefarious. In other words, if you don't know what "forwarding" is, then you don't have to worry.
- throwaway47292 5y agonono ssh is great medium, just most people have agent forwarding by default, and its annoying that it can be exploited by malicious ssh host[1] [1]: https://book.hacktricks.xyz/linux-unix/privilege-escalation/ssh-forward-agent-exploitation https://book.hacktricks.xyz/linux-unix/privilege-escalation/...
- binwiederhier 5y agoThat's a great resource. I had never heard of this attack vector before. Thanks for sharing the link.
- tyingq 5y agoThis: "ssh -o ClearAllForwardings=yes ..." seems like it would be a good catch-all.
- SavantIdiot 5y agoCan I stick that into ~/.ssh/config somehow so it is always a default, or should i just alias it?
- thaumasiotes 5y agoIf you're going to change your config, couldn't you just... not have forwarding?
- est 5y agoAlternatively you can config id_rsa from different path specifically for github and your work repo. Use a general non-identifiable id_rsa to play with public ssh servers.
- Groxx 5y agoForwarding is not the default behavior, so normally you're fine. For others, if you do this: Host * ForwardAgent yes you can take this as a reminder that `Host *` is playing with fire, and just asking for accidents like this. Be extremely careful with `Host *` configs, especially with anything security-sensitive. "Careful", as in "do not do it if there's literally any risk". And if you don't know for sure, consider it a risk by default. `Host *.internal` at a minimum, or whatever hostname / dns patterns are used around you, is dramatically safer and just as convenient.
- GekkePrutser 5y agoAdditionally, setting up an SSH agent that requires confirmation for every use is a great measure to prevent abuse when you do forward it by mistake.
- digitalsushi 5y agoStronger reminder: Don't play with SSH toys using your work computer, ever, as a sensible way to remain employed
- tyingq 5y agoOne workaround...launch a Google cloud shell from a personal google account and try the ssh toy from there. It's free. https://cloud.google.com/shell https://cloud.google.com/shell
- chillingeffect 5y agoi miss the much-maligned telnet :( perfect for uncritical fun stuff like this.
- GekkePrutser 5y agoI wish I was able to SSH from work at all :)
- herdrick 5y agoWhy not use your github/etc username?
- est 5y agoit can be used to dox you
- phonethrowaway 5y agoshell escapes are real attack vector too...
- davidjhall 5y agoDid you write a z-machine with sockets or is this piping to an existing one (frotz, etc?) I'm curious about the internals because I'm working on my own z-machine implementation too (not ssh though!)
- pheasantquiff 5y ago:) Yes I'm piping to dumb-frotz. The ssh server is a custom golang server, not a 'real' ssh daemon. Z-machine impl is fun (except for all the version differences)
- davidjhall 5y agoVery fun indeed and easier than a sockets-based impl that covers all versions. I'm only doing v3 so far and it's a long haul! Congrats on this!
- pheasantquiff 5y agoThere are quite a few edge cases going the pipe route since there is no defined communication protocol and every game expresses some things slightly differently. I try to keep the code as generic as possible but nearly every game I try has had a surprise for me. I really don't want to have tons of special cases in the code but I think some might be unavoidable. If you're writing your own Z-machine, then you can write it in a way that plans for such integration and that would make a direct-linked approach much easier. My 'ssh toy' has proven quite popular so far and I hope it has introduced IF to some new people. Thanks and best of luck with your Z-Machine. Hacks and Glory await!
- pheasantquiff 5y agoI'm sure you've read all the Graham Nelson Z-Machine specs etc.? And seen the various alternative implementations like nitfol (which is a bit smaller than most and easier to read maybe)?
- davidjhall 5y ago
- empressplay 5y agoI'm having a very strange sense of deja vu...
- cheaprentalyeti 5y agoHopefully you won't be eaten by a grue.
- thebeardisred 5y agoA blast from the past, courtesy of me - play Zork anywhere you can run a OCI container: `<container engine> run -it quay.io/games/zork`
- julienchastang 5y agoThanks. I played with this version (in a sandboxed VM) and it worked well. It really brought back memories. I was surprised how much I remembered about the game several decades later. Ahh those were the good old days :-)
- makeworld 5y agoHow do you play with other people? I'm confused, but happy to see a hosted SSH application in 2021! Wanna see more of these.
- pheasantquiff 5y agoI think the simplest answer to that is just to try it, if you haven't already. Briefly, everyone connected is playing a single game of Zork (in this instance, tho any z-machine game will work). Like a chat session everyone can see every other player's commands/comments, and the game's output. Just $ ssh -p 64100 urnamehere@sayitwith.ink password: nitfol > /help > /who > !look > !get lamp Also, thanks and I think I must have missed the "SSH Toy" craze when it was popular.
- redrobein 5y agoThere's also watchcdda[1] which lets you play group play cataclysm dda. [1] https://r7st.guru/watchcdda/ https://r7st.guru/watchcdda/
- dettus 5y agoAnd if you want to play more text adventures, like "The Guild of Thieves", go to http://magneticscrolls.net http://magneticscrolls.net Or type in ssh -p 8080 -l magnetic magneticscrolls.net
- pheasantquiff 5y agoYes thank you @dettus. I recently found your site via asciicinema and it was your site that inspired me to make this. (The wheelbarrow is so annoying)