安全规范

数字签名

为保证数据传输过程中的数据真实性,完整性和不可抵赖,我们需要对数据进行数字签名,在接收签名数据之后迚行签名校验。签名算法分为MD5

签名机制如下:

  1. 签名字段不参与组成签名原文串
  2. 只有约束为“1”且非循环节点参与签名

  3. 待签名原文是请求参数按参数名小写字母进行升序排列,参数值做拼接组成的字符串

  4. 如果提交的参数为{apam:value1, Cpam:value2, bpam:Value3},密钥key值为AFDFAASDASDAS,则待签名原文为:value1value3value2AFDFAASDASDAS,MD5后的signValue为:2145eb33684c7e4bcfe04307c435c3b9

  5. 新增版本号,默认值为V1.0.0为修改前的接口,V1.0.1,为现在接口

请求范例

请求数据:

{
    "stl_oac": "6228480402564890018",
    "crp_exp_dt_tmp": "2020-11-12",
    "bus_lic_no": "00000000000",
    "fee_rat1_scan": "0.58",
    "trm_rec": "1",
    "mercAdds": "上海浦东鲁能国际中心营业执照地址",
    "crp_id_no": "310115199601012538",
    "alipay_flg": "Y",
    "fee_rat1": "0.6",
    "orgNo": "518",
    "suptDbfreeFlg": "1",
    "stoe_area_cod": "460108",
    "scan_stoe_cnm": "上海鲁能国际中心",
    "icrp_id_no": "310115199601012538",
    "tranTyps": "C1,C2,C3,C4,C5,C6,C7",
    "serviceId": "6060601",
    "wc_lbnk_no": "318100000019",
    "max_fee_amt": "20",
    "bse_lice_nm": "上海浦东鲁能国际中心",
    "bnk_acnm": "小胖",
    "stoe_cnt_tel": "17621250727",
    "cardTyp": "01",
    "stoe_adds": "上海浦东鲁能国际中心门店地址",
    "stl_sign": "1",
    "crp_exp_dt": "2020-11-12",
    "version": "V1.0.1",
    "stoe_nm": "上海浦东鲁能国际中心门店名",
    "fee_rat2_scan": "0.6",
    "mcc_cd": "7011",
    "mailbox": "12321312@qq.com",
    "bus_exp_dt": "2020-12-30",
    "fee_rat_scan": "0.38",
    "crp_nm": "小胖",
    "stoe_cnt_nm": "小胖",
    "yhkpay_flg": "Y",
    "fee_rat": "0.5"
    "signValue": "",

}

机构密钥:B665BA9955D3F61315E94C64E028A849

排序后数据:Y小胖上海浦东鲁能国际中心2020-12-30000000000002020-11-12310115199601012538小胖12321312@qq.com7011上海浦东鲁能国际中心营业执照地址518606060162284804025648900181上海浦东鲁能国际中心门店地址460108小胖17621250727上海浦东鲁能国际中心门店名1V1.0.1318100000019YB665BA9955D3F61315E94C64E028A849

注意 参数名小写排序,参数值不用小写,设备key不需小写,signvalue值为小写,排完序后去除所有空格

signValue值--MD5加签后数据:ce11955611642a0561f27f51d24d8b8e

results matching ""

    No results matching ""