Common/Com/Alipay/Notify.cs

(开头部分) 3KB

这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。

namespace Com.Alipay
{
    using System;
    using System.Collections.Generic;
    using System.IO;
    using System.Net;
    using System.Text;

    public class Notify
    {
        private string _input_charset = "";
        private string _key = "";
        private string _partner = "";
        private string _sign_type = "";
        private string Https_veryfy_url = "https://mapi.alipay.com/gateway.do?service=notify_verify&";

        public Notify()
        {
            this._partner = Config.Partner.Trim();
            this._key = Config.Key.Trim();
            this._input_charset = Config.Input_charset.Trim().ToLower();
            this._sign_type = Config.Sign_type.Trim().ToUpper();
        }

        private string Get_Http(string strUrl, int timeout)
        {
            try
            {
                HttpWebRequest request = (HttpWebRequest) WebRequest.Create(strUrl);
                request.Timeout = timeout;
                HttpWebResponse response = (HttpWebResponse) request.GetResponse();
                StreamReader reader = new StreamReader(response.GetResponseStream(), Encoding.Default);
                StringBuilder builder = new StringBuilder();
                while (-1 != reader.Peek())
                {
                    builder.Append(reader.ReadLine());
                }
                return builder.ToString();
            }
            catch (Exception exception)
            {
                return ("错误:" + exception.Message);
            }
        }

        private string GetPreSignStr(SortedDictionary<string, string> inputPara)
        {
            Dictionary<string, string> dictionary = new Dictionary<string, string>();
            return Core.CreateLinkString(Core.FilterPara(inputPara));
        }

        private string GetResponseTxt(string notify_id)
        {
            string strUrl = this.Https_veryfy_url + "partner=" + this._partner + "&notify_id=" + notify_id;
            return this.Get_Http(strUrl, 0x1d4c0);
        }

        private bool GetSignVeryfy(SortedDictionary<string, string> inputPara, string sign)
        {
            Dictionary<string, string> dictionary = new Dictionary<string, string>();
后面还有 26 行代码,购买后查看完整代码

24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明

AI 解读 AI

登录后可用,每次 10 算力,解读结果公开显示在下面。

还没有人解读过这个文件。