From 9dc0e72571a895e34a55c11d015c5d359b485aff Mon Sep 17 00:00:00 2001 From: Christof Rabensteiner Date: Fri, 12 Jul 2019 08:31:42 +0200 Subject: Renamed and Simplified SignatureVerifier --- .../gv/egiz/moazs/backend/SignatureVerifier.java | 67 ++++++++++++---------- src/main/resources/application.yaml | 1 + .../egiz/moazs/ITMoaSPSSSignatureVerifierTest.java | 55 ------------------ .../at/gv/egiz/moazs/ITSignatureVerifierTest.java | 55 ++++++++++++++++++ .../invalid-signed-delivery-response.xml | 30 ---------- .../valid-signed-delivery-response.xml | 30 ---------- .../invalid-signed-delivery-response.xml | 30 ++++++++++ .../valid-signed-delivery-response.xml | 30 ++++++++++ 8 files changed, 154 insertions(+), 144 deletions(-) delete mode 100644 src/test/java/at/gv/egiz/moazs/ITMoaSPSSSignatureVerifierTest.java create mode 100644 src/test/java/at/gv/egiz/moazs/ITSignatureVerifierTest.java delete mode 100644 src/test/resources/at/gv/egiz/moazs/ITMoaSPSSSignatureVerifierTest/invalid-signed-delivery-response.xml delete mode 100644 src/test/resources/at/gv/egiz/moazs/ITMoaSPSSSignatureVerifierTest/valid-signed-delivery-response.xml create mode 100644 src/test/resources/at/gv/egiz/moazs/ITSignatureVerifierTest/invalid-signed-delivery-response.xml create mode 100644 src/test/resources/at/gv/egiz/moazs/ITSignatureVerifierTest/valid-signed-delivery-response.xml diff --git a/src/main/java/at/gv/egiz/moazs/backend/SignatureVerifier.java b/src/main/java/at/gv/egiz/moazs/backend/SignatureVerifier.java index e9c5387..f9bbeb3 100644 --- a/src/main/java/at/gv/egiz/moazs/backend/SignatureVerifier.java +++ b/src/main/java/at/gv/egiz/moazs/backend/SignatureVerifier.java @@ -16,6 +16,23 @@ public class SignatureVerifier implements Consumer { private static final Logger log = LoggerFactory.getLogger(SignatureVerifier.class); private static final int OK_CODE = 0; + private static final String MOASPSS_FAILED_ERROR_MSG = "MOA SPSS could not find the signature. "; + private static final String SIGNATURE_CODE_ERROR_MSG = "Signature is not valid: Check code was %d. "; + private static final String CERT_CODE_ERROR_MSG = "Certificate chain is not valid: Check code was %d. "; + private static final String MANIFEST_CODE_ERROR_MSG = "Signature Manifest is not valid: Check code was %d. "; + private static final String XMLMANIFEST_CODE_ERROR_MSG = "XmlDSIGManifest is not valid: Check code was %d. "; + private static final String XML_SIGNATURE_RESPONSE_TEMPLATE = + " XmlDsigSubjectName: %s\n" + + " SignatureManifestCheckCode: %s\n" + + " XmlDSIGManifestCheckCode: %s\n" + + " CertificateCheckCode: %s\n" + + " SignatureCheckCode: %s\n" + + " SigningDateTime: %s\n" + + " isXmlDSIGManigest: %s\n" + + " isPublicAuthority: %s\n" + + " isQualifiedCertificate: %s\n" + + " getPublicAuthorityCode: %s\n"; + private static final String MOASIG_SERVICE_ERROR_MSG = "MOA SPSS could not accept the XML signature. "; private final ISignatureVerificationService service; private final String trustProfile; @@ -40,29 +57,24 @@ public class SignatureVerifier implements Consumer { try { var response = service.verifyXMLSignature(signedXMLdocument, trustProfile); - if (log.isDebugEnabled()) { - print(response); - } + debug(response); if (response == null) { - throw moaZSException("MOA SPSS could not find the signature. "); + throw moaZSException(MOASPSS_FAILED_ERROR_MSG); } var builder = new StringBuilder(); if (response.getSignatureCheckCode() != OK_CODE) { - builder.append(format("Signature is not valid; SignatureCheckCode was %d. ", - response.getSignatureCheckCode())); + builder.append(format(SIGNATURE_CODE_ERROR_MSG, response.getSignatureCheckCode())); } if (response.getCertificateCheckCode() != OK_CODE) { - builder.append(format("Certificate chain is not valid; CertificateCheckCode was %d. ", - response.getCertificateCheckCode())); + builder.append(format(CERT_CODE_ERROR_MSG, response.getCertificateCheckCode())); } if (response.getSignatureManifestCheckCode() != OK_CODE) { - var signatureManifestErrorMsg = format("Signature Manifest is not valid; " + - "SignatureManifestCheckCode was %d. ", response.getSignatureManifestCheckCode()); + var signatureManifestErrorMsg = format(MANIFEST_CODE_ERROR_MSG, response.getSignatureManifestCheckCode()); if (isManifestCheckActive) { builder.append(signatureManifestErrorMsg); } else { @@ -71,8 +83,7 @@ public class SignatureVerifier implements Consumer { } if (response.isXmlDSIGManigest() && response.getXmlDSIGManifestCheckCode() != OK_CODE) { - var xmlDSIGManifestErrorMsg = format("XmlDSIGManifest Manifest is not valid; " + - "XmlDSIGManifest was %d. ", response.getXmlDSIGManifestCheckCode()); + var xmlDSIGManifestErrorMsg = format(XMLMANIFEST_CODE_ERROR_MSG, response.getXmlDSIGManifestCheckCode()); if (isManifestCheckActive) { builder.append(xmlDSIGManifestErrorMsg); } else { @@ -87,30 +98,28 @@ public class SignatureVerifier implements Consumer { } } catch (MOASigServiceException e) { - throw moaZSExceptionBuilder("Could not accept the XML signature.") + throw moaZSExceptionBuilder(MOASIG_SERVICE_ERROR_MSG) .withCause(e) .build(); } } - private void print(IXMLSignatureVerificationResponse response) { - log.debug("Response:"); + public static void debug(IXMLSignatureVerificationResponse response) { + if (log.isDebugEnabled()) { + var builder = new StringBuilder("Response: \n"); + if (response == null) { + builder.append("null"); + } else { + var objects = new Object[]{response.getXmlDsigSubjectName(), response.getSignatureManifestCheckCode(), + response.getXmlDSIGManifestCheckCode(), response.getCertificateCheckCode(), + response.getSignatureCheckCode(), response.getSigningDateTime(), response.isXmlDSIGManigest(), + response.isPublicAuthority(), response.isQualifiedCertificate(), + response.getPublicAuthorityCode()}; + builder.append(String.format(XML_SIGNATURE_RESPONSE_TEMPLATE, objects)); + } - if (response == null) { - log.debug("null"); - return; + log.debug(builder.toString()); } - - log.debug(" XmlDsigSubjectName: {}", response.getXmlDsigSubjectName()); - log.debug(" SignatureManifestCheckCode: {}", response.getSignatureManifestCheckCode()); - log.debug(" XmlDSIGManifestCheckCode: {}", response.getXmlDSIGManifestCheckCode()); - log.debug(" CertificateCheckCode: {}", response.getCertificateCheckCode()); - log.debug(" SignatureCheckCode: {}", response.getSignatureCheckCode()); - log.debug(" SigningDateTime: {}", response.getSigningDateTime()); - log.debug(" isXmlDSIGManigest: {}", response.isXmlDSIGManigest()); - log.debug(" isPublicAuthority: {}", response.isPublicAuthority()); - log.debug(" isQualifiedCertificate: {}", response.isQualifiedCertificate()); - log.debug(" getPublicAuthorityCode: {}", response.getPublicAuthorityCode()); } } diff --git a/src/main/resources/application.yaml b/src/main/resources/application.yaml index ca8221c..0e7b67e 100644 --- a/src/main/resources/application.yaml +++ b/src/main/resources/application.yaml @@ -55,6 +55,7 @@ logging: org.springframework: WARN at.gv: INFO #DEBUG iaik: INFO #DEBUG + at.gv.egiz.moazs.backend.SignatureVerifier: DEBUG # default type for java's ssl key/trust store javax.net.ssl: diff --git a/src/test/java/at/gv/egiz/moazs/ITMoaSPSSSignatureVerifierTest.java b/src/test/java/at/gv/egiz/moazs/ITMoaSPSSSignatureVerifierTest.java deleted file mode 100644 index 34f4e1b..0000000 --- a/src/test/java/at/gv/egiz/moazs/ITMoaSPSSSignatureVerifierTest.java +++ /dev/null @@ -1,55 +0,0 @@ -package at.gv.egiz.moazs; - -import at.gv.egiz.eid.authhandler.modules.sigverify.moasig.api.ISignatureVerificationService; -import at.gv.egiz.moazs.backend.SignatureVerifier; -import org.junit.Test; -import org.junit.runner.RunWith; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.boot.test.context.SpringBootTest; -import org.springframework.boot.test.context.TestConfiguration; -import org.springframework.context.annotation.Bean; -import org.springframework.test.context.junit4.SpringRunner; - -import java.io.File; -import java.io.IOException; -import java.nio.file.Files; - -//Note: Certificate that signed these delivery responses expires in 2023-09-27. -@RunWith(SpringRunner.class) -@SpringBootTest - public class ITMoaSPSSSignatureVerifierTest { - - private final String resourcesPath = "src/test/resources/at/gv/egiz/moazs/ITMoaSPSSSignatureVerifierTest/"; - - @TestConfiguration - public class Config{ - - @Bean - public SignatureVerifier verifier(@Autowired ISignatureVerificationService service){ - return new SignatureVerifier(service, "test-trust-profile", true); - } - - } - - @Autowired - private SignatureVerifier verifier; - - @Test - public void acceptValidSignedDeliveryResponse() throws IOException { - - var path = resourcesPath + "valid-signed-delivery-response.xml"; - var signature = Files.readAllBytes(new File(path).toPath()); - - verifier.accept(signature); - } - - @Test(expected = MoaZSException.class) - public void rejectInvalidSignedDeliveryResponse() throws IOException { - - var path = resourcesPath + "invalid-signed-delivery-response.xml"; - var signature = Files.readAllBytes(new File(path).toPath()); - - verifier.accept(signature); - } - -} diff --git a/src/test/java/at/gv/egiz/moazs/ITSignatureVerifierTest.java b/src/test/java/at/gv/egiz/moazs/ITSignatureVerifierTest.java new file mode 100644 index 0000000..e4dbec7 --- /dev/null +++ b/src/test/java/at/gv/egiz/moazs/ITSignatureVerifierTest.java @@ -0,0 +1,55 @@ +package at.gv.egiz.moazs; + +import at.gv.egiz.eid.authhandler.modules.sigverify.moasig.api.ISignatureVerificationService; +import at.gv.egiz.moazs.backend.SignatureVerifier; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.boot.test.context.SpringBootTest; +import org.springframework.boot.test.context.TestConfiguration; +import org.springframework.context.annotation.Bean; +import org.springframework.test.context.junit4.SpringRunner; + +import java.io.File; +import java.io.IOException; +import java.nio.file.Files; + +//Note: Certificate that signed these delivery responses expires in 2023-09-27. +@RunWith(SpringRunner.class) +@SpringBootTest + public class ITSignatureVerifierTest { + + private final String resourcesPath = "src/test/resources/at/gv/egiz/moazs/ITSignatureVerifierTest/"; + + @TestConfiguration + public class Config{ + + @Bean + public SignatureVerifier verifier(@Autowired ISignatureVerificationService service){ + return new SignatureVerifier(service, "test-trust-profile", true); + } + + } + + @Autowired + private SignatureVerifier verifier; + + @Test + public void acceptValidSignedDeliveryResponse() throws IOException { + + var path = resourcesPath + "valid-signed-delivery-response.xml"; + var signature = Files.readAllBytes(new File(path).toPath()); + + verifier.accept(signature); + } + + @Test(expected = MoaZSException.class) + public void rejectInvalidSignedDeliveryResponse() throws IOException { + + var path = resourcesPath + "invalid-signed-delivery-response.xml"; + var signature = Files.readAllBytes(new File(path).toPath()); + + verifier.accept(signature); + } + +} diff --git a/src/test/resources/at/gv/egiz/moazs/ITMoaSPSSSignatureVerifierTest/invalid-signed-delivery-response.xml b/src/test/resources/at/gv/egiz/moazs/ITMoaSPSSSignatureVerifierTest/invalid-signed-delivery-response.xml deleted file mode 100644 index b850145..0000000 --- a/src/test/resources/at/gv/egiz/moazs/ITMoaSPSSSignatureVerifierTest/invalid-signed-delivery-response.xml +++ /dev/null @@ -1,30 +0,0 @@ -https://testzustellsystem.egiz.gv.atmanipulated-delivery-idmanipulated-delivery-request-id00000ejvUI0yh/IIyauFe8x5ZonD/i5oznl8vFyS3oLNivzA=hmVZrLkMDbXaRLYQKOaV3OtK13TQgMu3csKyw9M4zWqNyva1yxnYkzoX3dKDOdc9 -O56yQJsjoA3Cuw7pXlGO7jSfVM77dTXbWSDaF95O9Vdsrmr7R6Uki0jA9SmgQLXg -hZAUG8JpsHcBn8M0L2BXADKjSn0LuMDL2L7dmU3EM7eRy+OvFwDrXDw1fhjQO6L2 -KoflAWLgUerDhJSpzr0+YfmkrjzitLUA7oIg8ieOnfGyql31ECmDJEqgnL78hyPZ -KaNZImDf3EWFs8je6mt+os1TwsyXYwz+GGbjoDR8lGTS9xVqnXdrgP8Jyv6p9FEu -0IYgSY2FlbI3skPZC8ZVXg==MIIEqzCCBBSgAwIBAgIHANux81oNezANBgkqhkiG9w0BAQUFADBAMSIwIAYDVQQD -ExlJQUlLIFRlc3QgSW50ZXJtZWRpYXRlIENBMQ0wCwYDVQQKEwRJQUlLMQswCQYD -VQQGEwJBVDAeFw0xMzA5MjcwNTMzMzdaFw0yMzA5MjcwNTMzMzdaMIHkMQswCQYD -VQQGEwJBVDENMAsGA1UEBxMER3JhejEmMCQGA1UEChMdR3JheiBVbml2ZXJzaXR5 -IG9mIFRlY2hub2xvZ3kxSDBGBgNVBAsTP0luc3RpdHV0ZSBmb3IgQXBwbGllZCBJ -bmZvcm1hdGlvbiBQcm9jZXNzaW5nIGFuZCBDb21tdW5pY2F0aW9uczEUMBIGA1UE -BBMLTU9BLVNTIFRlc3QxGDAWBgNVBCoTD0VHSVogV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FHLQwyVo8JWb -gvRkHHDUv2o8ofXUY2R2WJ38dxeDoccgbXrJb/Qhi8IY7YhCwv/TuIZDisyAqo8W -ORKSip/6HWlGCSR/Vgoet1GtCmF0FoUxFUIGSAuQ2yyt4fIzt5GJrU1X5ujjI1w= diff --git a/src/test/resources/at/gv/egiz/moazs/ITMoaSPSSSignatureVerifierTest/valid-signed-delivery-response.xml b/src/test/resources/at/gv/egiz/moazs/ITMoaSPSSSignatureVerifierTest/valid-signed-delivery-response.xml deleted file mode 100644 index 59a90cf..0000000 --- a/src/test/resources/at/gv/egiz/moazs/ITMoaSPSSSignatureVerifierTest/valid-signed-delivery-response.xml +++ /dev/null @@ -1,30 +0,0 @@ -https://testzustellsystem.egiz.gv.atzs-valid-delivery-request-idvalid-delivery-request-id12345ejvUI0yh/IIyauFe8x5ZonD/i5oznl8vFyS3oLNivzA=hmVZrLkMDbXaRLYQKOaV3OtK13TQgMu3csKyw9M4zWqNyva1yxnYkzoX3dKDOdc9 -O56yQJsjoA3Cuw7pXlGO7jSfVM77dTXbWSDaF95O9Vdsrmr7R6Uki0jA9SmgQLXg -hZAUG8JpsHcBn8M0L2BXADKjSn0LuMDL2L7dmU3EM7eRy+OvFwDrXDw1fhjQO6L2 -KoflAWLgUerDhJSpzr0+YfmkrjzitLUA7oIg8ieOnfGyql31ECmDJEqgnL78hyPZ -KaNZImDf3EWFs8je6mt+os1TwsyXYwz+GGbjoDR8lGTS9xVqnXdrgP8Jyv6p9FEu -0IYgSY2FlbI3skPZC8ZVXg==MIIEqzCCBBSgAwIBAgIHANux81oNezANBgkqhkiG9w0BAQUFADBAMSIwIAYDVQQD -ExlJQUlLIFRlc3QgSW50ZXJtZWRpYXRlIENBMQ0wCwYDVQQKEwRJQUlLMQswCQYD -VQQGEwJBVDAeFw0xMzA5MjcwNTMzMzdaFw0yMzA5MjcwNTMzMzdaMIHkMQswCQYD -VQQGEwJBVDENMAsGA1UEBxMER3JhejEmMCQGA1UEChMdR3JheiBVbml2Z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S1Rlc3RfSW50ZXJtZWRpYXRlQ0EuY2VyMCEGA1UdEQQaMBiBFnRob21hcy5sZW56 -QGVnaXouZ3YuYXQwHwYDVR0jBBgwFoAUaKJeEdreL4BrRES/jfplNoEkp28wDQYJ -KoZIhvcNAQEFBQADgYEAlFGjUxXLs7SAT8NtXSrv2WrjlklaRnHTFHLQwyVo8JWb -gvRkHHDUv2o8ofXUY2R2WJ38dxeDoccgbXrJb/Qhi8IY7YhCwv/TuIZDisyAqo8W -ORKSip/6HWlGCSR/Vgoet1GtCmF0FoUxFUIGSAuQ2yyt4fIzt5GJrU1X5ujjI1w= diff --git a/src/test/resources/at/gv/egiz/moazs/ITSignatureVerifierTest/invalid-signed-delivery-response.xml b/src/test/resources/at/gv/egiz/moazs/ITSignatureVerifierTest/invalid-signed-delivery-response.xml new file mode 100644 index 0000000..b850145 --- /dev/null +++ b/src/test/resources/at/gv/egiz/moazs/ITSignatureVerifierTest/invalid-signed-delivery-response.xml @@ -0,0 +1,30 @@ +https://testzustellsystem.egiz.gv.atmanipulated-delivery-idmanipulated-delivery-request-id00000ejvUI0yh/IIyauFe8x5ZonD/i5oznl8vFyS3oLNivzA=hmVZrLkMDbXaRLYQKOaV3OtK13TQgMu3csKyw9M4zWqNyva1yxnYkzoX3dKDOdc9 +O56yQJsjoA3Cuw7pXlGO7jSfVM77dTXbWSDaF95O9Vdsrmr7R6Uki0jA9SmgQLXg +hZAUG8JpsHcBn8M0L2BXADKjSn0LuMDL2L7dmU3EM7eRy+OvFwDrXDw1fhjQO6L2 +KoflAWLgUerDhJSpzr0+YfmkrjzitLUA7oIg8ieOnfGyql31ECmDJEqgnL78hyPZ +KaNZImDf3EWFs8je6mt+os1TwsyXYwz+GGbjoDR8lGTS9xVqnXdrgP8Jyv6p9FEu +0IYgSY2FlbI3skPZC8ZVXg==MIIEqzCCBBSgAwIBAgIHANux81oNezANBgkqhkiG9w0BAQUFADBAMSIwIAYDVQQD +ExlJQUlLIFRlc3QgSW50ZXJtZ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mh0dHA6Ly9jYS5pYWlrLnR1Z3Jh +ei5hdC9jYXBzby9PQ1NQP2NhPUlBSUtUZXN0X0ludGVybWVkaWF0ZUNBMEwGCCsG +AQUFBzAChkBodHRwOi8vY2EuaWFpay50dWdyYXouYXQvY2Fwc28vY2VydHMvSUFJ +S1Rlc3RfSW50ZXJtZWRpYXRlQ0EuY2VyMCEGA1UdEQQaMBiBFnRob21hcy5sZW56 +QGVnaXouZ3YuYXQwHwYDVR0jBBgwFoAUaKJeEdreL4BrRES/jfplNoEkp28wDQYJ +KoZIhvcNAQEFBQADgYEAlFGjUxXLs7SAT8NtXSrv2WrjlklaRnHTFHLQwyVo8JWb +gvRkHHDUv2o8ofXUY2R2WJ38dxeDoccgbXrJb/Qhi8IY7YhCwv/TuIZDisyAqo8W +ORKSip/6HWlGCSR/Vgoet1GtCmF0FoUxFUIGSAuQ2yyt4fIzt5GJrU1X5ujjI1w= diff --git a/src/test/resources/at/gv/egiz/moazs/ITSignatureVerifierTest/valid-signed-delivery-response.xml b/src/test/resources/at/gv/egiz/moazs/ITSignatureVerifierTest/valid-signed-delivery-response.xml new file mode 100644 index 0000000..59a90cf --- /dev/null +++ b/src/test/resources/at/gv/egiz/moazs/ITSignatureVerifierTest/valid-signed-delivery-response.xml @@ -0,0 +1,30 @@ +https://testzustellsystem.egiz.gv.atzs-valid-delivery-request-idvalid-delivery-request-id12345ejvUI0yh/IIyauFe8x5ZonD/i5oznl8vFyS3oLNivzA=hmVZrLkMDbXaRLYQKOaV3OtK13TQgMu3csKyw9M4zWqNyva1yxnYkzoX3dKDOdc9 +O56yQJsjoA3Cuw7pXlGO7jSfVM77dTXbWSDaF95O9Vdsrmr7R6Uki0jA9SmgQLXg +hZAUG8JpsHcBn8M0L2BXADKjSn0LuMDL2L7dmU3EM7eRy+OvFwDrXDw1fhjQO6L2 +KoflAWLgUerDhJSpzr0+YfmkrjzitLUA7oIg8ieOnfGyql31ECmDJEqgnL78hyPZ +KaNZImDf3EWFs8je6mt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