reply with relay tag only if accept tunnels

This commit is contained in:
orignal
2026-01-25 13:57:31 -05:00
parent c87e656655
commit 7b43e10b88
+7 -4
View File
@@ -1636,11 +1636,14 @@ namespace transport
LogPrint (eLogDebug, "SSU2: RelayTagRequest");
if (!m_RelayTag)
{
auto addr = FindLocalAddress ();
if (addr && addr->IsIntroducer ())
if (i2p::context.AcceptsTunnels())
{
RAND_bytes ((uint8_t *)&m_RelayTag, 4);
m_Server.AddRelay (m_RelayTag, shared_from_this ());
auto addr = FindLocalAddress ();
if (addr && addr->IsIntroducer ())
{
RAND_bytes ((uint8_t *)&m_RelayTag, 4);
m_Server.AddRelay (m_RelayTag, shared_from_this ());
}
}
}
break;