separate class TransitTunnelBuildMsgHandler for tunnel build messages

This commit is contained in:
orignal
2024-11-16 16:05:46 -05:00
parent 3c608ec07c
commit 0c5f39ad81
4 changed files with 23 additions and 8 deletions

View File

@@ -109,8 +109,20 @@ namespace tunnel
const i2p::crypto::AESKey& layerKey, const i2p::crypto::AESKey& ivKey,
bool isGateway, bool isEndpoint);
void HandleShortTransitTunnelBuildMsg (std::shared_ptr<I2NPMessage> msg);
void HandleVariableTransitTunnelBuildMsg (std::shared_ptr<I2NPMessage> msg);
class TransitTunnelBuildMsgHandler
{
public:
void Start () {};
void Stop () {};
void HandleShortTransitTunnelBuildMsg (std::shared_ptr<I2NPMessage>&& msg);
void HandleVariableTransitTunnelBuildMsg (std::shared_ptr<I2NPMessage>&& msg);
private:
bool HandleBuildRequestRecords (int num, uint8_t * records, uint8_t * clearText);
};
}
}