mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2025-03-07 06:09:42 +00:00
take intro key from right address
This commit is contained in:
@@ -30,14 +30,15 @@ namespace transport
|
|||||||
if (router)
|
if (router)
|
||||||
{
|
{
|
||||||
// we are client
|
// we are client
|
||||||
auto address = router->GetSSUAddress (false);
|
auto address = IsV6 () ? router->GetSSUV6Address () : router->GetSSUAddress (true);
|
||||||
if (address) m_IntroKey = address->ssu->key;
|
if (address) m_IntroKey = address->ssu->key;
|
||||||
m_Data.AdjustPacketSize (router); // mtu
|
m_Data.AdjustPacketSize (router); // mtu
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
// we are server
|
// we are server
|
||||||
auto address = i2p::context.GetRouterInfo ().GetSSUAddress (false);
|
auto address = IsV6 () ? i2p::context.GetRouterInfo ().GetSSUV6Address () :
|
||||||
|
i2p::context.GetRouterInfo ().GetSSUAddress (true);
|
||||||
if (address) m_IntroKey = address->ssu->key;
|
if (address) m_IntroKey = address->ssu->key;
|
||||||
}
|
}
|
||||||
m_CreationTime = i2p::util::GetSecondsSinceEpoch ();
|
m_CreationTime = i2p::util::GetSecondsSinceEpoch ();
|
||||||
|
|||||||
Reference in New Issue
Block a user