| 143 | } |
| 144 | |
| 145 | static std::string sha256_hex(std::string_view data) { |
| 146 | if (data.empty()) { |
| 147 | return {}; |
| 148 | } |
| 149 | char hash[65]; |
| 150 | return DoraXrtSha256Hex(data.data(), data.size(), hash) ? std::string(hash) : std::string{}; |
| 151 | } |
| 152 | |
| 153 | static std::string hmac_sha256_hex(std::string_view key, std::string_view data) { |
| 154 | char hash[65]; |
no test coverage detected