diff options
author | Mattes D <github@xoft.cz> | 2014-07-16 13:30:57 +0200 |
---|---|---|
committer | Mattes D <github@xoft.cz> | 2014-07-16 13:30:57 +0200 |
commit | e444106d0924b1faecc61e50ca27a1d9c7fd7c9f (patch) | |
tree | 3d3aa66b0bf8ed4063fbda9ce2ddef62d9185fab /src/Protocol/Authenticator.h | |
parent | Fixed a DropSpenser AddFace bug (diff) | |
parent | Suggestions (diff) | |
download | cuberite-e444106d0924b1faecc61e50ca27a1d9c7fd7c9f.tar cuberite-e444106d0924b1faecc61e50ca27a1d9c7fd7c9f.tar.gz cuberite-e444106d0924b1faecc61e50ca27a1d9c7fd7c9f.tar.bz2 cuberite-e444106d0924b1faecc61e50ca27a1d9c7fd7c9f.tar.lz cuberite-e444106d0924b1faecc61e50ca27a1d9c7fd7c9f.tar.xz cuberite-e444106d0924b1faecc61e50ca27a1d9c7fd7c9f.tar.zst cuberite-e444106d0924b1faecc61e50ca27a1d9c7fd7c9f.zip |
Diffstat (limited to 'src/Protocol/Authenticator.h')
-rw-r--r-- | src/Protocol/Authenticator.h | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/src/Protocol/Authenticator.h b/src/Protocol/Authenticator.h index 211f51394..244d94c0b 100644 --- a/src/Protocol/Authenticator.h +++ b/src/Protocol/Authenticator.h @@ -23,6 +23,11 @@ // fwd: "cRoot.h" class cRoot; +namespace Json +{ + class Value; +} + @@ -73,13 +78,19 @@ private: AString m_Server; AString m_Address; + AString m_PropertiesAddress; bool m_ShouldAuthenticate; /** cIsThread override: */ virtual void Execute(void) override; - /** Returns true if the user authenticated okay, false on error; iLevel is the recursion deptht (bails out if too deep) */ - bool AuthWithYggdrasil(AString & a_UserName, const AString & a_ServerId, AString & a_UUID); + /** Connects to a hostname using SSL, sends given data, and sets the response, returning whether all was successful or not */ + bool SecureGetFromAddress(const AString & a_CACerts, const AString & a_ExpectedPeerName, const AString & a_Request, AString & a_Response); + + /** Returns true if the user authenticated okay, false on error + Sets the username, UUID, and properties (i.e. skin) fields + */ + bool AuthWithYggdrasil(AString & a_UserName, const AString & a_ServerId, AString & a_UUID, Json::Value & a_Properties); }; |