don't connect to unpublished NTCP2 addresses

This commit is contained in:
orignal 2018-07-18 14:19:12 -04:00
parent 910a9600bd
commit e0790700cd
4 changed files with 6 additions and 3 deletions

View file

@ -94,6 +94,7 @@ namespace data
{
Tag<32> staticKey;
Tag<16> iv;
bool isPublished = false;
};
struct Address
@ -124,6 +125,7 @@ namespace data
}
bool IsNTCP2 () const { return (bool)ntcp2; };
bool IsPublishedNTCP2 () const { return IsNTCP2 () && ntcp2->isPublished; };
};
typedef std::list<std::shared_ptr<Address> > Addresses;