code: public static boolean checkSign(PurchaseInfoResult result, String pubKey) {
  
          if (result == null || pubKey == null) {
              return false;
          }
  
          StringBuilder sb = new StringBuilder();
  
          Map<String, Object> paramsa = new HashMap<String, Object>();
          paramsa.put("pageCount", result.getPageCount());
          paramsa.put("rtnCode", result.getRtnCode());
          sb.append(getNoSign(paramsa, false)).append('&');
  
          List<PurchaseInfo> purchaseInfos = result.getPurchaseInfoList();
          if (purchaseInfos != null) {
              for (PurchaseInfo info : purchaseInfos) {
                  if (info != null) {
                      Map<String, Object> paramsaSub = new HashMap<String, Object>();
                      //必选参数
                      paramsaSub.put("requestId", info.getRequestId());
                      paramsaSub.put("merchantId", info.getMerchantId());
                      paramsaSub.put("appId", info.getAppId());
                      paramsaSub.put("productId", info.getProductId());
                      paramsaSub.put("tradeTime", info.getTradeTime());
  
                      sb.append(getNoSign(paramsaSub, false)).append('&');
                  }
              }
          }
  
          if (sb.charAt(sb.length()-1) == '&') {
              sb.deleteCharAt(sb.length()-1);
          }
  
          return doCheck(sb.toString(), result.getSign(), pubKey);
      }
docs: 对查询非消耗商品结果的每一个订单签名进行校验
  @param result 查询订单结果
  @param pubKey 公钥
  @return 是否校验通过