mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2025-04-28 11:47:48 +02:00
manage tunnel pools
This commit is contained in:
parent
cba18faa87
commit
ab23327da6
7 changed files with 70 additions and 46 deletions
|
@ -300,7 +300,7 @@ namespace stream
|
|||
|
||||
StreamingDestination * sharedLocalDestination = nullptr;
|
||||
|
||||
StreamingDestination::StreamingDestination (): m_TunnelPool (this), m_LeaseSet (nullptr)
|
||||
StreamingDestination::StreamingDestination (): m_LeaseSet (nullptr)
|
||||
{
|
||||
// TODO: read from file later
|
||||
m_Keys = i2p::data::CreateRandomKeys ();
|
||||
|
@ -308,6 +308,7 @@ namespace stream
|
|||
m_IdentHash = i2p::data::CalculateIdentHash (m_Identity);
|
||||
m_SigningPrivateKey.Initialize (i2p::crypto::dsap, i2p::crypto::dsaq, i2p::crypto::dsag,
|
||||
CryptoPP::Integer (m_Keys.signingPrivateKey, 20));
|
||||
i2p::tunnel::tunnels.CreateTunnelPool (this);
|
||||
}
|
||||
|
||||
StreamingDestination::~StreamingDestination ()
|
||||
|
@ -316,16 +317,6 @@ namespace stream
|
|||
DeleteI2NPMessage (m_LeaseSet);
|
||||
}
|
||||
|
||||
void StreamingDestination::Start ()
|
||||
{
|
||||
m_TunnelPool.CreateTunnels ();
|
||||
}
|
||||
|
||||
void StreamingDestination::Stop ()
|
||||
{
|
||||
// TODO:
|
||||
}
|
||||
|
||||
void StreamingDestination::HandleNextPacket (Packet * packet)
|
||||
{
|
||||
uint32_t sendStreamID = packet->GetSendStreamID ();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue