summaryrefslogtreecommitdiff
path: root/src/Network/Tox/Crypto/Handlers.hs
diff options
context:
space:
mode:
authorJames Crayne <jim.crayne@gmail.com>2018-05-29 00:54:28 +0000
committerJames Crayne <jim.crayne@gmail.com>2018-05-29 00:54:28 +0000
commitf2e7d76a22681beabcfdbc727b3fe320d34af7e5 (patch)
tree8a7e26847d8550c42cc70dbffbbcf66c16c58b15 /src/Network/Tox/Crypto/Handlers.hs
parent8980cc601aad0851e7a3f0ddcf55f1ad3fe6963d (diff)
netCrypto function, ready for testing?
Diffstat (limited to 'src/Network/Tox/Crypto/Handlers.hs')
-rw-r--r--src/Network/Tox/Crypto/Handlers.hs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/Network/Tox/Crypto/Handlers.hs b/src/Network/Tox/Crypto/Handlers.hs
index bffb4280..0e349196 100644
--- a/src/Network/Tox/Crypto/Handlers.hs
+++ b/src/Network/Tox/Crypto/Handlers.hs
@@ -7,7 +7,7 @@ import Network.QueryResponse
7import Network.Tox.NodeId 7import Network.Tox.NodeId
8import Network.Tox.Crypto.Transport 8import Network.Tox.Crypto.Transport
9import Network.Tox.DHT.Transport (Cookie(..),CookieData(..), CookieRequest(..), NoSpam(..)) 9import Network.Tox.DHT.Transport (Cookie(..),CookieData(..), CookieRequest(..), NoSpam(..))
10import Network.Tox.DHT.Handlers (Client, cookieRequest, cookieRequestH ) 10import Network.Tox.DHT.Handlers (Client, cookieRequest, createCookie )
11import Crypto.Tox 11import Crypto.Tox
12import Control.Concurrent.STM 12import Control.Concurrent.STM
13import Network.Address 13import Network.Address
@@ -212,7 +212,7 @@ newHandShakeData crypto basenonce (HParam {hpOtherCookie,hpMySecretKey,hpCookieR
212 = do 212 = do
213 freshCookie 213 freshCookie
214 <- case nodeInfo (key2id hpCookieRemoteDhtkey) addr of 214 <- case nodeInfo (key2id hpCookieRemoteDhtkey) addr of
215 Right nodeinfo -> Just <$> cookieRequestH crypto nodeinfo (CookieRequest hpCookieRemotePubkey) 215 Right nodeinfo -> Just <$> createCookie crypto nodeinfo hpCookieRemotePubkey
216 Left er -> return Nothing 216 Left er -> return Nothing
217 let hinit = hashInit 217 let hinit = hashInit
218 Cookie n24 encrypted = hpOtherCookie 218 Cookie n24 encrypted = hpOtherCookie