mirror of
https://github.com/node-ebics/node-ebics-client.git
synced 2024-11-24 23:22:06 +00:00
23 lines
377 B
JavaScript
23 lines
377 B
JavaScript
|
'use strict';
|
||
|
|
||
|
const Signer = require('../Signer');
|
||
|
|
||
|
module.exports = class XMLSign {
|
||
|
constructor(client, data) {
|
||
|
this.client = client;
|
||
|
this.data = data;
|
||
|
};
|
||
|
|
||
|
static go (client, data) {
|
||
|
const xmlSigner = new XMLSign(client, data);
|
||
|
const signer = new Signer(client, data);
|
||
|
|
||
|
signer.digest();
|
||
|
signer.sign();
|
||
|
|
||
|
this.data = signer.toXML();
|
||
|
|
||
|
return this.data;
|
||
|
}
|
||
|
};
|