node-ebics-client/lib/middleware/XMLSign.js

23 lines
378 B
JavaScript
Raw Normal View History

2018-05-17 15:03:59 +00:00
'use strict';
const Signer = require('../Signer');
module.exports = class XMLSign {
constructor(client, data) {
this.client = client;
this.data = data;
2018-06-01 13:16:43 +00:00
}
2018-05-17 15:03:59 +00:00
2018-06-01 13:16:43 +00:00
static go(client, data) {
// const xmlSigner = new XMLSign(client, data);
2018-05-17 15:03:59 +00:00
const signer = new Signer(client, data);
signer.digest();
signer.sign();
this.data = signer.toXML();
return this.data;
}
};