Java Triple DES 算法填充模式
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/16416039/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Java Triple DES algorithm Padding modes
提问by Bahram
I need to know what are the padding modes applicable to Triple DES algorithm , Is AI_PKCS_PADDING a padding mode applicable to Triple DES ?
我需要知道什么是适用于三重 DES 算法的填充模式,AI_PKCS_PADDING 是适用于三重 DES 的填充模式吗?
回答by John Snow
According to Java Cipher API:
根据Java 密码 API:
Every implementation of the Java platform is required to support the following standard Cipher transformations with the keysizes in parentheses:
AES/CBC/NoPadding (128)
AES/CBC/PKCS5Padding (128)
AES/ECB/NoPadding (128)
AES/ECB/PKCS5Padding (128)
DES/CBC/NoPadding (56)
DES/CBC/PKCS5Padding (56)
DES/ECB/NoPadding (56)
DES/ECB/PKCS5Padding (56)
DESede/CBC/NoPadding (168)
DESede/CBC/PKCS5Padding (168)
DESede/ECB/NoPadding (168)
DESede/ECB/PKCS5Padding (168)
RSA/ECB/PKCS1Padding (1024, 2048)
RSA/ECB/OAEPWithSHA-1AndMGF1Padding (1024, 2048)
RSA/ECB/OAEPWithSHA-256AndMGF1Padding (1024, 2048)
Hence it should support PKCS5Padding
因此它应该支持 PKCS5Padding
回答by rebeliagamer
Triple DES algorithm Padding modes (...) I dont know which mode I should use (...)
三重 DES 算法填充模式 (...) 我不知道我应该使用哪种模式 (...)
- Padding in general: Using Padding in Encryption
- Common modes: Block cipher mode of operation
- 一般填充:在加密中使用填充
- 常用模式:分组密码操作模式
DES Modes of Operation (Triple DES is based on DES):
DES 操作模式(三重 DES 基于 DES):
- ECB
- CBC
- CFB
- OFB
- 欧洲央行
- 加拿大广播公司
- 循环流化床
- OFB
what is deference of AES and DES and DESede
什么是 AES 和 DES 以及 DESede 的尊重