mirror of
https://github.com/Vita3K/psvpfsparser.git
synced 2024-11-23 05:29:48 +00:00
b9d1a82195
Example program still needs Boost.Program_Options to be built.
26 lines
669 B
C++
26 lines
669 B
C++
#pragma once
|
|
|
|
#include "IF00DKeyEncryptor.h"
|
|
#include "ICryptoOperations.h"
|
|
|
|
#include <map>
|
|
#include <memory>
|
|
|
|
class F00DNativeKeyEncryptor : public IF00DKeyEncryptor
|
|
{
|
|
private:
|
|
std::map<std::string, std::string> m_keyCache;
|
|
|
|
std::shared_ptr<ICryptoOperations> m_cryptops;
|
|
|
|
public:
|
|
F00DNativeKeyEncryptor(std::shared_ptr<ICryptoOperations> cryptops);
|
|
|
|
private:
|
|
int kprx_auth_service_0x50001(const unsigned char* key, int key_size, unsigned char* drv_key, int key_id) const;
|
|
|
|
public:
|
|
int encrypt_key(const unsigned char* key, int key_size, unsigned char* drv_key) override;
|
|
|
|
void print_cache(std::ostream& os, std::string sep = "\t") const override;
|
|
}; |