Browse Source

moved HandleI2NPMessage to GarlicDestination level

pull/102/head
orignal 10 years ago
parent
commit
22937e1b54
  1. 2
      Destination.h
  2. 1
      Garlic.h
  3. 1
      Identity.h
  4. 2
      RouterContext.h

2
Destination.h

@ -44,10 +44,10 @@ namespace stream
const i2p::data::PrivateKeys& GetPrivateKeys () const { return m_Keys; }; const i2p::data::PrivateKeys& GetPrivateKeys () const { return m_Keys; };
const uint8_t * GetEncryptionPrivateKey () const { return m_EncryptionPrivateKey; }; const uint8_t * GetEncryptionPrivateKey () const { return m_EncryptionPrivateKey; };
const uint8_t * GetEncryptionPublicKey () const { return m_EncryptionPublicKey; }; const uint8_t * GetEncryptionPublicKey () const { return m_EncryptionPublicKey; };
void HandleI2NPMessage (const uint8_t * buf, size_t len);
// implements GarlicDestination // implements GarlicDestination
const i2p::data::LeaseSet * GetLeaseSet (); const i2p::data::LeaseSet * GetLeaseSet ();
void HandleI2NPMessage (const uint8_t * buf, size_t len);
// override GarlicDestination // override GarlicDestination
void ProcessGarlicMessage (I2NPMessage * msg); void ProcessGarlicMessage (I2NPMessage * msg);

1
Garlic.h

@ -99,6 +99,7 @@ namespace garlic
virtual void SetLeaseSetUpdated (); virtual void SetLeaseSetUpdated ();
virtual const i2p::data::LeaseSet * GetLeaseSet () = 0; // TODO virtual const i2p::data::LeaseSet * GetLeaseSet () = 0; // TODO
virtual void HandleI2NPMessage (const uint8_t * buf, size_t len) = 0;
protected: protected:

1
Identity.h

@ -242,7 +242,6 @@ namespace data
virtual const PrivateKeys& GetPrivateKeys () const = 0; virtual const PrivateKeys& GetPrivateKeys () const = 0;
virtual const uint8_t * GetEncryptionPrivateKey () const = 0; virtual const uint8_t * GetEncryptionPrivateKey () const = 0;
virtual const uint8_t * GetEncryptionPublicKey () const = 0; virtual const uint8_t * GetEncryptionPublicKey () const = 0;
virtual void HandleI2NPMessage (const uint8_t * buf, size_t len) = 0;
const IdentityEx& GetIdentity () const { return GetPrivateKeys ().GetPublic (); }; const IdentityEx& GetIdentity () const { return GetPrivateKeys ().GetPublic (); };
const IdentHash& GetIdentHash () const { return GetIdentity ().GetIdentHash (); }; const IdentHash& GetIdentHash () const { return GetIdentity ().GetIdentHash (); };

2
RouterContext.h

@ -41,10 +41,10 @@ namespace i2p
const uint8_t * GetEncryptionPrivateKey () const { return m_Keys.GetPrivateKey (); }; const uint8_t * GetEncryptionPrivateKey () const { return m_Keys.GetPrivateKey (); };
const uint8_t * GetEncryptionPublicKey () const { return GetIdentity ().GetStandardIdentity ().publicKey; }; const uint8_t * GetEncryptionPublicKey () const { return GetIdentity ().GetStandardIdentity ().publicKey; };
void SetLeaseSetUpdated () {}; void SetLeaseSetUpdated () {};
void HandleI2NPMessage (const uint8_t * buf, size_t len);
// implements GarlicDestination // implements GarlicDestination
const i2p::data::LeaseSet * GetLeaseSet () { return nullptr; }; const i2p::data::LeaseSet * GetLeaseSet () { return nullptr; };
void HandleI2NPMessage (const uint8_t * buf, size_t len);
private: private:

Loading…
Cancel
Save