summaryrefslogtreecommitdiff
path: root/src/Network/Tox/Session.hs
diff options
context:
space:
mode:
authorJoe Crayne <joe@jerkface.net>2018-11-01 21:51:00 -0400
committerJoe Crayne <joe@jerkface.net>2018-11-02 00:21:52 -0400
commit1b3b665cb8413ed519fab1fa560716736676fa59 (patch)
tree413491b8429dc3986a576dea037956342ca5ef2d /src/Network/Tox/Session.hs
parentb9b1a68f1a440f36b5f3b7a7acdd3d0e9a09a2a2 (diff)
Comments and debug prints.
Diffstat (limited to 'src/Network/Tox/Session.hs')
-rw-r--r--src/Network/Tox/Session.hs8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/Network/Tox/Session.hs b/src/Network/Tox/Session.hs
index c672087f..968b3503 100644
--- a/src/Network/Tox/Session.hs
+++ b/src/Network/Tox/Session.hs
@@ -116,10 +116,14 @@ plainHandshakeH :: SessionParams
116plainHandshakeH sp saddr skey handshake = do 116plainHandshakeH sp saddr skey handshake = do
117 let hd = runIdentity $ handshakeData handshake 117 let hd = runIdentity $ handshakeData handshake
118 prelude = show saddr ++ " --> " 118 prelude = show saddr ++ " --> "
119 dput XNetCrypto $ prelude ++ "handshake: " ++ show (otherCookie hd, baseNonce hd) 119 dput XNetCrypto $ unlines $ map (prelude ++)
120 [ "handshake: auth=" ++ show (handshakeCookie handshake)
121 , " : issuing=" ++ show (otherCookie hd)
122 , " : baseNonce=" ++ show (baseNonce hd)
123 ]
120 sent <- spGetSentHandshake sp skey saddr (handshakeCookie handshake) (otherCookie hd) 124 sent <- spGetSentHandshake sp skey saddr (handshakeCookie handshake) (otherCookie hd)
121 -- TODO: this is always returning sent = Nothing 125 -- TODO: this is always returning sent = Nothing
122 dput XNetCrypto $ " <-- (cached) handshake baseNonce" ++ show (fmap (baseNonce . snd) sent) 126 dput XNetCrypto $ " <-- (cached) handshake baseNonce " ++ show (fmap (baseNonce . snd) sent)
123 forM_ sent $ \(hd_skey,hd_sent) -> do 127 forM_ sent $ \(hd_skey,hd_sent) -> do
124 sk <- SessionKeys (spCrypto sp) 128 sk <- SessionKeys (spCrypto sp)
125 hd_skey 129 hd_skey