diff options
author | Rob Crittenden <rcritten@redhat.com> | 2011-04-26 16:45:19 -0400 |
---|---|---|
committer | Rob Crittenden <rcritten@redhat.com> | 2011-06-16 19:27:17 -0400 |
commit | a2a3782efb386f18689faf35a069c4da1085e87d (patch) | |
tree | b8c4b2bf7c13307eccf3be5f962a680ae97e122b /tests/test_xmlrpc/xmlrpc_test.py | |
parent | ed7a3e005a052845b7302744c0f6c16f7cdfd511 (diff) | |
download | freeipa-a2a3782efb386f18689faf35a069c4da1085e87d.tar.gz freeipa-a2a3782efb386f18689faf35a069c4da1085e87d.tar.xz freeipa-a2a3782efb386f18689faf35a069c4da1085e87d.zip |
Require an imported certificate's issuer to match our issuer.
The goal is to not import foreign certificates.
This caused a bunch of tests to fail because we had a hardcoded server
certificate. Instead a developer will need to run make-testcert to
create a server certificate generated by the local CA to test against.
ticket 1134
Diffstat (limited to 'tests/test_xmlrpc/xmlrpc_test.py')
-rw-r--r-- | tests/test_xmlrpc/xmlrpc_test.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/test_xmlrpc/xmlrpc_test.py b/tests/test_xmlrpc/xmlrpc_test.py index 7543fdeee..7b6a74177 100644 --- a/tests/test_xmlrpc/xmlrpc_test.py +++ b/tests/test_xmlrpc/xmlrpc_test.py @@ -44,6 +44,12 @@ fuzzy_netgroupdn = Fuzzy( 'ipauniqueid=[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12},cn=ng,cn=alt,%s' % api.env.basedn ) +# Matches a hash signature, not enforcing length +fuzzy_hash = Fuzzy('^([a-f0-9][a-f0-9]:)+[a-f0-9][a-f0-9]$', type=basestring) + +# Matches a date, like Tue Apr 26 17:45:35 2016 UTC +fuzzy_date = Fuzzy('^[a-zA-Z]{3} [a-zA-Z]{3} \d{2} \d{2}:\d{2}:\d{2} \d{4} UTC$') + try: if not api.Backend.xmlclient.isconnected(): api.Backend.xmlclient.connect(fallback=False) |