On Mon, Nov 08, 2004 at 07:16:01PM +1100, Someone wrote: > > 2. SSH does not impose time restrictions on a session whilst kerberos > > does (Prevents > > replay attacks) > > From memory, SSH uses some form of challenge/response to set things up, so a > replay attack wouldn't be feasible.
And it's fascinating stuff. Successful replay attempts are an extreme improbability with SSH, because before anything at all gets sent over the wire, a key exchange* occurs to establish a key for one of the faster (and just as secure) block cipher algorithms like DES or Blowfish (btw, DES and Blowfish are both very similar algorithms. In essence they're both Feistel ciphers. For some reason though, Blowfish is substantially faster in practice, even though at first glance its "round" function seems more complex). This key will be different on each connection attempt, and is dependent on the entropy pools on *both* ends of the connection. On Linux, entropy pools are quite good these days, and you don't get "inferior" random data if the kernel figures it can't guarantee randomness -- instead it tells you that the entropy pool is empty. If you don't believe me, try running "md5sum /dev/urandom". It'll take a while but it will terminate. [*] a secure key exchange. The one that is traditionally taught in crypto courses is Diffie-Hellman. I don't know if Diffie-Hellman is still used though. The difficulty of breaking Diffie-Hellman is in solving "the discrete logarithm problem" (which is a pretty hard problem). The problem with Diffie-Hellman is that it's susceptible to "man-in-the-middle" attacks. SSH gets around this by storing the digital finger-print of servers you connect to. If the finger-print doesn't match when you re-connect, you know something's up (that's what those errors mean that require you to edit .ssh/known_hosts). Sorry, I may have taken this a little off-topic. I find the maths behind it fascinating. I hope I've helped in evaluating the real security of SSH though and haven't provided too much erroneous information. James. -- "Now, there are no problems only opportunities. However, this seemed to be an insurmountable opportunity." - http://www.surfare.net/~toolman/temp/diagram.html -- SLUG - Sydney Linux User's Group Mailing List - http://slug.org.au/ Subscription info and FAQs: http://slug.org.au/faq/mailinglists.html
