1 Star 0 Fork 10

SyncGithub/OAuthApp

forked from uncle wang/OAuthApp 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
ApiModels
Apis
Controllers
Data
Filters
Models
Services
Tenant
Views
jietu
wwwroot
.gitignore
AppConst.cs
AppFunctions.cs
LICENSE
OAuthApp.csproj
OAuthApp.sln
Program.cs
README.en.md
README.md
Startup.cs
appsettings.Development.json
appsettings.json
bundleconfig.json
gulpfile.js
nlog.config
package.json
克隆/下载
AppFunctions.cs 848 Bytes
一键复制 编辑 原始数据 按行查看 历史
using System;
using System.Collections.Generic;
using System.Linq;
using System.Security.Cryptography;
using System.Text;
using System.Threading.Tasks;
namespace OAuthApp
{
public static class AppFunctions
{
public static string md5(string str)
{
var bt = Encoding.UTF8.GetBytes(str);
var md5 = MD5.Create();
var md5bt = md5.ComputeHash(bt);
StringBuilder builder = new StringBuilder();
foreach (var item in md5bt)
{
builder.Append(item.ToString("x2"));
}
var md5Str = builder.ToString();
return builder.ToString();
}
public static bool md5Compare(string pwd,string pwd2)
{
var pwd_md5 = md5(pwd);
return pwd_md5 == pwd2;
}
}
}
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
C#
1
https://gitee.com/sync-github/OAuthApp.git
git@gitee.com:sync-github/OAuthApp.git
sync-github
OAuthApp
OAuthApp
master

搜索帮助