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; }
14// clang-format on
15
16class FileSecureStorage : public ::SecureStorage {
17public:
18 // FileSecureStorage inner types declare
19 // clang-format off
20 class StorageSystem;
22 // clang-format on
23
24 // FileSecureStorage inner types define
26 public:
27 // virtual functions
28 // NOLINTBEGIN
29 virtual bool getData(::std::string& output, ::Core::Path path);
30
31 virtual void setData(::std::string const& data, ::Core::Path path);
32
33 virtual ~StorageSystem();
34 // NOLINTEND
35
36 public:
37 // destructor thunk
38 // NOLINTBEGIN
39 MCNAPI void $dtor();
40 // NOLINTEND
41
42 public:
43 // virtual function thunks
44 // NOLINTBEGIN
45 MCNAPI bool $getData(::std::string& output, ::Core::Path path);
46
47 MCNAPI void $setData(::std::string const& data, ::Core::Path path);
48
49
50 // NOLINTEND
51 };
52
53 class FileStorageSystem : public ::FileSecureStorage::StorageSystem {
54 public:
55 // member variables
56 // NOLINTBEGIN
58 // NOLINTEND
59
60 public:
61 // prevent constructor by default
62 FileStorageSystem& operator=(FileStorageSystem const&);
63 FileStorageSystem(FileStorageSystem const&);
64 FileStorageSystem();
65
66 public:
67 // virtual functions
68 // NOLINTBEGIN
69 virtual bool getData(::std::string& output, ::Core::Path path) /*override*/;
70
71 virtual void setData(::std::string const& data, ::Core::Path path) /*override*/;
72 // NOLINTEND
73
74 public:
75 // virtual function thunks
76 // NOLINTBEGIN
77 MCNAPI bool $getData(::std::string& output, ::Core::Path path);
78
79 MCNAPI void $setData(::std::string const& data, ::Core::Path path);
80
81
82 // NOLINTEND
83 };
84
85public:
86 // member variables
87 // NOLINTBEGIN
98 // NOLINTEND
99
100public:
101 // prevent constructor by default
102 FileSecureStorage& operator=(FileSecureStorage const&);
103 FileSecureStorage(FileSecureStorage const&);
104 FileSecureStorage();
105
106public:
107 // virtual functions
108 // NOLINTBEGIN
109 virtual ~FileSecureStorage() /*override*/;
110
111 virtual bool add(::std::string const& key, ::std::string const& value) /*override*/;
112
113 virtual bool addOrUpdate(::std::string const& key, ::std::string const& value) /*override*/;
114
115 virtual bool remove(::std::string const& key) /*override*/;
116
117 virtual bool get(::std::string const& key, ::std::string& outValue) /*override*/;
118 // NOLINTEND
119
120public:
121 // member functions
122 // NOLINTBEGIN
124 ::Core::PathView settingsPath,
125 ::Core::PathView baseSettingsPath,
126 ::ISecureStorageKeySystem* sskSystem,
127 ::Core::PathView userDataPath,
129 );
130
131 MCNAPI ::std::string _contentKeyObfuscator(::std::string const& codedData, ::std::string const& identifier);
132
133 MCNAPI ::SecureStorageKey _getSecureStorageKey() const;
134
135#ifdef LL_PLAT_C
136 MCNAPI bool _init(bool expectedFailure);
137#endif
138
139#ifdef LL_PLAT_S
140 MCNAPI bool _init(bool expectedFailure);
141#endif
142
143 MCNAPI void _initalizeSymmetricEncyrption(::std::string& symmetricKey, bool force);
144
146 // NOLINTEND
147
148public:
149 // constructor thunks
150 // NOLINTBEGIN
151 MCNAPI void* $ctor(
152 ::Core::PathView settingsPath,
153 ::Core::PathView baseSettingsPath,
154 ::ISecureStorageKeySystem* sskSystem,
155 ::Core::PathView userDataPath,
157 );
158 // NOLINTEND
159
160public:
161 // destructor thunk
162 // NOLINTBEGIN
163 MCNAPI void $dtor();
164 // NOLINTEND
165
166public:
167 // virtual function thunks
168 // NOLINTBEGIN
169 MCNAPI bool $add(::std::string const& key, ::std::string const& value);
170
171 MCNAPI bool $addOrUpdate(::std::string const& key, ::std::string const& value);
172
173 MCNAPI bool $remove(::std::string const& key);
174
175 MCNAPI bool $get(::std::string const& key, ::std::string& outValue);
176
177
178 // NOLINTEND
179};
Definition PathView.h:19
Definition Path.h:12
Definition FileSecureStorage.h:53
MCAPI bool $getData(::std::string &output, ::Core::Path path)
MCAPI void $setData(::std::string const &data, ::Core::Path path)
Definition FileSecureStorage.h:25
MCAPI void $setData(::std::string const &data, ::Core::Path path)
MCAPI bool $getData(::std::string &output, ::Core::Path path)
MCAPI bool $addOrUpdate(::std::string const &key, ::std::string const &value)
MCAPI void _rebuildSecureStorageFile()
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)
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 SecureStorageKey.h:5
Definition Alias.h:14