From 86af257df5f7d06344c8c2c5f52134addd5bbd03 Mon Sep 17 00:00:00 2001 From: mark Date: Fri, 22 Oct 2021 12:30:01 +0100 Subject: [PATCH 01/15] Changing version number in examples --- 103120/examples/mutliple-auth-example-request.xml | 2 +- 103120/examples/request1.xml | 2 +- 103120/examples/request2.xml | 2 +- 103120/examples/request3.xml | 2 +- 103120/examples/request4.xml | 2 +- 103120/examples/request5-Binary-Delivery.xml | 2 +- 103120/examples/request5-XML-Delivery.xml | 2 +- 103120/examples/response1.xml | 2 +- 103120/examples/response2.xml | 2 +- 103120/examples/response3.xml | 2 +- 103120/examples/response4.xml | 2 +- 103120/examples/response5.xml | 2 +- 12 files changed, 12 insertions(+), 12 deletions(-) diff --git a/103120/examples/mutliple-auth-example-request.xml b/103120/examples/mutliple-auth-example-request.xml index 5e5f226..8fd893c 100644 --- a/103120/examples/mutliple-auth-example-request.xml +++ b/103120/examples/mutliple-auth-example-request.xml @@ -12,7 +12,7 @@ d442c58c-d5e1-4fd9-90ec-9c228ad947f1 2020-09-22T08:06:17.025833Z - V1.8.1 + V1.10.1 XX v1.1.1 diff --git a/103120/examples/request1.xml b/103120/examples/request1.xml index d0b64ee..a5e40d6 100644 --- a/103120/examples/request1.xml +++ b/103120/examples/request1.xml @@ -12,7 +12,7 @@ c02358b2-76cf-4ba4-a8eb-f6436ccaea2e 2015-09-01T12:00:00.000000Z - V1.8.1 + V1.10.1 XX v1.0 diff --git a/103120/examples/request2.xml b/103120/examples/request2.xml index 67cbefd..2b1d012 100644 --- a/103120/examples/request2.xml +++ b/103120/examples/request2.xml @@ -12,7 +12,7 @@ 45002c1e-dc4a-470a-9152-8e752638c86c 2015-09-01T12:01:00.000000Z - V1.8.1 + V1.10.1 XX v1.0 diff --git a/103120/examples/request3.xml b/103120/examples/request3.xml index c93bb7a..dce6620 100644 --- a/103120/examples/request3.xml +++ b/103120/examples/request3.xml @@ -12,7 +12,7 @@ 69353ac0-9582-4c71-b162-86259c99de20 2015-09-01T12:02:00.000000Z - V1.8.1 + V1.10.1 XX v1.0 diff --git a/103120/examples/request4.xml b/103120/examples/request4.xml index 6296da5..73d6c07 100644 --- a/103120/examples/request4.xml +++ b/103120/examples/request4.xml @@ -12,7 +12,7 @@ c02358b2-76cf-4ba4-a8eb-f6436ccaea2e 2019-09-30T13:37:00.000000Z - V1.8.1 + V1.10.1 XX v1.0 diff --git a/103120/examples/request5-Binary-Delivery.xml b/103120/examples/request5-Binary-Delivery.xml index 7d51707..2a13dfb 100644 --- a/103120/examples/request5-Binary-Delivery.xml +++ b/103120/examples/request5-Binary-Delivery.xml @@ -12,7 +12,7 @@ 8854cfad-44ac-43b8-99ae-530b690b43da 2019-09-30T13:37:37.000000Z - V1.8.1 + V1.10.1 XX v1.0 diff --git a/103120/examples/request5-XML-Delivery.xml b/103120/examples/request5-XML-Delivery.xml index f9314cd..c345dbb 100644 --- a/103120/examples/request5-XML-Delivery.xml +++ b/103120/examples/request5-XML-Delivery.xml @@ -12,7 +12,7 @@ 8854cfad-44ac-43b8-99ae-530b690b43da 2019-09-30T13:37:37.000000Z - V1.8.1 + V1.10.1 XX v1.0 diff --git a/103120/examples/response1.xml b/103120/examples/response1.xml index 25aa22c..54fad1c 100644 --- a/103120/examples/response1.xml +++ b/103120/examples/response1.xml @@ -12,7 +12,7 @@ c02358b2-76cf-4ba4-a8eb-f6436ccaea2e 2015-09-01T12:00:01.000000Z - V1.8.1 + V1.10.1 XX v1.0 diff --git a/103120/examples/response2.xml b/103120/examples/response2.xml index 3f3e550..104a76f 100644 --- a/103120/examples/response2.xml +++ b/103120/examples/response2.xml @@ -12,7 +12,7 @@ 45002c1e-dc4a-470a-9152-8e752638c86c 2015-09-01T12:01:00.000000Z - V1.8.1 + V1.10.1 XX v1.0 diff --git a/103120/examples/response3.xml b/103120/examples/response3.xml index e3b1537..445187d 100644 --- a/103120/examples/response3.xml +++ b/103120/examples/response3.xml @@ -12,7 +12,7 @@ 69353ac0-9582-4c71-b162-86259c99de20 2015-09-01T12:02:00.000000Z - V1.8.1 + V1.10.1 XX v1.0 diff --git a/103120/examples/response4.xml b/103120/examples/response4.xml index a8dc811..3ca45c2 100644 --- a/103120/examples/response4.xml +++ b/103120/examples/response4.xml @@ -12,7 +12,7 @@ c02358b2-76cf-4ba4-a8eb-f6436ccaea2e 2019-09-30T13:37:01.000000Z - V1.8.1 + V1.10.1 XX v1.0 diff --git a/103120/examples/response5.xml b/103120/examples/response5.xml index 32bfcd1..d02dff5 100644 --- a/103120/examples/response5.xml +++ b/103120/examples/response5.xml @@ -17,7 +17,7 @@ 8854cfad-44ac-43b8-99ae-530b690b43da 2019-09-30T13:37:37.000000Z - V1.8.1 + V1.10.1 XX v1.0 -- GitLab From f3f09f7c3888b660d639f273b2164823ac0460cc Mon Sep 17 00:00:00 2001 From: mark Date: Fri, 22 Oct 2021 13:20:15 +0100 Subject: [PATCH 02/15] Updating testing --- testing/check_xsd.py | 31 +- testing/deps/xmldsig/xmldsig-core-schema.xsd | 318 +++++++++++++++++++ 2 files changed, 343 insertions(+), 6 deletions(-) create mode 100644 testing/deps/xmldsig/xmldsig-core-schema.xsd diff --git a/testing/check_xsd.py b/testing/check_xsd.py index db4ee8c..dd6f0fd 100644 --- a/testing/check_xsd.py +++ b/testing/check_xsd.py @@ -11,7 +11,6 @@ from lxml import etree from xml.etree.ElementTree import ParseError from xmlschema import XMLSchema, XMLSchemaParseError - def BuildSchemaDictonary (fileList): if len(fileList) == 0: logging.info("No schema files provided") @@ -22,7 +21,7 @@ def BuildSchemaDictonary (fileList): for schemaFile in fileList: try: xs = XMLSchema(schemaFile, validation='skip') - schemaLocations.append((xs.default_namespace, str(Path(schemaFile).resolve()))) + schemaLocations.append((xs.target_namespace, str(Path(schemaFile).resolve()))) logging.info(" [ {0} -> {1} ]".format(xs.default_namespace, schemaFile)) except ParseError as ex: logging.warning (" [ {0} failed to parse: {1} ]".format(schemaFile, ex)) @@ -53,6 +52,7 @@ def ValidateXSDFiles (fileList): schemaLocations = BuildSchemaDictonary(fileList) errors = {} + schemaDictionary = {} logging.info("Schema validation:") for schemaFile in fileList: @@ -60,6 +60,7 @@ def ValidateXSDFiles (fileList): schema = XMLSchema(schemaFile, locations = schemaLocations) logging.info(schemaFile + ": OK") errors[schemaFile] = [] + schemaDictionary[schema.target_namespace] = schema except XMLSchemaParseError as ex: if (ex.schema_url) and (ex.schema_url != ex.origin_url): logging.info(" Error {1} comes from {0}, suppressing".format(ex.schema_url, ex.message)) @@ -67,7 +68,7 @@ def ValidateXSDFiles (fileList): else: logging.warning(schemaFile + ": Failed validation ({0})".format(ex)) errors[schemaFile] = [ex.message] - return errors + return errors, schemaDictionary def ValidateInstanceDocuments (coreFile, supportingSchemas, instanceDocs): @@ -102,6 +103,7 @@ if __name__ == '__main__': logging.debug(f"Path: {args.input}") includeFileList = [] + includeInstanceDocList = [] for path in args.input[0]: p = Path(path) if not p.exists(): @@ -112,9 +114,17 @@ if __name__ == '__main__': for g in glob.glob(os.path.join(str(p), "*.xsd")): logging.info(f">Including {g}") includeFileList.append(g) + for g in glob.glob(os.path.join(str(p), "*.xml")): + logging.info(f">Including instance doc {g}") + includeInstanceDocList.append(g) else: logging.info(f"Including {p.absolute()}") - includeFileList.append(p.absolute()) + if str(p.absolute()).endswith('.xml'): + includeInstanceDocList.append(p.absolute()) + elif str(p.absolute()).endswith('.xml'): + includeFileList.append(p.absolute()) + else: + logging.warning(f'Ignoring file {p.absolute()}') syntaxErrors = 0 @@ -133,7 +143,7 @@ if __name__ == '__main__': print (f"{syntaxErrors} syntax errors detected") exit(syntaxErrors) - results = ValidateXSDFiles(includeFileList) + results, schemaDict = ValidateXSDFiles(includeFileList) print ("XSD build checks:") print ("-----------------------------") @@ -152,4 +162,13 @@ if __name__ == '__main__': print ("-----------------------------") print (f"{errorCount} build errors detected") - exit(errorCount) \ No newline at end of file + if (errorCount > 0): + exit(errorCount) + + print ("Instance document checks") + print ("-----------------------------") + errorCount = 0 + + for instanceDoc in includeInstanceDocList: + print (f" {instanceDoc:}") + diff --git a/testing/deps/xmldsig/xmldsig-core-schema.xsd b/testing/deps/xmldsig/xmldsig-core-schema.xsd new file mode 100644 index 0000000..df126b3 --- /dev/null +++ b/testing/deps/xmldsig/xmldsig-core-schema.xsd @@ -0,0 +1,318 @@ + + + + + + ]> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -- GitLab From e56de57f8dc3ce20427f8f4b922570c85faa7888 Mon Sep 17 00:00:00 2001 From: mark Date: Fri, 22 Oct 2021 12:30:01 +0100 Subject: [PATCH 03/15] Changing version number in examples --- 103120/examples/mutliple-auth-example-request.xml | 2 +- 103120/examples/request1.xml | 2 +- 103120/examples/request2.xml | 2 +- 103120/examples/request3.xml | 2 +- 103120/examples/request4.xml | 2 +- 103120/examples/request5-Binary-Delivery.xml | 2 +- 103120/examples/request5-XML-Delivery.xml | 2 +- 103120/examples/response1.xml | 2 +- 103120/examples/response2.xml | 2 +- 103120/examples/response3.xml | 2 +- 103120/examples/response4.xml | 2 +- 103120/examples/response5.xml | 2 +- 12 files changed, 12 insertions(+), 12 deletions(-) diff --git a/103120/examples/mutliple-auth-example-request.xml b/103120/examples/mutliple-auth-example-request.xml index 5e5f226..8fd893c 100644 --- a/103120/examples/mutliple-auth-example-request.xml +++ b/103120/examples/mutliple-auth-example-request.xml @@ -12,7 +12,7 @@ d442c58c-d5e1-4fd9-90ec-9c228ad947f1 2020-09-22T08:06:17.025833Z - V1.8.1 + V1.10.1 XX v1.1.1 diff --git a/103120/examples/request1.xml b/103120/examples/request1.xml index d0b64ee..a5e40d6 100644 --- a/103120/examples/request1.xml +++ b/103120/examples/request1.xml @@ -12,7 +12,7 @@ c02358b2-76cf-4ba4-a8eb-f6436ccaea2e 2015-09-01T12:00:00.000000Z - V1.8.1 + V1.10.1 XX v1.0 diff --git a/103120/examples/request2.xml b/103120/examples/request2.xml index 67cbefd..2b1d012 100644 --- a/103120/examples/request2.xml +++ b/103120/examples/request2.xml @@ -12,7 +12,7 @@ 45002c1e-dc4a-470a-9152-8e752638c86c 2015-09-01T12:01:00.000000Z - V1.8.1 + V1.10.1 XX v1.0 diff --git a/103120/examples/request3.xml b/103120/examples/request3.xml index c93bb7a..dce6620 100644 --- a/103120/examples/request3.xml +++ b/103120/examples/request3.xml @@ -12,7 +12,7 @@ 69353ac0-9582-4c71-b162-86259c99de20 2015-09-01T12:02:00.000000Z - V1.8.1 + V1.10.1 XX v1.0 diff --git a/103120/examples/request4.xml b/103120/examples/request4.xml index 6296da5..73d6c07 100644 --- a/103120/examples/request4.xml +++ b/103120/examples/request4.xml @@ -12,7 +12,7 @@ c02358b2-76cf-4ba4-a8eb-f6436ccaea2e 2019-09-30T13:37:00.000000Z - V1.8.1 + V1.10.1 XX v1.0 diff --git a/103120/examples/request5-Binary-Delivery.xml b/103120/examples/request5-Binary-Delivery.xml index 7d51707..2a13dfb 100644 --- a/103120/examples/request5-Binary-Delivery.xml +++ b/103120/examples/request5-Binary-Delivery.xml @@ -12,7 +12,7 @@ 8854cfad-44ac-43b8-99ae-530b690b43da 2019-09-30T13:37:37.000000Z - V1.8.1 + V1.10.1 XX v1.0 diff --git a/103120/examples/request5-XML-Delivery.xml b/103120/examples/request5-XML-Delivery.xml index f9314cd..c345dbb 100644 --- a/103120/examples/request5-XML-Delivery.xml +++ b/103120/examples/request5-XML-Delivery.xml @@ -12,7 +12,7 @@ 8854cfad-44ac-43b8-99ae-530b690b43da 2019-09-30T13:37:37.000000Z - V1.8.1 + V1.10.1 XX v1.0 diff --git a/103120/examples/response1.xml b/103120/examples/response1.xml index 25aa22c..54fad1c 100644 --- a/103120/examples/response1.xml +++ b/103120/examples/response1.xml @@ -12,7 +12,7 @@ c02358b2-76cf-4ba4-a8eb-f6436ccaea2e 2015-09-01T12:00:01.000000Z - V1.8.1 + V1.10.1 XX v1.0 diff --git a/103120/examples/response2.xml b/103120/examples/response2.xml index 3f3e550..104a76f 100644 --- a/103120/examples/response2.xml +++ b/103120/examples/response2.xml @@ -12,7 +12,7 @@ 45002c1e-dc4a-470a-9152-8e752638c86c 2015-09-01T12:01:00.000000Z - V1.8.1 + V1.10.1 XX v1.0 diff --git a/103120/examples/response3.xml b/103120/examples/response3.xml index e3b1537..445187d 100644 --- a/103120/examples/response3.xml +++ b/103120/examples/response3.xml @@ -12,7 +12,7 @@ 69353ac0-9582-4c71-b162-86259c99de20 2015-09-01T12:02:00.000000Z - V1.8.1 + V1.10.1 XX v1.0 diff --git a/103120/examples/response4.xml b/103120/examples/response4.xml index a8dc811..3ca45c2 100644 --- a/103120/examples/response4.xml +++ b/103120/examples/response4.xml @@ -12,7 +12,7 @@ c02358b2-76cf-4ba4-a8eb-f6436ccaea2e 2019-09-30T13:37:01.000000Z - V1.8.1 + V1.10.1 XX v1.0 diff --git a/103120/examples/response5.xml b/103120/examples/response5.xml index 32bfcd1..d02dff5 100644 --- a/103120/examples/response5.xml +++ b/103120/examples/response5.xml @@ -17,7 +17,7 @@ 8854cfad-44ac-43b8-99ae-530b690b43da 2019-09-30T13:37:37.000000Z - V1.8.1 + V1.10.1 XX v1.0 -- GitLab From 111f14a0e1bee8f7f7cda485a0a315a7fdacc88d Mon Sep 17 00:00:00 2001 From: mark Date: Fri, 22 Oct 2021 13:20:15 +0100 Subject: [PATCH 04/15] Updating testing --- testing/check_xsd.py | 31 +- testing/deps/xmldsig/xmldsig-core-schema.xsd | 318 +++++++++++++++++++ 2 files changed, 343 insertions(+), 6 deletions(-) create mode 100644 testing/deps/xmldsig/xmldsig-core-schema.xsd diff --git a/testing/check_xsd.py b/testing/check_xsd.py index db4ee8c..dd6f0fd 100644 --- a/testing/check_xsd.py +++ b/testing/check_xsd.py @@ -11,7 +11,6 @@ from lxml import etree from xml.etree.ElementTree import ParseError from xmlschema import XMLSchema, XMLSchemaParseError - def BuildSchemaDictonary (fileList): if len(fileList) == 0: logging.info("No schema files provided") @@ -22,7 +21,7 @@ def BuildSchemaDictonary (fileList): for schemaFile in fileList: try: xs = XMLSchema(schemaFile, validation='skip') - schemaLocations.append((xs.default_namespace, str(Path(schemaFile).resolve()))) + schemaLocations.append((xs.target_namespace, str(Path(schemaFile).resolve()))) logging.info(" [ {0} -> {1} ]".format(xs.default_namespace, schemaFile)) except ParseError as ex: logging.warning (" [ {0} failed to parse: {1} ]".format(schemaFile, ex)) @@ -53,6 +52,7 @@ def ValidateXSDFiles (fileList): schemaLocations = BuildSchemaDictonary(fileList) errors = {} + schemaDictionary = {} logging.info("Schema validation:") for schemaFile in fileList: @@ -60,6 +60,7 @@ def ValidateXSDFiles (fileList): schema = XMLSchema(schemaFile, locations = schemaLocations) logging.info(schemaFile + ": OK") errors[schemaFile] = [] + schemaDictionary[schema.target_namespace] = schema except XMLSchemaParseError as ex: if (ex.schema_url) and (ex.schema_url != ex.origin_url): logging.info(" Error {1} comes from {0}, suppressing".format(ex.schema_url, ex.message)) @@ -67,7 +68,7 @@ def ValidateXSDFiles (fileList): else: logging.warning(schemaFile + ": Failed validation ({0})".format(ex)) errors[schemaFile] = [ex.message] - return errors + return errors, schemaDictionary def ValidateInstanceDocuments (coreFile, supportingSchemas, instanceDocs): @@ -102,6 +103,7 @@ if __name__ == '__main__': logging.debug(f"Path: {args.input}") includeFileList = [] + includeInstanceDocList = [] for path in args.input[0]: p = Path(path) if not p.exists(): @@ -112,9 +114,17 @@ if __name__ == '__main__': for g in glob.glob(os.path.join(str(p), "*.xsd")): logging.info(f">Including {g}") includeFileList.append(g) + for g in glob.glob(os.path.join(str(p), "*.xml")): + logging.info(f">Including instance doc {g}") + includeInstanceDocList.append(g) else: logging.info(f"Including {p.absolute()}") - includeFileList.append(p.absolute()) + if str(p.absolute()).endswith('.xml'): + includeInstanceDocList.append(p.absolute()) + elif str(p.absolute()).endswith('.xml'): + includeFileList.append(p.absolute()) + else: + logging.warning(f'Ignoring file {p.absolute()}') syntaxErrors = 0 @@ -133,7 +143,7 @@ if __name__ == '__main__': print (f"{syntaxErrors} syntax errors detected") exit(syntaxErrors) - results = ValidateXSDFiles(includeFileList) + results, schemaDict = ValidateXSDFiles(includeFileList) print ("XSD build checks:") print ("-----------------------------") @@ -152,4 +162,13 @@ if __name__ == '__main__': print ("-----------------------------") print (f"{errorCount} build errors detected") - exit(errorCount) \ No newline at end of file + if (errorCount > 0): + exit(errorCount) + + print ("Instance document checks") + print ("-----------------------------") + errorCount = 0 + + for instanceDoc in includeInstanceDocList: + print (f" {instanceDoc:}") + diff --git a/testing/deps/xmldsig/xmldsig-core-schema.xsd b/testing/deps/xmldsig/xmldsig-core-schema.xsd new file mode 100644 index 0000000..df126b3 --- /dev/null +++ b/testing/deps/xmldsig/xmldsig-core-schema.xsd @@ -0,0 +1,318 @@ + + + + + + ]> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -- GitLab From 0c89bb7ff6e59ee9bb7277c79ba6d7a01586d792 Mon Sep 17 00:00:00 2001 From: mark Date: Fri, 22 Oct 2021 13:56:52 +0100 Subject: [PATCH 05/15] Updating tests to include validation of instance documents --- 103120/examples/FooServiceSchema.xsd | 27 +++++++++++++++++++++++++++ testing/check_xsd.py | 25 ++++++++++++++++++++----- 2 files changed, 47 insertions(+), 5 deletions(-) create mode 100644 103120/examples/FooServiceSchema.xsd diff --git a/103120/examples/FooServiceSchema.xsd b/103120/examples/FooServiceSchema.xsd new file mode 100644 index 0000000..5657394 --- /dev/null +++ b/103120/examples/FooServiceSchema.xsd @@ -0,0 +1,27 @@ + + + + + + + + + + + + + + + + + + + + + + diff --git a/testing/check_xsd.py b/testing/check_xsd.py index dd6f0fd..30f0a28 100644 --- a/testing/check_xsd.py +++ b/testing/check_xsd.py @@ -92,6 +92,7 @@ if __name__ == '__main__': parser = argparse.ArgumentParser() parser.add_argument("-v", "--verbosity", help="verbosity level", action="count", default=0) parser.add_argument("input", help="include a directory or file", action="append", nargs="+") + parser.add_argument("-p", "--primaryNamespace", help="Primary schema namespace for instance doc validation") args = parser.parse_args() logging.getLogger().setLevel(logging.WARNING) @@ -101,6 +102,7 @@ if __name__ == '__main__': logging.getLogger().setLevel(logging.DEBUG) logging.debug("Very verbose selected") + logging.debug(f"Path: {args.input}") includeFileList = [] includeInstanceDocList = [] @@ -118,14 +120,18 @@ if __name__ == '__main__': logging.info(f">Including instance doc {g}") includeInstanceDocList.append(g) else: - logging.info(f"Including {p.absolute()}") + logging.info(f">Including {p.absolute()}") if str(p.absolute()).endswith('.xml'): - includeInstanceDocList.append(p.absolute()) - elif str(p.absolute()).endswith('.xml'): - includeFileList.append(p.absolute()) + includeInstanceDocList.append(str(p.absolute())) + elif str(p.absolute()).endswith('.xsd'): + includeFileList.append(str(p.absolute())) else: logging.warning(f'Ignoring file {p.absolute()}') + if len(includeInstanceDocList) and (args.primaryNamespace is None): + print("Cannot validate instance documents without specifying a primary namespace (use -h for usage guidelines)") + exit(-1) + syntaxErrors = 0 print ("XSD syntax checks:") @@ -169,6 +175,15 @@ if __name__ == '__main__': print ("-----------------------------") errorCount = 0 + primarySchema = schemaDict[args.primaryNamespace] for instanceDoc in includeInstanceDocList: - print (f" {instanceDoc:}") + try: + results = primarySchema.validate(instanceDoc) + print (f" {instanceDoc} : OK") + except Exception as ex: + errorCount += 1 + print (f" {instanceDoc} : {str(ex)}") + print (f"{errorCount} instance doc errors detected") + exit(errorCount) + -- GitLab From d1ecf9d8efe9175b1047523f6d48c843932d4012 Mon Sep 17 00:00:00 2001 From: mark Date: Fri, 22 Oct 2021 14:10:41 +0100 Subject: [PATCH 06/15] Updating tests --- testing/check_xsd.py | 9 --------- 1 file changed, 9 deletions(-) diff --git a/testing/check_xsd.py b/testing/check_xsd.py index 93a5203..aad0879 100644 --- a/testing/check_xsd.py +++ b/testing/check_xsd.py @@ -120,19 +120,11 @@ if __name__ == '__main__': logging.info(f">Including instance doc {g}") includeInstanceDocList.append(g) else: -<<<<<<< HEAD logging.info(f">Including {p.absolute()}") if str(p.absolute()).endswith('.xml'): includeInstanceDocList.append(str(p.absolute())) elif str(p.absolute()).endswith('.xsd'): includeFileList.append(str(p.absolute())) -======= - logging.info(f"Including {p.absolute()}") - if str(p.absolute()).endswith('.xml'): - includeInstanceDocList.append(p.absolute()) - elif str(p.absolute()).endswith('.xml'): - includeFileList.append(p.absolute()) ->>>>>>> f3f09f7c3888b660d639f273b2164823ac0460cc else: logging.warning(f'Ignoring file {p.absolute()}') @@ -193,4 +185,3 @@ if __name__ == '__main__': print (f" {instanceDoc} : {str(ex)}") print (f"{errorCount} instance doc errors detected") exit(errorCount) - -- GitLab From f233980918f79cd30c20f67a848912b9ebc932e4 Mon Sep 17 00:00:00 2001 From: mark Date: Fri, 22 Oct 2021 14:14:27 +0100 Subject: [PATCH 07/15] Updating tests --- testing/check_xsd.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/testing/check_xsd.py b/testing/check_xsd.py index aad0879..b35695a 100644 --- a/testing/check_xsd.py +++ b/testing/check_xsd.py @@ -134,6 +134,7 @@ if __name__ == '__main__': syntaxErrors = 0 + print ("=============================") print ("XSD syntax checks:") print ("-----------------------------") for file in includeFileList: @@ -148,9 +149,12 @@ if __name__ == '__main__': if (syntaxErrors > 0): print (f"{syntaxErrors} syntax errors detected") exit(syntaxErrors) + else: + print ("0 syntax errors detected") results, schemaDict = ValidateXSDFiles(includeFileList) + print ("=============================") print ("XSD build checks:") print ("-----------------------------") errorCount = 0 @@ -171,6 +175,7 @@ if __name__ == '__main__': if (errorCount > 0): exit(errorCount) + print ("=============================") print ("Instance document checks") print ("-----------------------------") errorCount = 0 @@ -184,4 +189,5 @@ if __name__ == '__main__': errorCount += 1 print (f" {instanceDoc} : {str(ex)}") print (f"{errorCount} instance doc errors detected") + print ("=============================") exit(errorCount) -- GitLab From bed002e116b74962d613c515b377387ff0782163 Mon Sep 17 00:00:00 2001 From: mark Date: Fri, 22 Oct 2021 12:30:01 +0100 Subject: [PATCH 08/15] Changing version number in examples --- 103120/examples/mutliple-auth-example-request.xml | 2 +- 103120/examples/request1.xml | 2 +- 103120/examples/request2.xml | 2 +- 103120/examples/request3.xml | 2 +- 103120/examples/request4.xml | 2 +- 103120/examples/request5-Binary-Delivery.xml | 2 +- 103120/examples/request5-XML-Delivery.xml | 2 +- 103120/examples/response1.xml | 2 +- 103120/examples/response2.xml | 2 +- 103120/examples/response3.xml | 2 +- 103120/examples/response4.xml | 2 +- 103120/examples/response5.xml | 2 +- 12 files changed, 12 insertions(+), 12 deletions(-) diff --git a/103120/examples/mutliple-auth-example-request.xml b/103120/examples/mutliple-auth-example-request.xml index 5e5f226..8fd893c 100644 --- a/103120/examples/mutliple-auth-example-request.xml +++ b/103120/examples/mutliple-auth-example-request.xml @@ -12,7 +12,7 @@ d442c58c-d5e1-4fd9-90ec-9c228ad947f1 2020-09-22T08:06:17.025833Z - V1.8.1 + V1.10.1 XX v1.1.1 diff --git a/103120/examples/request1.xml b/103120/examples/request1.xml index d0b64ee..a5e40d6 100644 --- a/103120/examples/request1.xml +++ b/103120/examples/request1.xml @@ -12,7 +12,7 @@ c02358b2-76cf-4ba4-a8eb-f6436ccaea2e 2015-09-01T12:00:00.000000Z - V1.8.1 + V1.10.1 XX v1.0 diff --git a/103120/examples/request2.xml b/103120/examples/request2.xml index 67cbefd..2b1d012 100644 --- a/103120/examples/request2.xml +++ b/103120/examples/request2.xml @@ -12,7 +12,7 @@ 45002c1e-dc4a-470a-9152-8e752638c86c 2015-09-01T12:01:00.000000Z - V1.8.1 + V1.10.1 XX v1.0 diff --git a/103120/examples/request3.xml b/103120/examples/request3.xml index c93bb7a..dce6620 100644 --- a/103120/examples/request3.xml +++ b/103120/examples/request3.xml @@ -12,7 +12,7 @@ 69353ac0-9582-4c71-b162-86259c99de20 2015-09-01T12:02:00.000000Z - V1.8.1 + V1.10.1 XX v1.0 diff --git a/103120/examples/request4.xml b/103120/examples/request4.xml index 6296da5..73d6c07 100644 --- a/103120/examples/request4.xml +++ b/103120/examples/request4.xml @@ -12,7 +12,7 @@ c02358b2-76cf-4ba4-a8eb-f6436ccaea2e 2019-09-30T13:37:00.000000Z - V1.8.1 + V1.10.1 XX v1.0 diff --git a/103120/examples/request5-Binary-Delivery.xml b/103120/examples/request5-Binary-Delivery.xml index 7d51707..2a13dfb 100644 --- a/103120/examples/request5-Binary-Delivery.xml +++ b/103120/examples/request5-Binary-Delivery.xml @@ -12,7 +12,7 @@ 8854cfad-44ac-43b8-99ae-530b690b43da 2019-09-30T13:37:37.000000Z - V1.8.1 + V1.10.1 XX v1.0 diff --git a/103120/examples/request5-XML-Delivery.xml b/103120/examples/request5-XML-Delivery.xml index f9314cd..c345dbb 100644 --- a/103120/examples/request5-XML-Delivery.xml +++ b/103120/examples/request5-XML-Delivery.xml @@ -12,7 +12,7 @@ 8854cfad-44ac-43b8-99ae-530b690b43da 2019-09-30T13:37:37.000000Z - V1.8.1 + V1.10.1 XX v1.0 diff --git a/103120/examples/response1.xml b/103120/examples/response1.xml index 25aa22c..54fad1c 100644 --- a/103120/examples/response1.xml +++ b/103120/examples/response1.xml @@ -12,7 +12,7 @@ c02358b2-76cf-4ba4-a8eb-f6436ccaea2e 2015-09-01T12:00:01.000000Z - V1.8.1 + V1.10.1 XX v1.0 diff --git a/103120/examples/response2.xml b/103120/examples/response2.xml index 3f3e550..104a76f 100644 --- a/103120/examples/response2.xml +++ b/103120/examples/response2.xml @@ -12,7 +12,7 @@ 45002c1e-dc4a-470a-9152-8e752638c86c 2015-09-01T12:01:00.000000Z - V1.8.1 + V1.10.1 XX v1.0 diff --git a/103120/examples/response3.xml b/103120/examples/response3.xml index e3b1537..445187d 100644 --- a/103120/examples/response3.xml +++ b/103120/examples/response3.xml @@ -12,7 +12,7 @@ 69353ac0-9582-4c71-b162-86259c99de20 2015-09-01T12:02:00.000000Z - V1.8.1 + V1.10.1 XX v1.0 diff --git a/103120/examples/response4.xml b/103120/examples/response4.xml index a8dc811..3ca45c2 100644 --- a/103120/examples/response4.xml +++ b/103120/examples/response4.xml @@ -12,7 +12,7 @@ c02358b2-76cf-4ba4-a8eb-f6436ccaea2e 2019-09-30T13:37:01.000000Z - V1.8.1 + V1.10.1 XX v1.0 diff --git a/103120/examples/response5.xml b/103120/examples/response5.xml index 32bfcd1..d02dff5 100644 --- a/103120/examples/response5.xml +++ b/103120/examples/response5.xml @@ -17,7 +17,7 @@ 8854cfad-44ac-43b8-99ae-530b690b43da 2019-09-30T13:37:37.000000Z - V1.8.1 + V1.10.1 XX v1.0 -- GitLab From 9ea2ce54cd592be67d2bc9030dfb5539328150cb Mon Sep 17 00:00:00 2001 From: mark Date: Fri, 22 Oct 2021 13:20:15 +0100 Subject: [PATCH 09/15] Updating testing --- testing/check_xsd.py | 31 +- testing/deps/xmldsig/xmldsig-core-schema.xsd | 318 +++++++++++++++++++ 2 files changed, 343 insertions(+), 6 deletions(-) create mode 100644 testing/deps/xmldsig/xmldsig-core-schema.xsd diff --git a/testing/check_xsd.py b/testing/check_xsd.py index db4ee8c..dd6f0fd 100644 --- a/testing/check_xsd.py +++ b/testing/check_xsd.py @@ -11,7 +11,6 @@ from lxml import etree from xml.etree.ElementTree import ParseError from xmlschema import XMLSchema, XMLSchemaParseError - def BuildSchemaDictonary (fileList): if len(fileList) == 0: logging.info("No schema files provided") @@ -22,7 +21,7 @@ def BuildSchemaDictonary (fileList): for schemaFile in fileList: try: xs = XMLSchema(schemaFile, validation='skip') - schemaLocations.append((xs.default_namespace, str(Path(schemaFile).resolve()))) + schemaLocations.append((xs.target_namespace, str(Path(schemaFile).resolve()))) logging.info(" [ {0} -> {1} ]".format(xs.default_namespace, schemaFile)) except ParseError as ex: logging.warning (" [ {0} failed to parse: {1} ]".format(schemaFile, ex)) @@ -53,6 +52,7 @@ def ValidateXSDFiles (fileList): schemaLocations = BuildSchemaDictonary(fileList) errors = {} + schemaDictionary = {} logging.info("Schema validation:") for schemaFile in fileList: @@ -60,6 +60,7 @@ def ValidateXSDFiles (fileList): schema = XMLSchema(schemaFile, locations = schemaLocations) logging.info(schemaFile + ": OK") errors[schemaFile] = [] + schemaDictionary[schema.target_namespace] = schema except XMLSchemaParseError as ex: if (ex.schema_url) and (ex.schema_url != ex.origin_url): logging.info(" Error {1} comes from {0}, suppressing".format(ex.schema_url, ex.message)) @@ -67,7 +68,7 @@ def ValidateXSDFiles (fileList): else: logging.warning(schemaFile + ": Failed validation ({0})".format(ex)) errors[schemaFile] = [ex.message] - return errors + return errors, schemaDictionary def ValidateInstanceDocuments (coreFile, supportingSchemas, instanceDocs): @@ -102,6 +103,7 @@ if __name__ == '__main__': logging.debug(f"Path: {args.input}") includeFileList = [] + includeInstanceDocList = [] for path in args.input[0]: p = Path(path) if not p.exists(): @@ -112,9 +114,17 @@ if __name__ == '__main__': for g in glob.glob(os.path.join(str(p), "*.xsd")): logging.info(f">Including {g}") includeFileList.append(g) + for g in glob.glob(os.path.join(str(p), "*.xml")): + logging.info(f">Including instance doc {g}") + includeInstanceDocList.append(g) else: logging.info(f"Including {p.absolute()}") - includeFileList.append(p.absolute()) + if str(p.absolute()).endswith('.xml'): + includeInstanceDocList.append(p.absolute()) + elif str(p.absolute()).endswith('.xml'): + includeFileList.append(p.absolute()) + else: + logging.warning(f'Ignoring file {p.absolute()}') syntaxErrors = 0 @@ -133,7 +143,7 @@ if __name__ == '__main__': print (f"{syntaxErrors} syntax errors detected") exit(syntaxErrors) - results = ValidateXSDFiles(includeFileList) + results, schemaDict = ValidateXSDFiles(includeFileList) print ("XSD build checks:") print ("-----------------------------") @@ -152,4 +162,13 @@ if __name__ == '__main__': print ("-----------------------------") print (f"{errorCount} build errors detected") - exit(errorCount) \ No newline at end of file + if (errorCount > 0): + exit(errorCount) + + print ("Instance document checks") + print ("-----------------------------") + errorCount = 0 + + for instanceDoc in includeInstanceDocList: + print (f" {instanceDoc:}") + diff --git a/testing/deps/xmldsig/xmldsig-core-schema.xsd b/testing/deps/xmldsig/xmldsig-core-schema.xsd new file mode 100644 index 0000000..df126b3 --- /dev/null +++ b/testing/deps/xmldsig/xmldsig-core-schema.xsd @@ -0,0 +1,318 @@ + + + + + + ]> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + -- GitLab From c46cabd6248f55c4d84cb5f36e0600d829e88490 Mon Sep 17 00:00:00 2001 From: mark Date: Fri, 22 Oct 2021 13:56:52 +0100 Subject: [PATCH 10/15] Updating tests to include validation of instance documents --- 103120/examples/FooServiceSchema.xsd | 27 +++++++++++++++++++++++++++ testing/check_xsd.py | 25 ++++++++++++++++++++----- 2 files changed, 47 insertions(+), 5 deletions(-) create mode 100644 103120/examples/FooServiceSchema.xsd diff --git a/103120/examples/FooServiceSchema.xsd b/103120/examples/FooServiceSchema.xsd new file mode 100644 index 0000000..5657394 --- /dev/null +++ b/103120/examples/FooServiceSchema.xsd @@ -0,0 +1,27 @@ + + + + + + + + + + + + + + + + + + + + + + diff --git a/testing/check_xsd.py b/testing/check_xsd.py index dd6f0fd..30f0a28 100644 --- a/testing/check_xsd.py +++ b/testing/check_xsd.py @@ -92,6 +92,7 @@ if __name__ == '__main__': parser = argparse.ArgumentParser() parser.add_argument("-v", "--verbosity", help="verbosity level", action="count", default=0) parser.add_argument("input", help="include a directory or file", action="append", nargs="+") + parser.add_argument("-p", "--primaryNamespace", help="Primary schema namespace for instance doc validation") args = parser.parse_args() logging.getLogger().setLevel(logging.WARNING) @@ -101,6 +102,7 @@ if __name__ == '__main__': logging.getLogger().setLevel(logging.DEBUG) logging.debug("Very verbose selected") + logging.debug(f"Path: {args.input}") includeFileList = [] includeInstanceDocList = [] @@ -118,14 +120,18 @@ if __name__ == '__main__': logging.info(f">Including instance doc {g}") includeInstanceDocList.append(g) else: - logging.info(f"Including {p.absolute()}") + logging.info(f">Including {p.absolute()}") if str(p.absolute()).endswith('.xml'): - includeInstanceDocList.append(p.absolute()) - elif str(p.absolute()).endswith('.xml'): - includeFileList.append(p.absolute()) + includeInstanceDocList.append(str(p.absolute())) + elif str(p.absolute()).endswith('.xsd'): + includeFileList.append(str(p.absolute())) else: logging.warning(f'Ignoring file {p.absolute()}') + if len(includeInstanceDocList) and (args.primaryNamespace is None): + print("Cannot validate instance documents without specifying a primary namespace (use -h for usage guidelines)") + exit(-1) + syntaxErrors = 0 print ("XSD syntax checks:") @@ -169,6 +175,15 @@ if __name__ == '__main__': print ("-----------------------------") errorCount = 0 + primarySchema = schemaDict[args.primaryNamespace] for instanceDoc in includeInstanceDocList: - print (f" {instanceDoc:}") + try: + results = primarySchema.validate(instanceDoc) + print (f" {instanceDoc} : OK") + except Exception as ex: + errorCount += 1 + print (f" {instanceDoc} : {str(ex)}") + print (f"{errorCount} instance doc errors detected") + exit(errorCount) + -- GitLab From 6a33275bb44c1055321f35f1f32d4595acd40cd8 Mon Sep 17 00:00:00 2001 From: mark Date: Fri, 22 Oct 2021 14:44:04 +0100 Subject: [PATCH 11/15] Resolving merge conflict --- testing/check_xsd.py | 1 - 1 file changed, 1 deletion(-) diff --git a/testing/check_xsd.py b/testing/check_xsd.py index 30f0a28..5b6c3c5 100644 --- a/testing/check_xsd.py +++ b/testing/check_xsd.py @@ -186,4 +186,3 @@ if __name__ == '__main__': print (f"{errorCount} instance doc errors detected") exit(errorCount) - -- GitLab From 01a3d69a311dfec8a49fdffd7d7ebbcd455fc1e9 Mon Sep 17 00:00:00 2001 From: mark Date: Fri, 22 Oct 2021 14:10:41 +0100 Subject: [PATCH 12/15] Updating tests --- testing/check_xsd.py | 1 - 1 file changed, 1 deletion(-) diff --git a/testing/check_xsd.py b/testing/check_xsd.py index 5b6c3c5..aad0879 100644 --- a/testing/check_xsd.py +++ b/testing/check_xsd.py @@ -185,4 +185,3 @@ if __name__ == '__main__': print (f" {instanceDoc} : {str(ex)}") print (f"{errorCount} instance doc errors detected") exit(errorCount) - -- GitLab From 9dd8cf44675c46e3e4591759710fe8e33e990657 Mon Sep 17 00:00:00 2001 From: mark Date: Fri, 22 Oct 2021 14:14:27 +0100 Subject: [PATCH 13/15] Updating tests --- testing/check_xsd.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/testing/check_xsd.py b/testing/check_xsd.py index aad0879..b35695a 100644 --- a/testing/check_xsd.py +++ b/testing/check_xsd.py @@ -134,6 +134,7 @@ if __name__ == '__main__': syntaxErrors = 0 + print ("=============================") print ("XSD syntax checks:") print ("-----------------------------") for file in includeFileList: @@ -148,9 +149,12 @@ if __name__ == '__main__': if (syntaxErrors > 0): print (f"{syntaxErrors} syntax errors detected") exit(syntaxErrors) + else: + print ("0 syntax errors detected") results, schemaDict = ValidateXSDFiles(includeFileList) + print ("=============================") print ("XSD build checks:") print ("-----------------------------") errorCount = 0 @@ -171,6 +175,7 @@ if __name__ == '__main__': if (errorCount > 0): exit(errorCount) + print ("=============================") print ("Instance document checks") print ("-----------------------------") errorCount = 0 @@ -184,4 +189,5 @@ if __name__ == '__main__': errorCount += 1 print (f" {instanceDoc} : {str(ex)}") print (f"{errorCount} instance doc errors detected") + print ("=============================") exit(errorCount) -- GitLab From 8d40874141f37aa5939d9367e170a9c6f323e9ca Mon Sep 17 00:00:00 2001 From: mark Date: Fri, 22 Oct 2021 14:46:34 +0100 Subject: [PATCH 14/15] Updating testing --- testing/check_xsd.py | 1 + 1 file changed, 1 insertion(+) diff --git a/testing/check_xsd.py b/testing/check_xsd.py index b35695a..816e389 100644 --- a/testing/check_xsd.py +++ b/testing/check_xsd.py @@ -188,6 +188,7 @@ if __name__ == '__main__': except Exception as ex: errorCount += 1 print (f" {instanceDoc} : {str(ex)}") + print ("-----------------------------") print (f"{errorCount} instance doc errors detected") print ("=============================") exit(errorCount) -- GitLab From ca5167cb69fa20574ec13a78acea30ac9bc82c40 Mon Sep 17 00:00:00 2001 From: mark Date: Fri, 22 Oct 2021 15:11:48 +0100 Subject: [PATCH 15/15] Adding missing examples from portal --- 103120/examples/example.key | 28 +++++++ 103120/examples/example.pem | 19 +++++ 103120/examples/request6_signed.xml | 118 ++++++++++++++++++++++++++++ 3 files changed, 165 insertions(+) create mode 100644 103120/examples/example.key create mode 100644 103120/examples/example.pem create mode 100644 103120/examples/request6_signed.xml diff --git a/103120/examples/example.key b/103120/examples/example.key new file mode 100644 index 0000000..b5959e7 --- /dev/null +++ b/103120/examples/example.key @@ -0,0 +1,28 @@ +-----BEGIN PRIVATE KEY----- +MIIEvgIBADANBgkqhkiG9w0BAQEFAASCBKgwggSkAgEAAoIBAQDc9UQSsRmchhOC +ixyrHvmjmDFeIApVlfTfVV5RJL/280wDlAYymhAcEcvMOyvBCHq4c3M8hBxt9zKD +mV+NbcDqXyblt8rVpjzbggn3Ch2dMJ/kLNO+O+WJSl3Jpyx3b4r8IVoUDXai2sjX +8jLNYI4TC673X3xX1VikzcGwFjt2zbL+WLHEnvUVeG/8FJfRl2ttWlSFMA2252ak +OwtAPF4AKJBW5pXSeILA+K32bf+Y5JMODWwI+njylAafTFV1eM/dTOSEKYCHVCN0 +cxiO6KCC2GSzLeQEGWmh/C+uyhSlLW/6EyEHJcLdi6eTPunYJGanai6PLLr5zNWX +lvcj/YbZAgMBAAECggEAbm1BPRo3U4uKWpaNmFPdrU3VdlYK9CUCgU8X2PPF4HRN +TAiBZG6smGqocIQt5MYJFv/T2q2ny6lcHHrdT0BHxpoRRYMqIsZ26bk+o7DxheqU +LiPdGtiyaX+6CZq71WDwk/tTGmx0GwW+lHXdv9h+iLQxGD4nVXoxWAPgxdEGnONY +gSYbOhXz+MEFZaW8HnVPfoA+RR9Hg59gnmBCZlhbahqf3WnjAwgS0nsbSUN57wVi +FcWHWLyzv94bQHcTgalXqVakQv5+ymJKF4ImiYUP2rLPQ8ubqwmdQ6xI8Gp3AGCr +FY5koP3JT2mMY+aZJEEGWE3U4JRDyrkOpI34No8iEQKBgQD6niFOopCjE2k7eIFr +c+s5Khp3ITmcgV4tycxngXOQw8GnPEzzZUW7xodTiMPLYz/8lFbJvCAWCeQpmVWX +U8OX9anzY0U0ILbolXpdpGdZkBHbKWtAVBNOZ/lY0SAmt6/ZWf/EcqpMm/fH+iph +aqafwQuX4qhy9HlwY2qwyj5y5QKBgQDhtBH9/9Hy0X2HI+uzNRaU0y1BqvuqjHOf +1v57DM5uYF0MAp1SAfAJcx+jUXdf28Nr4GlxBIvQumq6rsvfKhqBINsKgJf/4+PA +Lv+fofeUEEqrGHuecB4NbdHP5XIIiuyyuOtRhGq/sclOQSZAa1kxajGvDI1AVHL4 +LCwcy9HA5QKBgQDIq+2HhWvC6DwOvoMCgyMJ9siSMyxqQLwkdb0R8/mRJO3e9s22 +5pRbsq+RF6WPKb2GhVCo39XhT7I+DOUX8p5fAvo+RHKZNsi+m1ILwSRv9ogVsKiM +LcX3thFWKL1RwysvIn1F03rBNPHGUm206yzYJj8eMwMmaNMERtabEJXIcQKBgHct +Kvbwlr5daafrCrDkzlilLVdoXlzOrtrung8BUxsrHNaTptg/l6yVslX9VUgzdXvH +0kVP/jenx2VtmM7sn3Qhkid4gUon3gGDj4yN7HmtJJA1bEjbsLKsk0XwRIdIO/We ++PphLjCsQrxkYDtRs5YJGdTxjsAyF0b9pAlMgiQVAoGBAK/NGV5+IPDHEmz0CNJN +ApaA2jG8KrsIPWNpgOC3CxPMT3kWYK601y0CLw8ZpUnVTMfPkKMSOVsqaOpHV6eP +Oecq3bP1CiNunro+j3EOIDIST2ttrlNuKIBaiz63ZMNDbs/DyaGL8Zf688OJCXsb +yCWSJh8NbrNblNfI0jaMoTGw +-----END PRIVATE KEY----- diff --git a/103120/examples/example.pem b/103120/examples/example.pem new file mode 100644 index 0000000..2aa1eac --- /dev/null +++ b/103120/examples/example.pem @@ -0,0 +1,19 @@ +-----BEGIN CERTIFICATE----- +MIIC/zCCAeegAwIBAgIUUOGdj0hEfnnW9gqIOCTJ9EUocnMwDQYJKoZIhvcNAQEL +BQAwDzENMAsGA1UEAwwEdGVzdDAeFw0yMTA2MjUwNzIyMDlaFw0yNDAzMjEwNzIy +MDlaMA8xDTALBgNVBAMMBHRlc3QwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEK +AoIBAQDc9UQSsRmchhOCixyrHvmjmDFeIApVlfTfVV5RJL/280wDlAYymhAcEcvM +OyvBCHq4c3M8hBxt9zKDmV+NbcDqXyblt8rVpjzbggn3Ch2dMJ/kLNO+O+WJSl3J +pyx3b4r8IVoUDXai2sjX8jLNYI4TC673X3xX1VikzcGwFjt2zbL+WLHEnvUVeG/8 +FJfRl2ttWlSFMA2252akOwtAPF4AKJBW5pXSeILA+K32bf+Y5JMODWwI+njylAaf +TFV1eM/dTOSEKYCHVCN0cxiO6KCC2GSzLeQEGWmh/C+uyhSlLW/6EyEHJcLdi6eT +PunYJGanai6PLLr5zNWXlvcj/YbZAgMBAAGjUzBRMB0GA1UdDgQWBBSFT3NqexF1 +LcYkjqUr9MMTIFp/ATAfBgNVHSMEGDAWgBSFT3NqexF1LcYkjqUr9MMTIFp/ATAP +BgNVHRMBAf8EBTADAQH/MA0GCSqGSIb3DQEBCwUAA4IBAQCzwydpNgq680qWmd0D +4ya9fHUopeX7LBSYOU7NU3CagjXnUMwaCmSpokkH0Wvn1UtXDUF+slA9bEeXkfZm +70YW8msIEt1mljDi4CBI+MvaJ40OJkXwkQUE3dhj9LJl5Nv0UBEyv7k/a/6+eO9K +OQoHIVqXwrWs9JHTW6T4diN1w7xcgvSXhlcOySHjfNzFzferqx8i0/Wz6jD/7YSC +FOEaUrXbeFS3asRoZRLW6uXgfDJ7qfCmUZZ853OF3MN63OwWjPGxtFmeZAqMS/K0 +FKgwMCrmZlVq6Fx87E+sc3eppXIceCau/+CHG91mRvMSha6jQD7jLMT9xjND5Dob +/scV +-----END CERTIFICATE----- diff --git a/103120/examples/request6_signed.xml b/103120/examples/request6_signed.xml new file mode 100644 index 0000000..2bc0404 --- /dev/null +++ b/103120/examples/request6_signed.xml @@ -0,0 +1,118 @@ + +
+ + XX + ACTOR01 + + + XX + ACTOR02 + + 9964584e-c1a5-4ffa-b949-d9da504c4efb + 2021-06-25T12:00:00.000000Z + + V1.9.1 + XX + v1.0 + +
+ + + + + 0 + + + 68c78910-c922-45f2-aeb3-017eb958bb05 + XX + ACTOR01 + W000001 + + 2021-06-25T12:00:00Z + 2021-09-01T12:00:00Z + + + + + + 1 + + + 4d8127db-e8bc-4a69-9378-457f0424ec2c + XX + ACTOR01 + + 68c78910-c922-45f2-aeb3-017eb958bb05 + + LIID1 + + + + + ETSI + InternationalizedEmailAddress + + Όνομα.παραδείγματος@example.com + + + + + ETSI + TaskDeliveryType + IRIandCC + + + + + 192.0.2.0 + + + + + XX + RECVER01 + + + + + + + + + + + + + + + + + + kARbaz+wH6oJWSvmy6Fk4vTQ7t4m3Y16IiNNdDO08/I= + + + DdT9ie03Z9O47sN8ad9gsfuhZhchtNhtvTyNhtiHKuqgNCt696tDH2c68tVqr+iJ3WpCn0gWJHKnYeniTwVPj6fxDh2RbCqk5SVHvdggZjCv3BInNH0ZfOrlvuArJS3UP/gifYXlT5s59Seze1nSjZDNeC25o9WRxNy0krGrhbqIFjxTHDilR40cmKq2SI1540yM3rsc+5D3hgsxGu7ly2dg7qtiFGQIQaFJi8twrViQUnOyDZ63yJHhWeLVU+2FvIuBZh3orDc3VipKsbqrjrDqdfi8qfYEHHPp25DfTpHXnCuhD/3hOwcxvhVJ4+47R8ysO9qMTvGRCUNptgskhQ== + + + MIIC/zCCAeegAwIBAgIUUOGdj0hEfnnW9gqIOCTJ9EUocnMwDQYJKoZIhvcNAQEL +BQAwDzENMAsGA1UEAwwEdGVzdDAeFw0yMTA2MjUwNzIyMDlaFw0yNDAzMjEwNzIy +MDlaMA8xDTALBgNVBAMMBHRlc3QwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEK +AoIBAQDc9UQSsRmchhOCixyrHvmjmDFeIApVlfTfVV5RJL/280wDlAYymhAcEcvM +OyvBCHq4c3M8hBxt9zKDmV+NbcDqXyblt8rVpjzbggn3Ch2dMJ/kLNO+O+WJSl3J +pyx3b4r8IVoUDXai2sjX8jLNYI4TC673X3xX1VikzcGwFjt2zbL+WLHEnvUVeG/8 +FJfRl2ttWlSFMA2252akOwtAPF4AKJBW5pXSeILA+K32bf+Y5JMODWwI+njylAaf +TFV1eM/dTOSEKYCHVCN0cxiO6KCC2GSzLeQEGWmh/C+uyhSlLW/6EyEHJcLdi6eT +PunYJGanai6PLLr5zNWXlvcj/YbZAgMBAAGjUzBRMB0GA1UdDgQWBBSFT3NqexF1 +LcYkjqUr9MMTIFp/ATAfBgNVHSMEGDAWgBSFT3NqexF1LcYkjqUr9MMTIFp/ATAP +BgNVHRMBAf8EBTADAQH/MA0GCSqGSIb3DQEBCwUAA4IBAQCzwydpNgq680qWmd0D +4ya9fHUopeX7LBSYOU7NU3CagjXnUMwaCmSpokkH0Wvn1UtXDUF+slA9bEeXkfZm +70YW8msIEt1mljDi4CBI+MvaJ40OJkXwkQUE3dhj9LJl5Nv0UBEyv7k/a/6+eO9K +OQoHIVqXwrWs9JHTW6T4diN1w7xcgvSXhlcOySHjfNzFzferqx8i0/Wz6jD/7YSC +FOEaUrXbeFS3asRoZRLW6uXgfDJ7qfCmUZZ853OF3MN63OwWjPGxtFmeZAqMS/K0 +FKgwMCrmZlVq6Fx87E+sc3eppXIceCau/+CHG91mRvMSha6jQD7jLMT9xjND5Dob +/scV + + + + +
\ No newline at end of file -- GitLab