mirror of
https://github.com/Kelsidavis/WoWee.git
synced 2026-04-25 21:03:51 +00:00
Initial commit: wowee native WoW 3.3.5a client
This commit is contained in:
commit
ce6cb8f38e
147 changed files with 32347 additions and 0 deletions
27
include/auth/crypto.hpp
Normal file
27
include/auth/crypto.hpp
Normal file
|
|
@ -0,0 +1,27 @@
|
|||
#pragma once
|
||||
|
||||
#include <vector>
|
||||
#include <cstdint>
|
||||
#include <string>
|
||||
|
||||
namespace wowee {
|
||||
namespace auth {
|
||||
|
||||
class Crypto {
|
||||
public:
|
||||
static std::vector<uint8_t> sha1(const std::vector<uint8_t>& data);
|
||||
static std::vector<uint8_t> sha1(const std::string& data);
|
||||
|
||||
/**
|
||||
* HMAC-SHA1 message authentication code
|
||||
*
|
||||
* @param key Secret key
|
||||
* @param data Data to authenticate
|
||||
* @return 20-byte HMAC-SHA1 hash
|
||||
*/
|
||||
static std::vector<uint8_t> hmacSHA1(const std::vector<uint8_t>& key,
|
||||
const std::vector<uint8_t>& data);
|
||||
};
|
||||
|
||||
} // namespace auth
|
||||
} // namespace wowee
|
||||
Loading…
Add table
Add a link
Reference in a new issue