summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Cady <d@jerkface.net>2020-05-05 19:29:57 -0400
committerAndrew Cady <d@jerkface.net>2020-05-05 19:30:30 -0400
commitbcf603a5ebdfc5925ccfd928cbea5c4266f7efaf (patch)
tree2b19a7f9745a2b56a649bdae5bb4faae98a7234f
parent0ed32430c0c93f82ed62492e9a897cd0babece13 (diff)
fix cryptonomic.net URL, avoid use of SHA-1
-rw-r--r--lib/Kiki.hs4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/Kiki.hs b/lib/Kiki.hs
index 02ac397..870bbba 100644
--- a/lib/Kiki.hs
+++ b/lib/Kiki.hs
@@ -580,8 +580,8 @@ sshKeyToHostname sshkey = do
580 case rsaKeyFromPacket sshkey of 580 case rsaKeyFromPacket sshkey of
581 Just (RSAKey (MPI n) (MPI e)) -> do 581 Just (RSAKey (MPI n) (MPI e)) -> do
582 let blob = SSH.sshrsa e n 582 let blob = SSH.sshrsa e n
583 sha1 = C.hashlazy blob :: C.Digest C.SHA1 583 sum = C.hashlazy blob :: C.Digest C.SHA256
584 Char8.fromStrict (convertToBase Base16 sha1) <> ".ssh-rsa.cryptonomic.net" 584 Char8.fromStrict (convertToBase Base16 sum) <> ".ssh-rsa.cryptonomic.net"
585 Nothing -> "" 585 Nothing -> ""
586 586
587peerConnectionName :: Peer -> Char8.ByteString 587peerConnectionName :: Peer -> Char8.ByteString