Added TLS fingerprint validation.
This commit is contained in:
parent
bc9130ded3
commit
7da9e7a599
5 changed files with 78 additions and 9 deletions
|
@ -39,17 +39,20 @@ public:
|
|||
|
||||
bool handshake();
|
||||
bool send(const char *data, size_t size);
|
||||
const char *tlsVersion() const;
|
||||
const char *fingerprint() const;
|
||||
const char *version() const;
|
||||
void read(const char *data, size_t size);
|
||||
|
||||
private:
|
||||
bool send();
|
||||
bool verify();
|
||||
bool verify(X509 *cert);
|
||||
bool verifyFingerprint(X509 *cert);
|
||||
|
||||
BIO *m_readBio;
|
||||
BIO *m_writeBio;
|
||||
bool m_ready;
|
||||
char m_buf[1024 * 2];
|
||||
char m_fingerprint[32 * 2 + 8];
|
||||
Client *m_client;
|
||||
SSL *m_ssl;
|
||||
SSL_CTX *m_ctx;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue