mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2025-04-28 11:47:48 +02:00
random intro key
This commit is contained in:
parent
3dfb44de31
commit
c875ff923a
2 changed files with 7 additions and 4 deletions
|
@ -719,7 +719,10 @@ namespace data
|
|||
addr->date = 0;
|
||||
addr->ssu.reset (new SSUExt ());
|
||||
addr->ssu->mtu = mtu;
|
||||
memcpy (addr->ssu->key, key, 32);
|
||||
if (key)
|
||||
memcpy (addr->ssu->key, key, 32);
|
||||
else
|
||||
RAND_bytes (addr->ssu->key, 32);
|
||||
for (const auto& it: *m_Addresses) // don't insert same address twice
|
||||
if (*it == *addr) return;
|
||||
m_SupportedTransports |= addr->host.is_v6 () ? eSSUV6 : eSSUV4;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue