+class HttpSslParams(object):
+ """Data class for SSL key and certificate.
+
+ """
+ def __init__(self, ssl_key_path, ssl_cert_path):
+ """Initializes this class.
+
+ @type ssl_key_path: string
+ @param ssl_key_path: Path to file containing SSL key in PEM format
+ @type ssl_cert_path: string
+ @param ssl_cert_path: Path to file containing SSL certificate in PEM format
+
+ """
+ ssl_key_pem = utils.ReadFile(ssl_key_path)
+ ssl_cert_pem = utils.ReadFile(ssl_cert_path)
+
+ cr = OpenSSL.crypto
+ self.cert = cr.load_certificate(cr.FILETYPE_PEM, ssl_cert_pem)
+ self.key = cr.load_privatekey(cr.FILETYPE_PEM, ssl_key_pem)
+ del cr
+
+