Counter Strike : Global Offensive Source Code
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

38 lines
890 B

  1. #ifndef CRYPTOPP_SEED_H
  2. #define CRYPTOPP_SEED_H
  3. /** \file
  4. */
  5. #include "seckey.h"
  6. #include "secblock.h"
  7. NAMESPACE_BEGIN(CryptoPP)
  8. //! _
  9. struct SEED_Info : public FixedBlockSize<16>, public FixedKeyLength<16>, public FixedRounds<16>
  10. {
  11. static const char *StaticAlgorithmName() {return "SEED";}
  12. };
  13. /// <a href="http://www.cryptolounge.org/wiki/SEED">SEED</a>
  14. class SEED : public SEED_Info, public BlockCipherDocumentation
  15. {
  16. class CRYPTOPP_NO_VTABLE Base : public BlockCipherImpl<SEED_Info>
  17. {
  18. public:
  19. void UncheckedSetKey(const byte *key, unsigned int length, const NameValuePairs &params);
  20. void ProcessAndXorBlock(const byte *inBlock, const byte *xorBlock, byte *outBlock) const;
  21. protected:
  22. FixedSizeSecBlock<word32, 32> m_k;
  23. };
  24. public:
  25. typedef BlockCipherFinal<ENCRYPTION, Base> Encryption;
  26. typedef BlockCipherFinal<DECRYPTION, Base> Decryption;
  27. };
  28. NAMESPACE_END
  29. #endif