mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2025-04-28 11:47:48 +02:00
published encrypted flag
This commit is contained in:
parent
db107602bd
commit
e6a09b49c9
3 changed files with 21 additions and 5 deletions
|
@ -303,6 +303,11 @@ namespace data
|
|||
}
|
||||
}
|
||||
if (flags & LEASESET2_FLAG_UNPUBLISHED_LEASESET) m_IsPublic = false;
|
||||
if (flags & LEASESET2_FLAG_PUBLISHED_ENCRYPTED)
|
||||
{
|
||||
m_IsPublishedEncrypted = true;
|
||||
m_IsPublic = true;
|
||||
}
|
||||
// type specific part
|
||||
size_t s = 0;
|
||||
switch (m_StoreType)
|
||||
|
@ -742,7 +747,8 @@ namespace data
|
|||
|
||||
LocalLeaseSet2::LocalLeaseSet2 (uint8_t storeType, const i2p::data::PrivateKeys& keys,
|
||||
uint16_t keyType, uint16_t keyLen, const uint8_t * encryptionPublicKey,
|
||||
std::vector<std::shared_ptr<i2p::tunnel::InboundTunnel> > tunnels, bool isPublic):
|
||||
std::vector<std::shared_ptr<i2p::tunnel::InboundTunnel> > tunnels,
|
||||
bool isPublic, bool isPublishedEncrypted):
|
||||
LocalLeaseSet (keys.GetPublic (), nullptr, 0)
|
||||
{
|
||||
auto identity = keys.GetPublic ();
|
||||
|
@ -757,6 +763,11 @@ namespace data
|
|||
flags |= LEASESET2_FLAG_OFFLINE_KEYS;
|
||||
m_BufferLen += keys.GetOfflineSignature ().size ();
|
||||
}
|
||||
if (isPublishedEncrypted)
|
||||
{
|
||||
flags |= LEASESET2_FLAG_PUBLISHED_ENCRYPTED;
|
||||
isPublic = true;
|
||||
}
|
||||
if (!isPublic) flags |= LEASESET2_FLAG_UNPUBLISHED_LEASESET;
|
||||
|
||||
m_Buffer = new uint8_t[m_BufferLen + 1];
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue