Encryption 使用as3Crypto进行无符号加密/解密
我使用的是as3Crypto,没有问题 但后来我看到了一些特殊的角色,我意识到我可以遇到安培生。 这很痛苦,因为它们将被插入到查询字符串中。 有没有办法确保as3Crypto加密不会产生符号和Encryption 使用as3Crypto进行无符号加密/解密,encryption,as3crypto,Encryption,As3crypto,我使用的是as3Crypto,没有问题 但后来我看到了一些特殊的角色,我意识到我可以遇到安培生。 这很痛苦,因为它们将被插入到查询字符串中。 有没有办法确保as3Crypto加密不会产生符号和 public function encrypt(txt:String = ''):String { var data:ByteArray = Hex.toArray(Hex.fromString(txt)); var pad:IPad = new PKCS5; var
public function encrypt(txt:String = ''):String
{
var data:ByteArray = Hex.toArray(Hex.fromString(txt));
var pad:IPad = new PKCS5;
var mode:ICipher = Crypto.getCipher(type, key, pad);
pad.setBlockSize(mode.getBlockSize());
mode.encrypt(data);
return ''+Base64.encodeByteArray(data);
}
假设采用标准实现,Base64.encodeByteArray(数据)代码>不会产生符号。啊,我明白了。谷歌搜索哪个摇摆。谢谢