我想将一个字符串(用户密码)加密,有没有好的算法,请大家指教

解决方案 »

  1.   

    帮你UP。知道有个DES,不过不知道如何实现
      

  2.   

    DES或者RSA
    要是想简单点,就自己取反,移位什么的搞搞
      

  3.   

    You should NEVER keep the user password in any format, encrypted or not. Instead, you should only keep a hash value of the password through a one-way hashing algorithm (MD5, SHA-1, etc).
     To gain even higher security level, you may also consider adding some "salt" into the hashing process, meaning that append a random string/timestamp after the password before it goes into the hashing algorithm. For more detail, read:
     http://msdn.microsoft.com/msdnmag/issues/03/08/SecurityBriefs/default.aspx
      

  4.   

    MD5
    或者你可以使用IE自带的加密算法crypt 你可以在MSDN中查找crypt 有例子