Example #1
0
 public HashEncrypt(HashEncryptType hashType, string originalString, bool useSalt, string saltValue)
 {
     this._mbytHashType       = hashType;
     this._mstrOriginalString = originalString;
     this.mboolUseSalt        = useSalt;
     this.mstrSaltValue       = saltValue;
 }
Example #2
0
 public string Encrypt(string originalString, HashEncryptType hashType, string saltValue)
 {
     this._mstrOriginalString = originalString;
     this._mbytHashType       = hashType;
     this.mstrSaltValue       = saltValue;
     return(this.Encrypt());
 }
Example #3
0
        /// <summary>
        /// 进行非对称加密
        /// </summary>
        /// <param name="originalString">原始字符串</param>
        /// <param name="hashType">加密类型</param>
        public string Encrypt(string originalString, HashEncryptType hashType)
        {
            _mstrOriginalString = originalString;
            _mbytHashType       = hashType;

            return(this.Encrypt());
        }
Example #4
0
 public HashEncrypt(HashEncryptType hashType, string originalString, bool useSalt, string saltValue)
 {
     this._mbytHashType = hashType;
     this._mstrOriginalString = originalString;
     this.mboolUseSalt = useSalt;
     this.mstrSaltValue = saltValue;
 }
Example #5
0
 public HashEncrypt(HashEncryptType HashType, string OriginalString)
 {
     this.mstrSaltValue = string.Empty;
     this.msrtSaltLength = 8;
     this.mbytHashType = HashType;
     this.mstrOriginalString = OriginalString;
 }
Example #6
0
 public HashEncrypt(HashEncryptType HashType, string OriginalString, bool UseSalt, string SaltValue)
 {
     this.mstrSaltValue = string.Empty;
     this.msrtSaltLength = 8;
     this.mbytHashType = HashType;
     this.mstrOriginalString = OriginalString;
     this.mboolUseSalt = UseSalt;
     this.mstrSaltValue = SaltValue;
 }
Example #7
0
 public void Reset()
 {
     this.mstrSaltValue       = string.Empty;
     this._mstrOriginalString = string.Empty;
     this._mstrHashString     = string.Empty;
     this.mboolUseSalt        = false;
     this._mbytHashType       = HashEncryptType.MD5;
     this._mhash = null;
 }
Example #8
0
        /// <summary>
        /// 重置加密设置
        /// </summary>
        public void Reset()
        {
            mstrSaltValue       = String.Empty;
            _mstrOriginalString = String.Empty;
            _mstrHashString     = String.Empty;
            mboolUseSalt        = false;
            _mbytHashType       = HashEncryptType.MD5;

            _mhash = null;
        }
Example #9
0
 public HashEncrypt(HashEncryptType hashType, string originalString)
 {
     this._mbytHashType = hashType;
     this._mstrOriginalString = originalString;
 }
Example #10
0
 public HashEncrypt(HashEncryptType hashType)
 {
     this._mbytHashType = hashType;
 }
Example #11
0
 public HashEncrypt(HashEncryptType HashType)
 {
     this.mstrSaltValue = string.Empty;
     this.msrtSaltLength = 8;
     this.mbytHashType = HashType;
 }
Example #12
0
 public HashEncrypt(HashEncryptType hashType)
 {
     this._mbytHashType = hashType;
 }
Example #13
0
 public string Encrypt(string originalString, HashEncryptType hashType, string saltValue)
 {
     this._mstrOriginalString = originalString;
     this._mbytHashType = hashType;
     this.mstrSaltValue = saltValue;
     return this.Encrypt();
 }
Example #14
0
 public string Encrypt(string originalString, HashEncryptType hashType)
 {
     this._mstrOriginalString = originalString;
     this._mbytHashType = hashType;
     return this.Encrypt();
 }
Example #15
0
 public void Reset()
 {
     this.mstrSaltValue = string.Empty;
     this._mstrOriginalString = string.Empty;
     this._mstrHashString = string.Empty;
     this.mboolUseSalt = false;
     this._mbytHashType = HashEncryptType.MD5;
     this._mhash = null;
 }
Example #16
0
 public HashEncrypt()
 {
     this._mbytHashType = HashEncryptType.MD5;
 }
Example #17
0
 public HashEncrypt()
 {
     this._mbytHashType = HashEncryptType.MD5;
 }
Example #18
0
 public HashEncrypt(HashEncryptType hashType, string originalString)
 {
     this._mbytHashType       = hashType;
     this._mstrOriginalString = originalString;
 }
Example #19
0
 public string CreateHash(string OriginalString, HashEncryptType HashType, string SaltValue)
 {
     this.mstrOriginalString = OriginalString;
     this.mbytHashType = HashType;
     this.mstrSaltValue = SaltValue;
     return this.CreateHash();
 }