diff --git a/src/core/crypto/key_manager.cpp b/src/core/crypto/key_manager.cpp index 58faf9013b..1a06f614e2 100644 --- a/src/core/crypto/key_manager.cpp +++ b/src/core/crypto/key_manager.cpp @@ -557,12 +557,6 @@ static std::optional FindTicketOffset(const std::array& data) { } std::optional KeyManager::ParseTicketTitleKey(const Ticket& ticket) { - if (eticket_rsa_keypair == RSAKeyPair<2048>{}) { - LOG_WARNING(Crypto, - "Skipping ticket title key parsing due to missing ETicket RSA key-pair."); - return std::nullopt; - } - if (!ticket.IsValid()) { LOG_WARNING(Crypto, "Attempted to parse title key of invalid ticket."); return std::nullopt; @@ -587,6 +581,13 @@ std::optional KeyManager::ParseTicketTitleKey(const Ticket& ticket) { return ticket.GetData().title_key_common; } + if (eticket_rsa_keypair == RSAKeyPair<2048>{}) { + LOG_WARNING( + Crypto, + "Skipping personalized ticket title key parsing due to missing ETicket RSA key-pair."); + return std::nullopt; + } + mbedtls_mpi D; // RSA Private Exponent mbedtls_mpi N; // RSA Modulus mbedtls_mpi S; // Input @@ -1188,10 +1189,6 @@ void KeyManager::DeriveETicket(PartitionDataManager& data, } void KeyManager::PopulateTickets() { - if (eticket_rsa_keypair == RSAKeyPair<2048>{}) { - return; - } - if (!common_tickets.empty() && !personal_tickets.empty()) { return; }