Validate the metadata before printing it
This commit is contained in:
@@ -4,6 +4,7 @@ import getopt
|
||||
|
||||
from saml2.metadata import entity_descriptor, entities_descriptor
|
||||
from saml2.sigver import SecurityContext
|
||||
from saml2.validate import valid_instance
|
||||
|
||||
HELP_MESSAGE = """
|
||||
Usage: make_metadata [options] 1*configurationfile
|
||||
@@ -72,7 +73,9 @@ def main(args):
|
||||
eds.append(entity_descriptor(confd, valid_for))
|
||||
|
||||
secc = SecurityContext(xmlsec, keyfile)
|
||||
print entities_descriptor(eds, valid_for, name, id, sign, secc)
|
||||
desc = entities_descriptor(eds, valid_for, name, id, sign, secc)
|
||||
valid_instance(desc)
|
||||
print desc
|
||||
|
||||
if __name__ == "__main__":
|
||||
import sys
|
||||
|
||||
Reference in New Issue
Block a user