-
Notifications
You must be signed in to change notification settings - Fork 35
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
11 changed files
with
262 additions
and
34 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,6 +3,7 @@ | |
|
||
# nyc test coverage | ||
.nyc_output | ||
coverage/ | ||
|
||
# Dependency directories | ||
node_modules/ | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<ebicsKeyManagementResponse xmlns="urn:org:ebics:H004" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" Revision="1" Version="H004" xsi:schemaLocation="urn:org:ebics:H004 ebics_keymgmt_response_H004.xsd"> | ||
<header authenticate="true"> | ||
<static/> | ||
<mutable> | ||
<ReturnCode>000000</ReturnCode> | ||
<ReportText>[EBICS_OK] OK</ReportText> | ||
</mutable> | ||
</header> | ||
<body> | ||
<DataTransfer> | ||
<DataEncryptionInfo authenticate="true"> | ||
<EncryptionPubKeyDigest Algorithm="http://www.w3.org/2001/04/xmlenc#sha256" Version="E002">nuZyAjQoIvH4MwnrCWB82TC/vcNqigpqPtMXwO1Xk9U=</EncryptionPubK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up2Dfnlfu26MDblC8+aiaPHypmPuzREqGjW/9d2vtLQz0IXX3X6H4pFXneSjKlwXlDk1WGuiOvXH4gmXEpfWTX9rq+rUyskwwL8ssW5eeeyJ5W2LhVKQllOi/bvrAL5kyrfDMxvOuFIBLxBf//xE</OrderData> | ||
</DataTransfer> | ||
<ReturnCode authenticate="true">000000</ReturnCode> | ||
<TimestampBankParameter authenticate="true">2016-08-10T16:16:17.512Z</TimestampBankParameter> | ||
</body> | ||
</ebicsKeyManagementResponse> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<HPBResponseOrderData xmlns="urn:org:ebics:H004" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ds="http://www.w3.org/2000/09/xmldsig#" xsi:schemaLocation="urn:org:ebics:H004 ebics_orders_H004.xsd"> | ||
<AuthenticationPubKeyInfo> | ||
<PubKeyValue> | ||
<ds:RSAKeyValue> | ||
<ds:Modulus>AJWVHQIfP0H1fr5Y7IjSlDmFksqQ+0E+CjzbEeE6r444LCuSXwbGKF6DJqguyX1qGYxjHRvVtdkNa+GNAtlZnmuPeLHPBUOs5Zx9J5JP4JZOcKd/wnRDIasTkg3NrtZ22tjOrWx26VuR6h7dUH2oJRnFDHmbXoCDMxkqJUNr/TM89p5slJ9Oj5+NAaOzm+7AlwbJ95EI/xc2jEfhp+GdF9CYdS/m2AZaAt79y6QDtBSDdAs0OHTgsOIjbjZkptBF/Gkip2sOordjsChRNLHLDcAOWbsg1NVMuhXs1b6+bCVLXQcGhFydYhqvrXB7pFS0++hlyzqGhbZK5cwEe/v8EJk=</ds:Modulus> | ||
<ds:Exponent>AQAB</ds:Exponent> | ||
</ds:RSAKeyValue> | ||
</PubKeyValue> | ||
<AuthenticationVersion>X002</AuthenticationVersion> | ||
</AuthenticationPubKeyInfo> | ||
<EncryptionPubKeyInfo> | ||
<PubKeyValue> | ||
<ds:RSAKeyValue> | ||
<ds:Modulus>AJWVHQIfP0H1fr5Y7IjSlDmFksqQ+0E+CjzbEeE6r444LCuSXwbGKF6DJqguyX1qGYxjHRvVtdkNa+GNAtlZnmuPeLHPBUOs5Zx9J5JP4JZOcKd/wnRDIasTkg3NrtZ22tjOrWx26VuR6h7dUH2oJRnFDHmbXoCDMxkqJUNr/TM89p5slJ9Oj5+NAaOzm+7AlwbJ95EI/xc2jEfhp+GdF9CYdS/m2AZaAt79y6QDtBSDdAs0OHTgsOIjbjZkptBF/Gkip2sOordjsChRNLHLDcAOWbsg1NVMuhXs1b6+bCVLXQcGhFydYhqvrXB7pFS0++hlyzqGhbZK5cwEe/v8EJk=</ds:Modulus> | ||
<ds:Exponent>AQAB</ds:Exponent> | ||
</ds:RSAKeyValue> | ||
</PubKeyValue> | ||
<EncryptionVersion>E002</EncryptionVersion> | ||
</EncryptionPubKeyInfo> | ||
<HostID>CRSISOTB</HostID> | ||
</HPBResponseOrderData> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
<h004:ebicsKeyManagementResponse xmlns:h004="urn:org:ebics:H004" xmlns:ds="http://www.w3.org/2000/09/xmldsig#" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="urn:org:ebics:H004 ebics_H004.xsd" Version="H004" Revision="1"> | ||
<h004:header authenticate="true"> | ||
<h004:static /> | ||
<h004:mutable> | ||
<h004:OrderID>B004</h004:OrderID> | ||
<h004:ReturnCode>000000</h004:ReturnCode> | ||
<h004:ReportText>[EBICS_OK] OK</h004:ReportText> | ||
</h004:mutable> | ||
</h004:header> | ||
<h004:body> | ||
<h004:ReturnCode authenticate="true">000000</h004:ReturnCode> | ||
</h004:body> | ||
</h004:ebicsKeyManagementResponse> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<ebicsResponse xmlns="urn:org:ebics:H004" xmlns:ds="http://www.w3.org/2000/09/xmldsig#" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="urn:org:ebics:H004 http://www.ebics.org/H004/ebics_response_H004.xsd" Version="H004" Revision="1"> | ||
<header authenticate="true"> | ||
<static> | ||
<TransactionID>ECD6F062AAEDFA77250526A68CBEC549</TransactionID> | ||
<NumSegments>2</NumSegments> | ||
</static> | ||
<mutable> | ||
<TransactionPhase>Initialisation</TransactionPhase> | ||
<SegmentNumber lastSegment="false">1</SegmentNumber> | ||
<ReturnCode>000000</ReturnCode> | ||
<ReportText>[EBICS_OK] OK</ReportText> | ||
</mutable> | ||
</header> | ||
<AuthSignature> | ||
<ds:SignedInfo> | ||
<ds:CanonicalizationMethod Algorithm="http://www.w3.org/TR/2001/REC-xml-c14n-20010315"/> | ||
<ds:SignatureMethod Algorithm="http://www.w3.org/2001/04/xmldsig-more#rsa-sha256"/> | ||
<ds:Reference URI="#xpointer(//*[@authenticate='true'])"> | ||
<ds:Transforms> | ||
<ds:Transform Algorithm="http://www.w3.org/TR/2001/REC-xml-c14n-20010315"/> | ||
</ds:Transforms> | ||
<ds:DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"/> | ||
<ds:DigestValue>OnY4VczV+1XfplpMS/SCKFWn+FDMge40X8TJ9pA6HEI=</ds:DigestValue> | ||
</ds:Reference> | ||
</ds:SignedInfo> | ||
<ds:SignatureValue>Qiz8clr/Ym+wLpB8CzTuxKP5rgIR2P4SaX8O4gGZx0Di8Lzd4hsBO3koqIuX11NRZo0RYA5E/IKQCoYLepkcM4QHvLT37YidbrXsTZe6cml/yF8OdyRAcd/9U7AoA9GKENFk4lnBFfZYmM4ADK6wVOCE/ABaOk0NeCDDbxrKA75tfTxwxTvQBfUOHZ87LrZxuQf//L9pzmtI07/7GbsQX8ZceQq40SpBFZn/oRvT/Q38Qu2ZO59MZexJn+BTzlhpfv9fQGF/sgXkdhUkPTEW3nL4j7ehasq3CtySGO2RnEppohEvJ4m07RDtEY3OWyAAZoPFVpvnECM6pOLbIuR40w==</ds:SignatureValue> | ||
</AuthSignature> | ||
<body> | ||
<DataTransfer> | ||
<DataEncryptionInfo authenticate="true"> | ||
<EncryptionPubKeyDigest Algorithm="http://www.w3.org/2001/04/xmlenc#sha256" Version="E002">IUW05JB5cuCzRYYa4kIAZ2ehYVrLI3lKvxZvo1uP+ug=</EncryptionPubKeyDigest> | ||
<TransactionKey>CPdd6ODXrCxHWpYrwS/5a3NIZ1R2SDscHHJSONc2I7g8ara7qv5Ra7H03W+336DPQLZQxH+EBRWdE2FQ1vrVTcypK6fkFarmO1dEtQt6Ka89AozC7aQMyp4yGl+zlF+XvFkJXZbRXgoEOPsgcG0xM6nKLXnr1ThYRFOoAasigLDGwqxliyhoR94F9dL7YB8Le/uZeRj78mNp4smkE5ZKKyPhwVx+0IW78YuVCSC2c2qbsMmm4evAvycdpLfuuoG4KVlNMIlvkKeBfMZFELcmeKKm85D2zPYkZ7cqG2IfAAp5qdS6K8P7RY4gtjUhOtP5mi8bZt/ZcjioUmIR9dAMnA==</TransactionKey> | ||
</DataEncryptionInfo> | ||
<OrderData>lJ/v1HvOYAZKTPkxULH4mOcUy01+EaAsxLzCPhtieAo9m5AtU5URdyBVfmclHbtWe3ELb02lR37bChynq0Esqpljxx7CiB+kl/bVs7XkNQQmtGPlh08O7ApJ7AHdKPFFvE+SM2OWpSwUrqJGtmyaU6s+RM66o/3Q0wvKi4y3+Q2jm8nkiWZpPfNt52g4ReE9Ge86o+L+EBOBgZm634L5Z/i6pq908mXBAklPdk1ERdEgWONaOeYYmB70FToplR1gINJEF2CnfAtD/wV+DuQFPDth+EWHqhe3a4xO0d9eJ55ou2QCYOPUC2g/qz1sp7GR74W7P5IWJdmnUEuPFsKJ6OvM+1V8S06jZGDa/QhUGDK8F3G/TMP09W1MsrlQTRr3YQ5H43+pMY7I6Jysze+X9OKZZTTpv4GmYm1USjmraGyMuPF3j9hrlmpttK+1gg2WzytCJO44YsZp9ckls8JNK4bT5uwTuomKZoRgmiIOTcMh4VP7V28TWj2XdF+T6rBFILTvQyXMOzvbe1kLwg2O31JDBdJ8X1fHCYJxKsIrYCSDPz4sha8h7QmHrCSFmjoXb+LUElnbLXZVRkY5/Dc73EM6Es3wAgjwSJK2asRqdqU0PhbS5qpIlgYKsNcb+Wes</OrderData> | ||
</DataTransfer> | ||
<ReturnCode authenticate="true">000000</ReturnCode> | ||
<TimestampBankParameter authenticate="true">2013-12-09T15:14:30.000Z</TimestampBankParameter> | ||
</body> | ||
</ebicsResponse> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<ebicsResponse xmlns="urn:org:ebics:H004" xmlns:ds="http://www.w3.org/2000/09/xmldsig#" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="urn:org:ebics:H004 http://www.ebics.org/H004/ebics_response_H004.xsd" Version="H004" Revision="1"> | ||
<header authenticate="true"> | ||
<static> | ||
<TransactionID>ECD6F062AAEDFA77250526A68CBEC549</TransactionID> | ||
<NumSegments>1</NumSegments> | ||
</static> | ||
<mutable> | ||
<TransactionPhase>Initialisation</TransactionPhase> | ||
<SegmentNumber lastSegment="true">1</SegmentNumber> | ||
<ReturnCode>000000</ReturnCode> | ||
<ReportText>[EBICS_OK] OK</ReportText> | ||
</mutable> | ||
</header> | ||
<AuthSignature> | ||
<ds:SignedInfo> | ||
<ds:CanonicalizationMethod Algorithm="http://www.w3.org/TR/2001/REC-xml-c14n-20010315"/> | ||
<ds:SignatureMethod Algorithm="http://www.w3.org/2001/04/xmldsig-more#rsa-sha256"/> | ||
<ds:Reference URI="#xpointer(//*[@authenticate='true'])"> | ||
<ds:Transforms> | ||
<ds:Transform Algorithm="http://www.w3.org/TR/2001/REC-xml-c14n-20010315"/> | ||
</ds:Transforms> | ||
<ds:DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"/> | ||
<ds:DigestValue>OnY4VczV+1XfplpMS/SCKFWn+FDMge40X8TJ9pA6HEI=</ds:DigestValue> | ||
</ds:Reference> | ||
</ds:SignedInfo> | ||
<ds:SignatureValue>Qiz8clr/Ym+wLpB8CzTuxKP5rgIR2P4SaX8O4gGZx0Di8Lzd4hsBO3koqIuX11NRZo0RYA5E/IKQCoYLepkcM4QHvLT37YidbrXsTZe6cml/yF8OdyRAcd/9U7AoA9GKENFk4lnBFfZYmM4ADK6wVOCE/ABaOk0NeCDDbxrKA75tfTxwxTvQBfUOHZ87LrZxuQf//L9pzmtI07/7GbsQX8ZceQq40SpBFZn/oRvT/Q38Qu2ZO59MZexJn+BTzlhpfv9fQGF/sgXkdhUkPTEW3nL4j7ehasq3CtySGO2RnEppohEvJ4m07RDtEY3OWyAAZoPFVpvnECM6pOLbIuR40w==</ds:SignatureValue> | ||
</AuthSignature> | ||
<body> | ||
<DataTransfer> | ||
<DataEncryptionInfo authenticate="true"> | ||
<EncryptionPubKeyDigest Algorithm="http://www.w3.org/2001/04/xmlenc#sha256" Version="E002">IUW05JB5cuCzRYYa4kIAZ2ehYVrLI3lKvxZvo1uP+ug=</EncryptionPubKeyDigest> | ||
<TransactionKey>CPdd6ODXrCxHWpYrwS/5a3NIZ1R2SDscHHJSONc2I7g8ara7qv5Ra7H03W+336DPQLZQxH+EBRWdE2FQ1vrVTcypK6fkFarmO1dEtQt6Ka89AozC7aQMyp4yGl+zlF+XvFkJXZbRXgoEOPsgcG0xM6nKLXnr1ThYRFOoAasigLDGwqxliyhoR94F9dL7YB8Le/uZeRj78mNp4smkE5ZKKyPhwVx+0IW78YuVCSC2c2qbsMmm4evAvycdpLfuuoG4KVlNMIlvkKeBfMZFELcmeKKm85D2zPYkZ7cqG2IfAAp5qdS6K8P7RY4gtjUhOtP5mi8bZt/ZcjioUmIR9dAMnA==</TransactionKey> | ||
</DataEncryptionInfo> | ||
<OrderData>lJ/v1HvOYAZKTPkxULH4mOcUy01+EaAsxLzCPhtieAo9m5AtU5URdyBVfmclHbtWe3ELb02lR37bChynq0Esqpljxx7CiB+kl/bVs7XkNQQmtGPlh08O7ApJ7AHdKPFFvE+SM2OWpSwUrqJGtmyaU6s+RM66o/3Q0wvKi4y3+Q2jm8nkiWZpPfNt52g4ReE9Ge86o+L+EBOBgZm634L5Z/i6pq908mXBAklPdk1ERdEgWONaOeYYmB70FToplR1gINJEF2CnfAtD/wV+DuQFPDth+EWHqhe3a4xO0d9eJ55ou2QCYOPUC2g/qz1sp7GR74W7P5IWJdmnUEuPFsKJ6OvM+1V8S06jZGDa/QhUGDK8F3G/TMP09W1MsrlQTRr3YQ5H43+pMY7I6Jysze+X9OKZZTTpv4GmYm1USjmraGyMuPF3j9hrlmpttK+1gg2WzytCJO44YsZp9ckls8JNK4bT5uwTuomKZoRgmiIOTcMh4VP7V28TWj2XdF+T6rBFILTvQyXMOzvbe1kLwg2O31JDBdJ8X1fHCYJxKsIrYCSDPz4sha8h7QmHrCSFmjoXb+LUElnbLXZVRkY5/Dc73EM6Es3wAgjwSJK2asRqdqU0PhbS5qpIlgYKsNcb+Wes</OrderData> | ||
</DataTransfer> | ||
<ReturnCode authenticate="true">000000</ReturnCode> | ||
<TimestampBankParameter authenticate="true">2013-12-09T15:14:30.000Z</TimestampBankParameter> | ||
</body> | ||
</ebicsResponse> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
'use strict'; | ||
|
||
/* eslint-env node, mocha */ | ||
|
||
const { assert } = require('chai'); | ||
|
||
const response = require('../../lib/middleware/response'); | ||
const serializer = require('../../lib/middleware/serializer'); | ||
const signer = require('../../lib/middleware/signer'); | ||
|
||
describe('Middlewares', () => { | ||
describe('Response Middleware', () => { | ||
it('should throw with no unspported protocol version', () => assert.throws(() => response('H003'))); | ||
}); | ||
describe('Signer Middleware', () => { | ||
it('should throw with no unspported protocol version', () => assert.throws(() => signer('H003'))); | ||
}); | ||
describe('Signer Middleware', () => { | ||
it('should throw with no unspported protocol version', () => assert.throws(() => serializer('H003'))); | ||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters