change message form of workflow notify
This commit is contained in:
parent
c8926d99be
commit
5e56a91bd3
@ -28,13 +28,13 @@ class WorkFlowController extends BaseController {
|
|||||||
@role('anon')
|
@role('anon')
|
||||||
@router('post /workflow/notify')
|
@router('post /workflow/notify')
|
||||||
async flowNotify(req, res) {
|
async flowNotify(req, res) {
|
||||||
let { msg_signature, timestamp, nonce, xml, Encrypt } = req.params
|
let { msg_signature, timestamp, nonce, xml } = req.params
|
||||||
console.log(xml)
|
console.log(xml)
|
||||||
const signature = getSignature(TOKEN, timestamp, nonce, Encrypt)
|
const signature = getSignature(TOKEN, timestamp, nonce, xml.Encrypt)
|
||||||
if (msg_signature !== signature) {
|
if (msg_signature !== signature) {
|
||||||
throw new ZError(10, 'sign check failed')
|
throw new ZError(10, 'sign check failed')
|
||||||
}
|
}
|
||||||
const { message, id } = decrypt(AES_KEY, Encrypt)
|
const { message, id } = decrypt(AES_KEY, xml.Encrypt)
|
||||||
console.log(id)
|
console.log(id)
|
||||||
console.log(message)
|
console.log(message)
|
||||||
res.send('success')
|
res.send('success')
|
||||||
|
Loading…
x
Reference in New Issue
Block a user