diff options
author | Jay Freeman (saurik) <saurik@saurik.com> | 2017-12-11 00:25:25 -0800 |
---|---|---|
committer | Jay Freeman (saurik) <saurik@saurik.com> | 2017-12-11 00:25:25 -0800 |
commit | f74652ab3bfc5026ef954a35aeb137a18f55bf67 (patch) | |
tree | cd532effc6ad9b57c130803c1649fe3fdde590bc /ldid.hpp | |
parent | 168c37736ac977ee5d751c36bb46d3255dc07ad2 (diff) | |
download | ldid-f74652ab3bfc5026ef954a35aeb137a18f55bf67.tar.gz ldid-f74652ab3bfc5026ef954a35aeb137a18f55bf67.tar.zst ldid-f74652ab3bfc5026ef954a35aeb137a18f55bf67.zip |
Add support for alternate SHA256 code directories.
Diffstat (limited to 'ldid.hpp')
-rw-r--r-- | ldid.hpp | 11 |
1 files changed, 8 insertions, 3 deletions
@@ -146,16 +146,21 @@ class UnionFolder : } }; +struct Hash { + uint8_t sha1_[0x14]; + uint8_t sha256_[0x20]; +}; + struct Bundle { std::string path; - std::vector<char> hash; + Hash hash; }; Bundle Sign(const std::string &root, Folder &folder, const std::string &key, const std::string &requirement, const Functor<std::string (const std::string &, const std::string &)> &alter, const Functor<void (const std::string &)> &progress, const Functor<void (double)> &percent); -typedef std::map<uint32_t, std::vector<char>> Slots; +typedef std::map<uint32_t, Hash> Slots; -std::vector<char> Sign(const void *idata, size_t isize, std::streambuf &output, const std::string &identifier, const std::string &entitlements, const std::string &requirement, const std::string &key, const Slots &slots, const Functor<void (double)> &percent); +Hash Sign(const void *idata, size_t isize, std::streambuf &output, const std::string &identifier, const std::string &entitlements, const std::string &requirement, const std::string &key, const Slots &slots, const Functor<void (double)> &percent); } |