-
-
Notifications
You must be signed in to change notification settings - Fork 305
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Showing
2 changed files
with
17 additions
and
27 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
using System; | ||
using System.Security.Cryptography; | ||
using System.Text; | ||
|
||
namespace AgileConfig.Server.Common | ||
{ | ||
public static class Encrypt | ||
{ | ||
private static readonly MD5 Md5Instance = MD5.Create(); | ||
public static string Md5(string txt) | ||
{ | ||
var inputBytes = Encoding.ASCII.GetBytes(txt); | ||
var hashBytes = Md5Instance.ComputeHash(inputBytes); | ||
return Convert.ToHexString(hashBytes); | ||
} | ||
} | ||
} |
This file was deleted.
Oops, something went wrong.