Browse Source

set SessionCreated state

pull/46/head
orignal 11 years ago
parent
commit
7300792033
  1. 3
      I2NPProtocol.cpp
  2. 2
      SSU.cpp

3
I2NPProtocol.cpp

@ -77,8 +77,7 @@ namespace i2p
} }
else // for SSU establishment else // for SSU establishment
{ {
auto rnd = i2p::context.GetRandomNumberGenerator (); msg.msgID = htobe32 (i2p::context.GetRandomNumberGenerator ().GenerateWord32 ());
msg.msgID = htobe32 (rnd.GenerateWord32 ());
msg.timestamp = htobe64 (2); // netID = 2 msg.timestamp = htobe64 (2); // netID = 2
} }
return CreateI2NPMessage (eI2NPDeliveryStatus, (uint8_t *)&msg, sizeof (msg)); return CreateI2NPMessage (eI2NPDeliveryStatus, (uint8_t *)&msg, sizeof (msg));

2
SSU.cpp

@ -309,7 +309,7 @@ namespace ssu
// encrypt message with intro key // encrypt message with intro key
FillHeaderAndEncrypt (PAYLOAD_TYPE_SESSION_CREATED, buf, 368, introKey, iv, introKey); FillHeaderAndEncrypt (PAYLOAD_TYPE_SESSION_CREATED, buf, 368, introKey, iv, introKey);
m_State = eSessionStateRequestSent; m_State = eSessionStateCreatedSent;
m_Server->Send (buf, 368, m_RemoteEndpoint); m_Server->Send (buf, 368, m_RemoteEndpoint);
} }

Loading…
Cancel
Save