Releases: dromara/dongle
Releases · dromara/dongle
v1.2.3
English
- Remove
LoadPublicKeyandLoadPrivateKeymethods fromSm2KeyPairstruct - Add
SetModemethod toSm2to replaceSetOrder;SetOrderwill be removed in a future version - Add support for
RSAprivate-key encryption/public-key decryption and public-key signing/private-key verification (non-standard operations) - Add
SetTypemethod toRSAto specify key type
中文
Sm2KeyPair结构体移除LoadPublicKey和LoadPrivateKey方法Sm2新增SetMode方法用于替换SetOrder,SetOrder方法将会在未来版本中移除RSA增加私钥加密/公钥解密 和 公钥签名/私有验证的支持(非标准操作)RSA新增SetType方法来指定密钥类型
Full Changelog: v1.2.2...v1.2.3
v1.2.2
English
- Move
mockandutilspackages tointernalpackage - Optimize
Rsaasymmetric encryption algorithm, addSetPaddingmethod to set padding mode, decoupling key format and padding mode
中文
- Add
Sm2asymmetric elliptic curve signature/verification support - 将
mock和utils包移动到internal包中 - 优化
Rsa非对称椭圆曲线加密算法, 新增SetPadding方法用于设置填充模式, 使密钥格式和填充模式解耦 - 增加
Sm2非对称椭圆曲线签名/验证支持
Full Changelog: v1.2.1...v1.2.2
v1.2.1
English
- Fix bug where
wNAFalgorithm error inSm2asymmetric elliptic curve encryption algorithm causes decryption failure in some cases - Optimize curve field element operation implementation in
Sm2asymmetric elliptic curve encryption algorithm - Add direct parsing support for
BIT_STRINGformat keys inSm2asymmetric elliptic curve encryption algorithm - Simplify test loop syntax, change from
forloop torangeloop
中文
- 修复
Sm2非对称椭圆曲线加密算法中wNAF算法错误造成某些情况下解密失败的bug - 优化
Sm2非对称椭圆曲线加密算法中曲线域元素运算实现 - 增加
Sm2非对称椭圆曲线加密算法对BIT_STRING格式密钥直接解析支持 - 简化测试循环语法,从
for循环改为range循环
Full Changelog: v1.2.0...v1.2.1
v1.2.0
English
- Remove
LoadPublicKeyandLoadPrivateKeymethods fromRSAKeyPairstruct - Remove
LoadPublicKeyandLoadPrivateKeymethods fromEd25519KeyPairstruct - Optimize encoder and decoder performance, reuse read buffer, reduce memory allocation and copying
RSAKeyPairstruct'sGenKeyPair,SetPublicKey,SetPrivateKeymethods changed from no return value to returningerrorEd25519KeyPairstruct'sGenKeyPair,SetPublicKey,SetPrivateKeymethods changed from no return value to returningerrorRSAKeyPairstruct addsFormatPublicKeyandFormatPrivateKeymethods to formatbase64encodedderformatRSApublic and private keys intopemformatEd25519KeyPairstruct addsFormatPublicKeyandFormatPrivateKeymethods to formatbase64encodedderformatEd25519public and private keys intopemformatRSAKeyPairstruct addsCompressPublicKeyandCompressPrivateKeymethods to compresspemformatRSApublic and private keys intobase64encodedderformatEd25519KeyPairstruct addsCompressPublicKeyandCompressPrivateKeymethods to compresspemformatEd25519public and private keys intobase64encodedderformat- Add
Sm2asymmetric elliptic curve encryption algorithm support, including standard processing and streaming processing
中文
- 移除
RSAKeyPair结构体的LoadPublicKey和LoadPrivateKey方法 - 移除
Ed25519KeyPair结构体的LoadPublicKey和LoadPrivateKey方法 - 优化编码器和解码器性能,重用读缓冲区,减少内存分配和复制
RSAKeyPair结构体的GenKeyPair,SetPublicKey,SetPrivateKey方法从无返回值改为返回errorEd25519KeyPair结构体的GenKeyPair,SetPublicKey,SetPrivateKey方法从无返回值改为返回errorRSAKeyPair结构体增加FormatPublicKey和FormatPrivateKey方法,用于将base64编码的der格式的RSA公钥和私钥格式化成pem格式Ed25519KeyPair结构体增加FormatPublicKey和FormatPrivateKey方法,用于将base64编码的der格式的Ed25519公钥和私钥格式化成pem格式RSAKeyPair结构体增加CompressPublicKey和CompressPrivateKey方法,用于将pem格式的RSA公钥和私钥压缩成经过base64编码的der格式Ed25519KeyPair结构体增加CompressPublicKey和CompressPrivateKey方法,用于将pem格式的Ed25519公钥和私钥压缩成经过base64编码的der格式- 增加
Sm2非对称椭圆曲线加密算法支持,包括标准处理和流式处理
Full Changelog: v1.1.8...v1.2.0
v1.1.8
English
- Fix bug where
*RsaKeyPair.formatPublicKeyand*RsaKeyPair.formatPrivateKeyfail to format keys - Fix bug where
*Ed25519KeyPair.formatPublicKeyand*Ed25519KeyPair.formatPrivateKeyfail to format keys - Fix bug where decoding encrypted ciphertext fails during decryption and the error cannot be retrieved
- Change default padding mode from
PKCS7toNoin symmetric block encryption algorithms - Add
Unicodeencoding/decoding support, including standard processing and streaming processing - Add
TBCpadding mode support for symmetric block encryption algorithms
中文
- 修复
*RsaKeyPair.formatPublicKey和*RsaKeyPair.formatPrivateKey格式化密钥失败的 bug - 修复
*Ed25519KeyPair.formatPublicKey和*Ed25519KeyPair.formatPrivateKey格式化密钥失败的 bug - 修复解密时对编码过的密文解码失败后无法获取错误的 bug
- 对称分组加密算法中默认填充模式从
PKCS7改为No - 增加
Unicode编码解码支持,包括标准处理和流式处理 - 对称分组加密算法增加
TBC填充模式支持
Full Changelog: v1.1.7...v1.1.8
v1.1.7
English
- Fix bug in asymmetric digital signature algorithm verification #30
- Optimize streaming processing logic, add support for
readerposition reset to ensure reading from the beginning of the data source, avoiding position offset issues caused by previous read operations, ensuring completeness and correctness of streaming operations - Change private methods
newXXXEncrypterandnewXXXDecrypterseries incrypto/cipher/block.goto public methodsNewXXXEncrypterandNewXXXDecrypter - Change private methods
newXXXPaddingandnewXXXUnPaddingseries incrypto/cipher/padding.goto public methodsNewXXXPaddingandNewXXXUnPadding - Add
sm4chinese national standard block encryption algorithm support, including standard processing and streaming processing, supporting different block modes and padding modes
中文
- 修复非对称数字签名算法中验签错误的 bug #30
- 优化流式处理逻辑,添加对
reader位置重置的支持,确保从数据源的开头开始读取,避免因之前读取操作导致的位置偏移问题,保证流式操作的完整性和正确性 crypto/cipher/block.go中newXXXEncrypter和newXXXDecrypter系列私有方法更改成公开方法NewXXXEncrypter和NewXXXDecryptercrypto/cipher/padding.go中newXXXPadding和newXXXUnPadding系列私有方法更改成公开方法NewXXXPadding和NewXXXUnPadding- 增加
sm4中国国家标准分组加密算法支持,包括标准处理和流式处理,支持不同分块模式和填充模式
Full Changelog: v1.1.6...v1.1.7
v1.1.6
English
- Use
io.CopyBufferto simplify streaming processing logic - Optimize
teaencryption algorithm to support different block modes and padding modes - Add
xteaencryption algorithm support, including standard processing and streaming processing
中文
- 使用
io.CopyBuffer简化流式处理逻辑 - 优化
tea加密算法,支持不同分块模式和填充模式 - 增加
xtea加密算法支持,包括标准处理和流式处理
Full Changelog: v1.1.5...v1.1.6
v1.1.5
English
- Fix bug where symmetric encryption algorithms incorrectly perform padding on block modes that don't require padding (such as CFB/OFB/CTR/GCM, etc.), causing encryption/decryption errors #29
中文
- 修复对称加密算法中对不需要填充的分组模式(如 CFB/OFB/CTR/GCM 等)进行填充时加解密错误的bug
Full Changelog: v1.1.4...v1.1.5
v1.1.4
English
- [chore] Change method receivers from pointer to value to prevent property pollution when using global default instances, with no impact on caller
API - [feat] Add
twofishencryption algorithm support, including standard processing and streaming processing
中文
- [chore] 将方法接受者从指针改成值,防止出现使用全局默认实例时属性污染现象,调用方
API没有任何影响 - [feat] 增加
twofish加密算法支持,包括标准处理和流式处理
Full Changelog: v1.1.3...v1.1.4
v1.1.3
English
- [chore] Optimize
3DESsymmetric encryption algorithm compatibility with16-byte keys - [chore] Optimize
DESsymmetric encryption algorithm validation for unsupportedGCMmode - [chore] Optimize
3DESsymmetric encryption algorithm validation for unsupportedGCMmode - [chore] Optimize
Blowfishsymmetric encryption algorithm validation for unsupportedGCMmode - [chore] Update
testifydependency tov1.11.1 - [feat] Add
Salsa20encryption algorithm support, including standard processing and streaming processing
中文
- [chore] 优化
3DES对称加密算法对16字节密钥的兼容 - [chore] 优化
DES对称加密算法对不支持的GCM模式的校验 - [chore] 优化
3DES对称加密算法对不支持的GCM模式的校验 - [chore] 优化
Blowfish对称加密算法对不支持的GCM模式的校验 - [chore] 更新
testify依赖至v1.11.1 - [feat] 增加
Salsa20加密算法支持,包括标准处理和流式处理
Full Changelog: v1.1.2...v1.1.3