Module: open-service-node-sdk/lib/sign

计算签名:sha1(sort(arg1, arg2, arg3...))

Parameters:
Name Type Attributes Description
rest String <repeatable>

变长参数

Author:
Source:
Returns:

签名

Type
String
Example
const sign = require('open-service-node-sdk/lib/sign');

const token = '123456';
const timestamp = new Date().getTime();
const nonce = 'abc123';
const encrypt = 'ol5ZdzGiGK9yXYIuKB0wb5I4DTnZwkNcuo0b3OZgCUNqMRIdb9mfsmjVEe5vJT+pp7M5kyY8lfxFGnrT/qr0UER9v+skaX5GQ59AEtILoe4=';

const signature = sign(timestamp, nonce, token, encrypt); // 参数顺序随意