]> www.wagner.pp.ru Git - oss/ctypescrypto.git/blob - ctypescrypto/__init__.py
Converted tabs to spaces to make pylint happy
[oss/ctypescrypto.git] / ctypescrypto / __init__.py
1 """
2     Interface to some libcrypto functions
3
4 """
5
6
7 from ctypes import CDLL,c_char_p
8
9 def config(filename=None):
10     """
11         Loads OpenSSL Config file. If none are specified, loads default
12         (compiled in) one
13     """
14     libcrypto.OPENSSL_config(filename)
15
16 __all__ = ['config']
17
18 libcrypto = CDLL("libcrypto.so.1.0.0")
19 libcrypto.OPENSSL_config.argtypes=(c_char_p,)
20 libcrypto.OPENSSL_add_all_algorithms_conf()