Package pulp :: Package server :: Package webservices :: Package httpd :: Module repo_cert_validation
[hide private]
[frames] | no frames]

Module repo_cert_validation

source code

Logic for determining if an entitlement certificate has permission to access a particular URL.

This logic exists in a separate module from the httpd authentication handler to prevent issues with mod_python imports not being available at unit test time.

Functions [hide private]
 
is_valid(dest, cert_pem)
Returns if the specified certificate should be able to access a certain URL.
source code
boolean
is_download_url_ext(ext_oid)
Tests to see if the given OID corresponds to a download URL value.
source code
 
_validate(oid_url, dest) source code
Variables [hide private]
  log = logging.getLogger(__name__)
Function Details [hide private]

is_valid(dest, cert_pem)

source code 

Returns if the specified certificate should be able to access a certain URL.

Parameters:
  • dest (string) - destination URL trying to be accessed
  • cert_pem (string) - PEM encoded client certificate sent with the request

is_download_url_ext(ext_oid)

source code 

Tests to see if the given OID corresponds to a download URL value.

Parameters:
  • ext_oid (a pulp.certificiate.OID object) - OID being tested; cannot be None
Returns: boolean
True if the OID contains download URL information; False otherwise