File cipher_rc4.h
File List > crypto > cipher_rc4.h
Go to the documentation of this file
#ifndef QQMUSIC_CRYPTO_CIPHER_RC4_H
#define QQMUSIC_CRYPTO_CIPHER_RC4_H
#include <cstdint>
#include <qqmusic/crypto/cipher.h>
#include <qqmusic/result.h>
#include <qqmusic/utils/buffer.h>
#include <vector>
namespace qqmusic::crypto {
class RC4Cipher : public Cipher {
public:
explicit RC4Cipher(const std::vector<uint8_t>& key);
void decrypt(qqmusic::utils::buffer& buf, size_t offset) override;
private:
std::vector<uint8_t> key;
};
} // namespace qqmusic::crypto
#endif // !QQMUSIC_CRYPTO_CIPHER_RC4_H