fuzz: Add fuzzing harness for Socks5(...)

This commit is contained in:
practicalswift
2020-06-07 16:59:46 +00:00
parent b9f41df1ea
commit b22d4c1607
5 changed files with 166 additions and 8 deletions

View File

@@ -40,6 +40,13 @@ public:
bool randomize_credentials;
};
/** Credentials for proxy authentication */
struct ProxyCredentials
{
std::string username;
std::string password;
};
enum Network ParseNetwork(const std::string& net);
std::string GetNetworkName(enum Network net);
/** Return a vector of publicly routable Network names; optionally append NET_UNROUTABLE. */
@@ -77,4 +84,6 @@ bool SetSocketNonBlocking(const SOCKET& hSocket, bool fNonBlocking);
bool SetSocketNoDelay(const SOCKET& hSocket);
void InterruptSocks5(bool interrupt);
bool Socks5(const std::string& strDest, int port, const ProxyCredentials* auth, const Sock& socket);
#endif // BITCOIN_NETBASE_H