Skip to content

Commit

Permalink
Fixed: AES/ECB/PCKS5padding panic #19
Browse files Browse the repository at this point in the history
Fixed: AES/ECB/PCKS5padding panic #19
  • Loading branch information
gouguoyin authored Jan 30, 2024
2 parents de0364a + 5497c86 commit fce46a2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion cipher.go
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ func (c *Cipher) AnsiX923UnPadding(src []byte) []byte {
// PKCS5Padding padding with PKCS5 mode.
// 进行 PKCS5 填充
func (c *Cipher) PKCS5Padding(src []byte) []byte {
return c.PKCS7Padding(src, 8)
return c.PKCS7Padding(src, 16)
}

// PKCS5UnPadding removes padding with PKCS5 mode.
Expand Down

0 comments on commit fce46a2

Please sign in to comment.