Authored by fangyeqing

fix md5 bug

... ... @@ -84,9 +84,7 @@ public class SecurityTool {
return buf.toString();
}
public static String getPassword(String account, String origalPassword, String salt) {
// 将原始密码加密成md5
String md5pass = encode("MD5",origalPassword);
public static String getPassword(String account, String md5pass, String salt) {
//用户在数据库中存储的数据为:md5(sha1(account + salt) + md5pass)
String encodePass = encode("MD5", encode("SHA1",account + salt) + md5pass);
return encodePass;
... ...