github.com/GeniusesGroup/libgo@v0.0.0-20220929090155-5ff932cb408e/crypto/aes-256.go (about) 1 /* For license and copyright information please see LEGAL file in repository */ 2 3 package crypto 4 5 // AESBlockSize is block size in bytes. 6 const AESBlockSize = 16 7 8 // A aes256 is an instance of AES-256 encryption using a particular key. 9 type aes256 struct { 10 enc [60]uint32 11 dec [60]uint32 12 } 13 14 // NewAES256 use to create the aes256 that implement BlockCipher128 interface! 15 func NewAES256(key [32]byte) BlockCipher128 { 16 var c = aes256{} 17 return &c 18 } 19 20 // Encrypt encrypts the buf. 21 // If original buf needed for any other proccess, must clone it before pass it!! 22 func (aes *aes256) Encrypt(block *[16]byte) {} 23 24 // Decrypt decrypts the buf. 25 // If original buf needed for any other proccess, must clone it before pass it!! 26 func (aes *aes256) Decrypt(block *[16]byte) {}