‹ BackHN Continuity

Thread

Show HN: ssh ssh.place

184 points · 120 comments · jeninh

  1. raggi · · focus · HN ↗
    Time for your regular reminder that ssh has no PKI and is trivial to mitm during tofu.
    1. pzacik · · focus · HN ↗
      Yes, but what exactly would an attacker achieve by doing mitm here?
      1. raggi · · focus · HN ↗
        here, less than most, but look for ssh agents

        on terminal.shop, steal credit cards on jobs endpoints, perform identity theft on exe.dev, whatever you put on there

    2. kro · · focus · HN ↗
      I understand that most people don't use it and indeed rely on tofu, but the statement is not absolutely correct.

      ssh server keys can be authenticated using (the DNSSEC "CA" system and) SSHFP, and it's possible to setup a signing CA for the host key (similar to ssh certificates, however not applicable for foreign servers). And of course, the fingerprint could be advertised out of band e.g. on the homepage with tls

      1. raggi · · focus · HN ↗
        sshfp is not PKI. It's an option and it is off by default in ssh(1). In practice no one actually deploys it, exe.dev, terminal.shop, jobs.{whoever.com}, etc. I've yet to see an in the wild deployment. The aforementioned sites let you perform electronic payment transactions over ssh without it, which is probably a PCI violation tbh, but auditors aren't good enough.

        webpki is on by default.

    3. rvz · · focus · HN ↗
      Agreed. Amid all this hype, once again we continue to see such disregard for basic security implications and using ssh outside it's intended use-case; especially sshing into random servers.

      Now we wait for the discovery of an RCE, key leakage vulnerability or a security bypass that leads to a trivial mitm attack to magnify why ssh apps make no sense security wise.

    4. sph · · focus · HN ↗
      Acronyms are supposed to be capitalised. I do not belive you are talking about the soy product.

      <a href="https:&#x2F;&#x2F;en.wikipedia.org&#x2F;wiki&#x2F;Man-in-the-middle_attack" rel="nofollow">https:&#x2F;&#x2F;en.wikipedia.org&#x2F;wiki&#x2F;Man-in-the-middle_attack

      <a href="https:&#x2F;&#x2F;en.wikipedia.org&#x2F;wiki&#x2F;Trust_on_first_use" rel="nofollow">https:&#x2F;&#x2F;en.wikipedia.org&#x2F;wiki&#x2F;Trust_on_first_use

    5. tptacek · · focus · HN ↗
      SSH does in fact have a PKI, just not a global one. Large-fleet SSH installs all tend to use certificate authorities, for this reason (and to simplify SSO).
      1. raggi · · focus · HN ↗
        Fair!

        When I last harassed Crawshaw about this and we discussed bits, he submitted <a href="https:&#x2F;&#x2F;github.com&#x2F;C2SP&#x2F;C2SP&#x2F;blob&#x2F;main&#x2F;well-known-ssh-hosts.md" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;C2SP&#x2F;C2SP&#x2F;blob&#x2F;main&#x2F;well-known-ssh-hosts....

        Unfortunately neither of us has taken time (AFAIK) to go back and implement it anywhere.

        1. tptacek · · focus · HN ↗
          I don&#x27;t understand the impulse behind these things --- this is a bootstrap mechanism for a global PKI for SSH. But cold introductions to SSH hosts (that is, first connections to hosts you have no business or technical relationship with) virtually never happen. What problem does it solve?
          1. raggi · · focus · HN ↗
            When you see people advertising a coffee shop at a conference and people TOFU&#x27;ing on conference wifi then plugging in credit card numbers, the picture gets a little more clear.
            1. edmccard · · focus · HN ↗
              Do people at conferences buy coffee by SSH&#x27;ing into coffee shop servers?
              1. raggi · · focus · HN ↗
                i&#x27;ve seen it, so the answer is non-zero
            2. tptacek · · focus · HN ↗
              Right, I mean, I see the problem for browsers! Just not for SSH servers. (Capturing sessions like this used to be a contest at Usenix Security).
              1. raggi · · focus · HN ↗
                So really the trend I&#x27;m talking about here is people turning SSH into a browser, hosting apps behind SSH that expect a much higher volume of TOFU happening, which is a departure from the &quot;first time i setup my vps&quot; kind of case.

                Honestly at this point I&#x27;d be kind of happy if we could just use an x.509 cert from a webpki acme provider in the sshd and be done with it, for the host identity part.

Open on Hacker News to reply ↗

Unofficial Hacker News client; not affiliated with Y Combinator.