Mercurial > 510Connectbot
comparison src/ch/ethz/ssh2/transport/ClientKexManager.java @ 287:db9b028016de ganymed
start conversion from trilead to ganymed
author | Carl Byington <carl@five-ten-sg.com> |
---|---|
date | Fri, 18 Jul 2014 19:52:08 -0700 |
parents | 486df527ddc5 |
children | ab3a99f11a36 |
comparison
equal
deleted
inserted
replaced
286:4656869af8fe | 287:db9b028016de |
---|---|
56 | 56 |
57 protected boolean verifySignature(byte[] sig, byte[] hostkey) throws IOException { | 57 protected boolean verifySignature(byte[] sig, byte[] hostkey) throws IOException { |
58 if (kxs.np.server_host_key_algo.startsWith("ecdsa-sha2-")) { | 58 if (kxs.np.server_host_key_algo.startsWith("ecdsa-sha2-")) { |
59 byte[] rs = ECDSASHA2Verify.decodeSSHECDSASignature(sig); | 59 byte[] rs = ECDSASHA2Verify.decodeSSHECDSASignature(sig); |
60 ECPublicKey epk = ECDSASHA2Verify.decodeSSHECDSAPublicKey(hostkey); | 60 ECPublicKey epk = ECDSASHA2Verify.decodeSSHECDSAPublicKey(hostkey); |
61 log.debug(50, "Verifying ecdsa signature"); | 61 log.debug("Verifying ecdsa signature"); |
62 return ECDSASHA2Verify.verifySignature(kxs.H, rs, epk); | 62 return ECDSASHA2Verify.verifySignature(kxs.H, rs, epk); |
63 } | 63 } |
64 if (kxs.np.server_host_key_algo.equals("ssh-rsa")) { | 64 if (kxs.np.server_host_key_algo.equals("ssh-rsa")) { |
65 byte[] rs = RSASHA1Verify.decodeSSHRSASignature(sig); | 65 byte[] rs = RSASHA1Verify.decodeSSHRSASignature(sig); |
66 RSAPublicKey rpk = RSASHA1Verify.decodeSSHRSAPublicKey(hostkey); | 66 RSAPublicKey rpk = RSASHA1Verify.decodeSSHRSAPublicKey(hostkey); |