LeviLamina
Loading...
Searching...
No Matches
FileSecureStorage.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/deps/core/secure_storage/SecureStorage.h"
7
8// auto generated forward declare list
9// clang-format off
12namespace Core { class Path; }
13namespace Core { class PathView; }
14namespace Json { class Value; }
15// clang-format on
16
17class FileSecureStorage : public ::SecureStorage {
18public:
19 // FileSecureStorage inner types declare
20 // clang-format off
21 class StorageSystem;
23 // clang-format on
24
25 // FileSecureStorage inner types define
27 public:
28 // virtual functions
29 // NOLINTBEGIN
30 virtual bool getData(::std::string& output, ::Core::Path path);
31
32 virtual void setData(::std::string const& data, ::Core::Path path);
33
34 virtual ~StorageSystem() = default;
35 // NOLINTEND
36
37 public:
38 // virtual function thunks
39 // NOLINTBEGIN
40 MCNAPI bool $getData(::std::string& output, ::Core::Path path);
41
42 MCNAPI void $setData(::std::string const& data, ::Core::Path path);
43
44
45 // NOLINTEND
46
47 public:
48 // vftables
49 // NOLINTBEGIN
50 MCNAPI static void** $vftable();
51 // NOLINTEND
52 };
53
54 class FileStorageSystem : public ::FileSecureStorage::StorageSystem {
55 public:
56 // member variables
57 // NOLINTBEGIN
59 // NOLINTEND
60
61 public:
62 // prevent constructor by default
63 FileStorageSystem& operator=(FileStorageSystem const&);
64 FileStorageSystem(FileStorageSystem const&);
65 FileStorageSystem();
66
67 public:
68 // virtual functions
69 // NOLINTBEGIN
70 virtual bool getData(::std::string& output, ::Core::Path path) /*override*/;
71
72 virtual void setData(::std::string const& data, ::Core::Path path) /*override*/;
73 // NOLINTEND
74
75 public:
76 // virtual function thunks
77 // NOLINTBEGIN
78 MCNAPI bool $getData(::std::string& output, ::Core::Path path);
79
80 MCNAPI void $setData(::std::string const& data, ::Core::Path path);
81
82
83 // NOLINTEND
84
85 public:
86 // vftables
87 // NOLINTBEGIN
88 MCNAPI static void** $vftable();
89 // NOLINTEND
90 };
91
92public:
93 // member variables
94 // NOLINTBEGIN
105 // NOLINTEND
106
107public:
108 // prevent constructor by default
109 FileSecureStorage& operator=(FileSecureStorage const&);
110 FileSecureStorage(FileSecureStorage const&);
111 FileSecureStorage();
112
113public:
114 // virtual functions
115 // NOLINTBEGIN
116 virtual ~FileSecureStorage() /*override*/;
117
118 virtual bool add(::std::string const& key, ::std::string const& value) /*override*/;
119
120 virtual bool addOrUpdate(::std::string const& key, ::std::string const& value) /*override*/;
121
122 virtual bool remove(::std::string const& key) /*override*/;
123
124 virtual bool get(::std::string const& key, ::std::string& outValue) /*override*/;
125 // NOLINTEND
126
127public:
128 // member functions
129 // NOLINTBEGIN
131 ::Core::PathView settingsPath,
132 ::Core::PathView baseSettingsPath,
133 ::ISecureStorageKeySystem* sskSystem,
134 ::Core::PathView userDataPath,
136 );
137
138 MCNAPI ::std::string _contentKeyObfuscator(::std::string const& codedData, ::std::string const& identifier);
139
140 MCNAPI ::SecureStorageKey _getSecureStorageKey() const;
141
142#ifdef LL_PLAT_C
143 MCNAPI ::Json::Value _getStoredJson();
144#endif
145
146 MCNAPI bool _init(bool);
147
148 MCNAPI void _initalizeSymmetricEncyrption(::std::string& symmetricKey, bool force);
149
151 // NOLINTEND
152
153public:
154 // constructor thunks
155 // NOLINTBEGIN
156 MCNAPI void* $ctor(
157 ::Core::PathView settingsPath,
158 ::Core::PathView baseSettingsPath,
159 ::ISecureStorageKeySystem* sskSystem,
160 ::Core::PathView userDataPath,
162 );
163 // NOLINTEND
164
165public:
166 // destructor thunk
167 // NOLINTBEGIN
168 MCNAPI void $dtor();
169 // NOLINTEND
170
171public:
172 // virtual function thunks
173 // NOLINTBEGIN
174 MCNAPI bool $add(::std::string const& key, ::std::string const& value);
175
176 MCNAPI bool $addOrUpdate(::std::string const& key, ::std::string const& value);
177
178 MCNAPI bool $remove(::std::string const& key);
179
180 MCNAPI bool $get(::std::string const& key, ::std::string& outValue);
181
182
183 // NOLINTEND
184
185public:
186 // vftables
187 // NOLINTBEGIN
188 MCNAPI static void** $vftable();
189 // NOLINTEND
190};
Definition PathView.h:19
Definition Path.h:12
Definition FileSecureStorage.h:54
MCAPI bool $getData(::std::string &output, ::Core::Path path)
static MCAPI void ** $vftable()
MCAPI void $setData(::std::string const &data, ::Core::Path path)
Definition FileSecureStorage.h:26
MCAPI void $setData(::std::string const &data, ::Core::Path path)
static MCAPI void ** $vftable()
MCAPI bool $getData(::std::string &output, ::Core::Path path)
MCAPI bool $addOrUpdate(::std::string const &key, ::std::string const &value)
MCAPI void _rebuildSecureStorageFile()
MCAPI bool _init(bool)
MCAPI::SecureStorageKey _getSecureStorageKey() const
MCAPI bool $add(::std::string const &key, ::std::string const &value)
MCAPI bool $get(::std::string const &key, ::std::string &outValue)
MCAPI void _initalizeSymmetricEncyrption(::std::string &symmetricKey, bool force)
static MCAPI void ** $vftable()
MCAPI FileSecureStorage(::Core::PathView settingsPath, ::Core::PathView baseSettingsPath, ::ISecureStorageKeySystem *sskSystem, ::Core::PathView userDataPath, ::FileSecureStorage::StorageSystem *storage)
MCAPI bool $remove(::std::string const &key)
MCAPI::std::string _contentKeyObfuscator(::std::string const &codedData, ::std::string const &identifier)
MCAPI void $dtor()
MCAPI void * $ctor(::Core::PathView settingsPath, ::Core::PathView baseSettingsPath, ::ISecureStorageKeySystem *sskSystem, ::Core::PathView userDataPath, ::FileSecureStorage::StorageSystem *storage)
Definition ISecureStorageKeySystem.h:10
Definition Value.h:16
Definition SecureStorageKey.h:5
Definition Alias.h:14