Com.Alipay/Core.cs
(开头部分) 2KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Configuration;
using System.Web;
using System.Xml;
using System.IO;
using System.Security;
using System.Security.Cryptography;
using System.Net;
namespace Com.Alipay
{
public class Core
{
// Methods
public Core() { }
// public static string BuildMysign(Dictionary<string, string> dicArray, string key, string sign_type, string _input_charset);
//public static string CreateLinkString(Dictionary<string, string> dicArray);
// public static Dictionary<string, string> FilterPara(SortedDictionary<string, string> dicArrayPre);
//public static void LogResult(string sWord);
//public static string Sign(string prestr, string sign_type, string _input_charset);
public static string BuildMysign(Dictionary<string, string> dicArray, string key, string sign_type, string _input_charset)
{
return Sign(CreateLinkString(dicArray) + key, sign_type, _input_charset);
}
public static string CreateLinkString(Dictionary<string, string> dicArray)
{
StringBuilder prestr = new StringBuilder();
foreach (KeyValuePair<string, string> temp in dicArray)
{
prestr.Append(temp.Key + "=" + temp.Value + "&");
}
int nLen = prestr.Length;
prestr.Remove(nLen - 1, 1);
return prestr.ToString();
}
public static Dictionary<string, string> FilterPara(SortedDictionary<string, string> dicArrayPre)
{
Dictionary<string, string> dicArray = new Dictionary<string, string>();
foreach (KeyValuePair<string, string> temp in dicArrayPre)
{
if ((((temp.Key.ToLower() != "sign") && (temp.Key.ToLower() != "sign_type")) && (temp.Value != "")) && (temp.Value != null))
{
dicArray.Add(temp.Key.ToLower(), temp.Value);
}
}
return dicArray;
}
public static void LogResult(string sWord)
{
StreamWriter fs = new StreamWriter(HttpContext.Current.Server.MapPath("log") + @"\" + DateTime.Now.ToString().Replace(":", "") + ".txt", false, Encoding.Default);
fs.Write(sWord);
fs.Close();
}
public static string Sign(string prestr, string sign_type, string _input_charset)
{
StringBuilder sb = new StringBuilder(0x20);
if (sign_type.ToUpper() == "MD5")
后面还有 11 行代码,购买后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明
AI 解读 AI
登录后可用,每次 10 算力,解读结果公开显示在下面。
还没有人解读过这个文件。