我将如何在 golang 中使用来自 java 的 AES/CCM/NoPadding 密码?
How would I use the AES/CCM/NoPadding cipher from java in golang?
我需要在 golang 中使用 AES/CCM/NoPadding 密码(来自 java),但我在标准库中找不到任何关于 aes-ccm 的信息。
这与SSL/TLS中的用法有关吗?似乎有些 golang 人不想支持 TLS:https://github.com/golang/go/issues/27484 但大多数 TLS 实现主要提供其他密码套件。
但是,如果它与 TLS 无关,您可能想看看其他人为实现它所做的努力,例如:
- https://pkg.go.dev/github.com/pschlump/AesCCM
- https://gist.github.com/hirochachacha/abb76ff71573dea2ef42
有关实现此功能的一些文档,请参阅:
- https://en.wikipedia.org/wiki/CCM_mode
- https://www.rfc-editor.org/rfc/rfc3610 关于 AES CCM
- https://www.rfc-editor.org/rfc/rfc4309(用于 IPsec 封装安全负载中的 CCM)
- https://www.rfc-editor.org/rfc/rfc6655(用于 TLS 中的 CCM)
您通常还会在 crypto.stackexchange.com 上找到有关加密的更深入的专业知识,例如:
我需要在 golang 中使用 AES/CCM/NoPadding 密码(来自 java),但我在标准库中找不到任何关于 aes-ccm 的信息。
这与SSL/TLS中的用法有关吗?似乎有些 golang 人不想支持 TLS:https://github.com/golang/go/issues/27484 但大多数 TLS 实现主要提供其他密码套件。
但是,如果它与 TLS 无关,您可能想看看其他人为实现它所做的努力,例如:
- https://pkg.go.dev/github.com/pschlump/AesCCM
- https://gist.github.com/hirochachacha/abb76ff71573dea2ef42
有关实现此功能的一些文档,请参阅:
- https://en.wikipedia.org/wiki/CCM_mode
- https://www.rfc-editor.org/rfc/rfc3610 关于 AES CCM
- https://www.rfc-editor.org/rfc/rfc4309(用于 IPsec 封装安全负载中的 CCM)
- https://www.rfc-editor.org/rfc/rfc6655(用于 TLS 中的 CCM)
您通常还会在 crypto.stackexchange.com 上找到有关加密的更深入的专业知识,例如: