Package icu.easyj.web.param.crypto.impls
Class DefaultParamCryptoHandlerImpl
java.lang.Object
icu.easyj.web.param.crypto.impls.DefaultParamCryptoHandlerImpl
- All Implemented Interfaces:
IParamCryptoHandler
默认的参数加密解密处理器实现类
- Author:
- wangliang181230
-
Constructor Summary
ConstructorsConstructorDescription构造函数 -
Method Summary
-
Constructor Details
-
DefaultParamCryptoHandlerImpl
构造函数- Parameters:
properties- 处理器配置
-
-
Method Details
-
isEncryptedQueryString
Description copied from interface:IParamCryptoHandler校验加密串的格式,是否为当前加密算法加密后的字符串格式。举例说明:默认实现类中,加密后为base64串,则校验一下base64格式。
- Specified by:
isEncryptedQueryStringin interfaceIParamCryptoHandler- Parameters:
encryptedParam- 待解密参数- Returns:
- 是否需要解密
-
encrypt
Description copied from interface:IParamCryptoHandler加密- Specified by:
encryptin interfaceIParamCryptoHandler- Parameters:
param- 待加密的参数- Returns:
- 加密后的参数
- Throws:
ParamEncryptException- 加密异常
-
decrypt
Description copied from interface:IParamCryptoHandler解密- Specified by:
decryptin interfaceIParamCryptoHandler- Parameters:
encryptedParam- 已加密的内容- Returns:
- content 未加密的内容
- Throws:
ParamDecryptException- 解密异常
-