diff options
| author | 2023-06-05 21:43:43 -0700 | |
|---|---|---|
| committer | 2023-06-05 21:43:43 -0700 | |
| commit | cb95d7fe1b6d81899fe6b279400da2c991e3132c (patch) | |
| tree | a856ac45b1053009c4c11ee141c49d7faa4c8a19 /src/core/crypto/key_manager.cpp | |
| parent | Merge pull request #10611 from liamwhite/audio-deadlock (diff) | |
| parent | Merge pull request #10633 from t895/variable-surface-ratio (diff) | |
| download | yuzu-cb95d7fe1b6d81899fe6b279400da2c991e3132c.tar.gz yuzu-cb95d7fe1b6d81899fe6b279400da2c991e3132c.tar.xz yuzu-cb95d7fe1b6d81899fe6b279400da2c991e3132c.zip | |
Merge pull request #10508 from yuzu-emu/lime
Project Lime - yuzu Android Port
Diffstat (limited to 'src/core/crypto/key_manager.cpp')
| -rw-r--r-- | src/core/crypto/key_manager.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/core/crypto/key_manager.cpp b/src/core/crypto/key_manager.cpp index 65a9fe802..4ff2c50e5 100644 --- a/src/core/crypto/key_manager.cpp +++ b/src/core/crypto/key_manager.cpp | |||
| @@ -569,6 +569,10 @@ std::optional<std::pair<Key128, Key128>> ParseTicket(const Ticket& ticket, | |||
| 569 | } | 569 | } |
| 570 | 570 | ||
| 571 | KeyManager::KeyManager() { | 571 | KeyManager::KeyManager() { |
| 572 | ReloadKeys(); | ||
| 573 | } | ||
| 574 | |||
| 575 | void KeyManager::ReloadKeys() { | ||
| 572 | // Initialize keys | 576 | // Initialize keys |
| 573 | const auto yuzu_keys_dir = Common::FS::GetYuzuPath(Common::FS::YuzuPath::KeysDir); | 577 | const auto yuzu_keys_dir = Common::FS::GetYuzuPath(Common::FS::YuzuPath::KeysDir); |
| 574 | 578 | ||
| @@ -702,6 +706,10 @@ void KeyManager::LoadFromFile(const std::filesystem::path& file_path, bool is_ti | |||
| 702 | } | 706 | } |
| 703 | } | 707 | } |
| 704 | 708 | ||
| 709 | bool KeyManager::AreKeysLoaded() const { | ||
| 710 | return !s128_keys.empty() && !s256_keys.empty(); | ||
| 711 | } | ||
| 712 | |||
| 705 | bool KeyManager::BaseDeriveNecessary() const { | 713 | bool KeyManager::BaseDeriveNecessary() const { |
| 706 | const auto check_key_existence = [this](auto key_type, u64 index1 = 0, u64 index2 = 0) { | 714 | const auto check_key_existence = [this](auto key_type, u64 index1 = 0, u64 index2 = 0) { |
| 707 | return !HasKey(key_type, index1, index2); | 715 | return !HasKey(key_type, index1, index2); |