HN user

antoniomika

296 karma

https://antonio.cx

[ my public key: https://keybase.io/antoniomika; my proof: https://keybase.io/antoniomika/sigs/LlYvMqpjWk7dbyijNgU-BLt6pqbTGLzewD_mmwAWr9E ]

Posts5
Comments63
View on HN

We’re actually using Unix sockets as the underlying transport layer for this. We’re also not using sshd, we custom wrote our own daemon that’s entire job is tunneling. If you’re curious about this, you can find the project here: https://github.com/antoniomika/sish

sish was actually my first foray into SSH apps. It was a lot of fun to write and pretty much implements tunnels with a routing system on top. It manages connectivity, routing, and reverse proxying all within user space. No namespaces required!

tuns can actually even tunnel UDP traffic over SSH, also entirely in user space. Docs for that can be found here: https://pico.sh/tuns#udp-tunneling

We recently changed our tui framework and the functionality for focus is a bit different. You might have to hit <tab> until `ADD` is highlighted. You can also rsync/scp/sftp an authorized_keys file and we'll add that to your account!

I wrote a system that did this >5 years ago (luckily was able to open source it before the startup went under[0]). The bastion would record ssh sessions in asciicast v2 format and store those for later playback directly from a control panel. The main issue that still isn't solved by a solution like this is user management on the remote (ssh server) side. In a more recent implementation, integration with LDAP made the most sense and allows for separation of user and login credentials. A single integrated solution is likely the holy grail in this space.

[0] https://github.com/notion/bastion

Nope! I utilize env files for all of my password/privileged settings. In the command entry for docker-compose.yml, you can then use a non-templated env var (one that docker-compose itself doesn't fill) by replacing a single dollar sign with two. That then loads the credential from the environment instead of command line.

Thanks for the feedback and trying things out!

- We like the "ssh to create an account" idea too. Makes it easy to confirm a user's identity which is nice and uses tried and true auth/encryption methods. Feedback has been good overall for the experience, main issue is managing account reset methods as that is a bit difficult.

- Noted on the account signup UI, we'll look into how we can work on making that cleaner (a blinking cursor is probably a good start).

- Once you signup, you can actually ssh to pgs without any username set and it will find the account for the public key used on signup.

- The site URL is a bit hard to deal with when uploading multiple files. We'll think of how to make this more clear.

- There's a "cli" based workflow with pgs. You can list your sites with `ssh pgs.sh ls`, you can replace `ls` with `help` for a list of other commands. We want to move away from the TUI a bit and have commands that are easy to be scripted.

- $20/year :)

Thanks again for all of the feedback, always appreciated!

We have rsync implemented with our other pico services, but we need to spend some time to finish implementing the rest of the protocol (support proper diff/upload, this includes recursive file uploads). We'll have that implemented once we're ready to open this up to everyone else. Of course, contributions to help get it over the line are always appreciated :)

Thanks for posting! I’d suggest this to anyone that wants a stateless setup method which uses standard SSH key/password auth. sish also has support for internal tunnels (hidden from the world and accessible with local/remote SSH forwards), SNI tunnels (zero trust TLS tunnels), TCP, and of course HTTP(S)/WS. Also does request inspection ala actual ngrok :)

Disclaimer: I’m the author and have done tunneling for years

Added benefit is sish handles all of the hostname/certificate provisioning on its own and does things like internal tunnels, TCP tunnels, and gives you a little website debugging tool as well. All in a single binary :)

Disclaimer: I'm the author of sish

Yep you’re right! My example was done with a CNAME on a subdomain (replaced the domain for privacy), and most providers provide flattening so I didn’t even think about it! I’ll update the copy to mention that.