c# 编写的 数据库加密,如何解密?
下面是解密方法,可能不全publicstaticstringEncrypt(stringTarget,stringKey){if(Key.Length==0){Key="...
下面是解密方法,可能不全
public static string Encrypt(string Target, string Key)
{
if (Key.Length == 0)
{
Key = "12a3b456c7d8e90f";
}
Encoding uTF = Encoding.UTF8;
byte[] inArray = xxtea.Encrypt(uTF.GetBytes(Target), uTF.GetBytes(Key));
return Convert.ToBase64String(inArray);
} 展开
public static string Encrypt(string Target, string Key)
{
if (Key.Length == 0)
{
Key = "12a3b456c7d8e90f";
}
Encoding uTF = Encoding.UTF8;
byte[] inArray = xxtea.Encrypt(uTF.GetBytes(Target), uTF.GetBytes(Key));
return Convert.ToBase64String(inArray);
} 展开
1个回答
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询
广告 您可能关注的内容 |