]> git.pld-linux.org Git - packages/python-M2Crypto.git/blob - M2Crypto-smime_callback.patch
- mass commit: remove obsolete BR: rpm-pythonprov
[packages/python-M2Crypto.git] / M2Crypto-smime_callback.patch
1 --- m2crypto-0.11/M2Crypto/SMIME.py.wiget       2002-12-23 04:48:35.000000000 +0100
2 +++ m2crypto-0.11/M2Crypto/SMIME.py     2003-09-16 13:36:00.000000000 +0200
3 @@ -4,7 +4,7 @@
4  
5  RCS_id='$Id$'
6  
7 -import BIO, EVP, X509, Err
8 +import BIO, EVP, X509, Err, util
9  import m2
10  
11  PKCS7_TEXT     = m2.PKCS7_TEXT
12 @@ -117,16 +117,16 @@
13  m2.smime_init(SMIME_Error)
14  
15  class SMIME:
16 -    def load_key(self, keyfile, certfile=None):
17 +    def load_key(self, keyfile, certfile=None, callback=util.passphrase_callback):
18          if certfile is None:
19              certfile = keyfile
20 -        self.pkey = EVP.load_key(keyfile)
21 +        self.pkey = EVP.load_key(keyfile, callback)
22          self.x509 = X509.load_cert(certfile)
23  
24 -    def load_key_bio(self, keybio, certbio=None):
25 +    def load_key_bio(self, keybio, certbio=None, callback=util.passphrase_callback):
26          if certbio is None:
27              certbio = keybio
28 -        self.pkey = EVP.load_key_bio(keybio)
29 +        self.pkey = EVP.load_key_bio(keybio, callback)
30          self.x509 = X509.load_cert_bio(certbio)
31  
32      def set_x509_stack(self, stack):
This page took 0.026247 seconds and 3 git commands to generate.