Documentation ¶
Index ¶
- Constants
- Variables
- func NewCipher(key []byte) (cipher.Block, error)
- func SetIV(iv []byte) error
- func Sm4CFB(key []byte, in []byte, mode bool) (out []byte, err error)
- func Sm4Cbc(key []byte, in []byte, mode bool) (out []byte, err error)
- func Sm4Ecb(key []byte, in []byte, mode bool) (out []byte, err error)
- func Sm4OFB(key []byte, in []byte, mode bool) (out []byte, err error)
- type SM4Key
- type Sm4Cipher
Constants ¶
View Source
const BlockSize = 16
Variables ¶
View Source
var IV = make([]byte, BlockSize)
Functions ¶
func Sm4CFB ¶
密码反馈模式(Cipher FeedBack (CFB)) https://blog.csdn.net/zy_strive_2012/article/details/102520356 https://blog.csdn.net/sinat_23338865/article/details/72869841
func Sm4OFB ¶
输出反馈模式(Output feedback, OFB) https://blog.csdn.net/chengqiuming/article/details/82390910 https://blog.csdn.net/sinat_23338865/article/details/72869841
Types ¶
Click to show internal directories.
Click to hide internal directories.