LeviLamina
Loading...
Searching...
No Matches
GameServerToken.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/certificates/identity/GameServerTokenValidationResult.h"
7#include "mc/deps/certificates/WebToken.h"
8
9// auto generated forward declare list
10// clang-format off
15// clang-format on
16
17class GameServerToken {
18public:
19 // member variables
20 // NOLINTBEGIN
21 ::ll::TypedStorage<1, 1, bool> mIsSelfSigned;
22 ::ll::TypedStorage<1, 1, bool> mIsValid;
23 ::ll::TypedStorage<1, 1, bool> mIsLocal;
24 ::ll::TypedStorage<8, 128, ::WebToken> mRawToken;
25 // NOLINTEND
26
27public:
28 // prevent constructor by default
29 GameServerToken();
30
31public:
32 // member functions
33 // NOLINTBEGIN
34 MCAPI explicit GameServerToken(::std::string const& tokenString);
35
36 MCAPI ::PlayerAuthenticationInfo getTrustedInfo() const;
37
38 MCAPI bool hasMatchingIssuer(::MinecraftServiceKeyManager const& serviceKeyManager);
39 // NOLINTEND
40
41public:
42 // static functions
43 // NOLINTBEGIN
44 MCAPI static bool _checkExpiration(::WebToken const& token, int64 currentTime);
45
46 MCAPI static ::GameServerTokenValidationResult _validate(
47 ::WebToken const& token,
48 ::MinecraftServiceKeyManager const& keyManager,
49 int64 currentTime,
50 bool checkExpiration
51 );
52
53 MCAPI static ::GameServerTokenValidationResult
54 _validateSelfSigned(::WebToken const& token, int64 currentTime, bool checkExpiration);
55
56#ifdef LL_PLAT_C
57 MCAPI static ::RawGameServerToken createLocal(
58 ::PrivateKeyManager const& signer,
59 int64 expirationDate,
60 ::std::string const& keyId,
61 ::PlayerAuthenticationInfo const& claims
62 );
63#endif
64 // NOLINTEND
65
66public:
67 // constructor thunks
68 // NOLINTBEGIN
69 MCAPI void* $ctor(::std::string const& tokenString);
70 // NOLINTEND
71};
Definition MinecraftServiceKeyManager.h:21
Definition PrivateKeyManager.h:10
Definition WebToken.h:17
Definition PlayerAuthenticationInfo.h:9
Definition RawGameServerToken.h:8