Documentation ¶
Index ¶
- Constants
- Variables
- func AesDecrypt(key, iv []byte, encrData []byte) []byte
- func AesEncrypt(key, iv []byte, origData []byte) []byte
- func ROTL(x byte) byte
- func ROTL16(x uint32) uint32
- func ROTL24(x uint32) uint32
- func ROTL8(x uint32) uint32
- type AesCipher128
- type AesCipher256
- type IAesCipher
- type RI
Constants ¶
View Source
const (
BLOCK_SIZE_16 = 16
)
View Source
const (
BLOCK_SIZE_32 = 32
)
Variables ¶
View Source
var (
InCo = []byte{0xB, 0xD, 0x9, 0xE} /* Inverse Coefficients */
)
Fixed Data
Functions ¶
Types ¶
type AesCipher128 ¶
type AesCipher128 struct {
// contains filtered or unexported fields
}
func NewAesCipher128 ¶
func NewAesCipher128(key, iv []byte) *AesCipher128
func (*AesCipher128) BlockSize ¶
func (aesCipher *AesCipher128) BlockSize() int
func (*AesCipher128) Decrypt ¶
func (aesCipher *AesCipher128) Decrypt(encrData []byte) []byte
func (*AesCipher128) Encrypt ¶
func (aesCipher *AesCipher128) Encrypt(origData []byte) []byte
type AesCipher256 ¶
type AesCipher256 struct { BufferPool *pkg.LimitedPool // contains filtered or unexported fields }
func NewAesCipher256 ¶
func NewAesCipher256(key, iv []byte) *AesCipher256
func (*AesCipher256) BlockSize ¶
func (aesCipher *AesCipher256) BlockSize() int
func (*AesCipher256) Decrypt ¶
func (aesCipher *AesCipher256) Decrypt(origData []byte) []byte
func (*AesCipher256) Encrypt ¶
func (aesCipher *AesCipher256) Encrypt(origData []byte) []byte
type IAesCipher ¶
func NewAesCipher ¶
func NewAesCipher(key, iv []byte) IAesCipher
Click to show internal directories.
Click to hide internal directories.