Beispiel #1
0
 /// <summary>
 /// 签名验证
 /// </summary>
 /// <param name="config"></param>
 /// <returns></returns>
 internal bool Verify(Config config)
 {
     if (IsReturn)
     {
         if (appid == config.appid && mch_id == config.mch_id && Sign <AppPrePayId> .Check(this, config.key, sign))
         {
             return(true);
         }
         config.PayLog.add(Log.LogType.Debug | Log.LogType.Info, "签名验证错误 " + AutoCSer.Json.Serializer.Serialize(this));
     }
     return(false);
 }
Beispiel #2
0
 /// <summary>
 /// 签名验证
 /// </summary>
 /// <param name="config"></param>
 /// <returns></returns>
 internal bool Verify(Config config)
 {
     if (IsReturn)
     {
         if (appid == config.appid && mch_id == config.mch_id && Sign <RefundResult> .Check(this, config.key, sign))
         {
             return(true);
         }
         AutoCSer.Log.Pub.Log.Add(Log.LogType.Debug | Log.LogType.Info, "签名验证错误 " + AutoCSer.Json.Serializer.Serialize(this));
     }
     return(false);
 }
Beispiel #3
0
 /// <summary>
 /// 签名验证
 /// </summary>
 /// <param name="config"></param>
 /// <returns></returns>
 internal bool Verify(Config config)
 {
     if (IsReturn)
     {
         if (appid == config.appid && mch_id == config.mch_id && Sign <RefundResult> .Check(this, config.key, sign))
         {
             return(true);
         }
         AutoCSer.LogHelper.Debug("签名验证错误 " + AutoCSer.JsonSerializer.Serialize(this), LogLevel.Debug | LogLevel.Info | LogLevel.AutoCSer);
     }
     return(false);
 }
Beispiel #4
0
 /// <summary>
 /// 签名验证
 /// </summary>
 /// <param name="config"></param>
 /// <returns></returns>
 internal bool Verify(Config config)
 {
     if (IsReturn)
     {
         if (appid == config.appid && mch_id == config.mch_id && Sign <AppPrePayId> .Check(this, config.key, sign))
         {
             return(true);
         }
         config.PayLog.Debug("签名验证错误 " + AutoCSer.JsonSerializer.Serialize(this), LogLevel.Debug | LogLevel.Info | LogLevel.AutoCSer);
     }
     return(false);
 }
Beispiel #5
0
 /// <summary>
 /// 签名验证
 /// </summary>
 /// <param name="config"></param>
 /// <returns></returns>
 internal bool Verify(Config config)
 {
     if (IsReturn)
     {
         if (appid == config.appid && mch_id == config.mch_id && Sign <CloseOrderResult> .Check(this, config.key, sign))
         {
             return(true);
         }
         AutoCSer.Log.Pub.Log.add(Log.LogType.Debug | Log.LogType.Info, "签名验证错误 " + AutoCSer.Json.Serializer.Serialize(this), new System.Diagnostics.StackFrame(), false);
     }
     return(false);
 }
Beispiel #6
0
 /// <summary>
 /// 签名验证
 /// </summary>
 /// <param name="config"></param>
 /// <returns></returns>
 public new bool Verify(Config config = null)
 {
     if (config == null)
     {
         config = Config.Default;
     }
     if (appid == config.appid && mch_id == config.mch_id && Sign <PayNotify> .Check(this, config.key, sign))
     {
         return(true);
     }
     config.PayLog.Add(Log.LogType.Debug | Log.LogType.Info, "签名验证错误 " + AutoCSer.Json.Serializer.Serialize(this));
     return(false);
 }
Beispiel #7
0
 /// <summary>
 /// 微信支付完成回调验证
 /// </summary>
 /// <param name="config"></param>
 /// <returns></returns>
 public bool Verify(Config config = null)
 {
     if (IsReturn)
     {
         if (config == null)
         {
             config = Config.Default;
         }
         if (appid == config.appid && mch_id == config.mch_id && Sign <PayNotify> .Check(this, config.key, sign))
         {
             return(true);
         }
         config.PayLog.Debug("微信支付回调验证错误 " + AutoCSer.JsonSerializer.Serialize(this), LogLevel.Debug | LogLevel.Info | LogLevel.AutoCSer);
     }
     return(false);
 }