Date: Friday, November 9, 2018 @ 21:55:50 Author: foutrelis Revision: 404790
archrelease: copy trunk to community-staging-any Added: python2-gnutls/repos/community-staging-any/ python2-gnutls/repos/community-staging-any/PKGBUILD (from rev 404789, python2-gnutls/trunk/PKGBUILD) python2-gnutls/repos/community-staging-any/libraryfunctions.patch (from rev 404789, python2-gnutls/trunk/libraryfunctions.patch) python2-gnutls/repos/community-staging-any/libraryinit.patch (from rev 404789, python2-gnutls/trunk/libraryinit.patch) ------------------------+ PKGBUILD | 29 +++ libraryfunctions.patch | 363 +++++++++++++++++++++++++++++++++++++++++++++++ libraryinit.patch | 12 + 3 files changed, 404 insertions(+) Copied: python2-gnutls/repos/community-staging-any/PKGBUILD (from rev 404789, python2-gnutls/trunk/PKGBUILD) =================================================================== --- community-staging-any/PKGBUILD (rev 0) +++ community-staging-any/PKGBUILD 2018-11-09 21:55:50 UTC (rev 404790) @@ -0,0 +1,29 @@ +# Maintainer: Sergej Pupykin <pupykin.s+a...@gmail.com> +# Maintainer: Hugo Doria <h...@archlinux.org> +# Contributor: N3RD3X <n3r...@linuxmail.org> + +pkgname=python2-gnutls +pkgver=3.0.0 +pkgrel=2 +pkgdesc="Python wrapper for the GNUTLS library" +arch=('any') +url="http://cheeseshop.python.org/pypi/python-gnutls" +depends=('python2' 'gnutls' 'libgcrypt') +license=('LGPL') +source=(https://pypi.python.org/packages/source/p/python-gnutls/python-gnutls-${pkgver}.tar.gz + libraryinit.patch + libraryfunctions.patch) +sha256sums=('6c1274c9f5c0c8c18d050134d6aa2bff3dbf59349fe5485f447fff5c24eb2dfb' + 'd288e90fae55652aada402a4e3c60b797df01a0da6ecc500a3a26b903c821d2b' + '8443ae32fdbfc4c1880bf5e1a1d9cc71077d6ee5c5d52f01a9c9c4c291ae64d9') + +prepare() { + cd "$srcdir"/python-gnutls-${pkgver} +# patch -p1 <"$srcdir"/libraryinit.patch +# patch -p1 <"$srcdir"/libraryfunctions.patch +} + +package() { + cd "$srcdir"/python-gnutls-${pkgver} + python2 setup.py install --root="$pkgdir" +} Copied: python2-gnutls/repos/community-staging-any/libraryfunctions.patch (from rev 404789, python2-gnutls/trunk/libraryfunctions.patch) =================================================================== --- community-staging-any/libraryfunctions.patch (rev 0) +++ community-staging-any/libraryfunctions.patch 2018-11-09 21:55:50 UTC (rev 404790) @@ -0,0 +1,363 @@ +diff -wbBur python-gnutls-2.0.1.org/gnutls/connection.py python-gnutls-2.0.1/gnutls/connection.py +--- python-gnutls-2.0.1.org/gnutls/connection.py 2014-07-02 15:19:26.000000000 +0400 ++++ python-gnutls-2.0.1/gnutls/connection.py 2015-04-20 20:23:20.288498813 +0300 +@@ -24,22 +24,22 @@ + from gnutls.library.constants import GNUTLS_A_CERTIFICATE_EXPIRED, GNUTLS_A_CERTIFICATE_REVOKED + from gnutls.library.constants import GNUTLS_NAME_DNS + from gnutls.library.types import gnutls_certificate_credentials_t, gnutls_session_t, gnutls_x509_crt_t +-from gnutls.library.types import gnutls_certificate_server_retrieve_function ++from gnutls.library.types import gnutls_certificate_retrieve_function2 + from gnutls.library.functions import * + + +-@gnutls_certificate_server_retrieve_function +-def _retrieve_server_certificate(c_session, retr_st): ++@gnutls_certificate_retrieve_function2 ++def _retrieve_server_certificate(c_session, a, b, c, d, retr2_st): + session = PyObj_FromPtr(gnutls_session_get_ptr(c_session)) + identity = session.credentials.select_server_identity(session) +- retr_st.contents.type = GNUTLS_CRT_X509 +- retr_st.contents.deinit_all = 0 ++ retr2_st.contents.cert_type = GNUTLS_CRT_X509 ++ retr2_st.contents.deinit_all = 0 + if identity is None: +- retr_st.contents.ncerts = 0 ++ retr2_st.contents.ncerts = 0 + else: +- retr_st.contents.ncerts = 1 +- retr_st.contents.cert.x509.contents = identity.cert._c_object +- retr_st.contents.key.x509 = identity.key._c_object ++ retr2_st.contents.ncerts = 1 ++ retr2_st.contents.cert.x509.contents = identity.cert._c_object ++ retr2_st.contents.key.x509 = identity.key._c_object + return 0 + + +@@ -91,7 +91,7 @@ + gnutls_certificate_set_x509_key(self._c_object, byref(cert._c_object), 1, key._c_object) + elif (cert, key) != (None, None): + raise ValueError("Specify neither or both the certificate and private key") +- gnutls_certificate_server_set_retrieve_function(self._c_object, _retrieve_server_certificate) ++ gnutls_certificate_set_retrieve_function2(self._c_object, _retrieve_server_certificate) + self._max_depth = 5 + self._max_bits = 8200 + self._type = CRED_CERTIFICATE +@@ -189,11 +189,14 @@ + """Select which identity the server will use for a given session. The default selection algorithm uses + the server name extension. A subclass can overwrite it if a different selection algorithm is desired.""" + server_name = session.server_name ++ print server_name + if server_name is not None: + return self.server_name_identities.get(server_name) + elif self.cert and self.key: ++ print "qweqwe\n" + return self ## since we have the cert and key attributes we can behave like a X509Identity + else: ++ print "asdasd\n" + return None + + +@@ -361,11 +364,7 @@ + session_params = self.credentials.session_params + # protocol order in the priority list is irrelevant (it always uses newer protocols first) + # the protocol list only specifies what protocols are to be enabled. +- gnutls_protocol_set_priority(self._c_object, c_priority_list(session_params.protocols)) +- gnutls_kx_set_priority(self._c_object, c_priority_list(session_params.kx_algorithms)) +- gnutls_cipher_set_priority(self._c_object, c_priority_list(session_params.ciphers)) +- gnutls_mac_set_priority(self._c_object, c_priority_list(session_params.mac_algorithms)) +- gnutls_compression_set_priority(self._c_object, c_priority_list(session_params.compressions)) ++ gnutls_set_default_priority(self._c_object) + + def handshake(self): + gnutls_handshake(self._c_object) +diff -wbBur python-gnutls-2.0.1.org/gnutls/crypto.py python-gnutls-2.0.1/gnutls/crypto.py +--- python-gnutls-2.0.1.org/gnutls/crypto.py 2011-05-20 17:13:12.000000000 +0400 ++++ python-gnutls-2.0.1/gnutls/crypto.py 2015-04-20 20:29:20.622064187 +0300 +@@ -332,14 +332,14 @@ + class RSAParams(object): + def __new__(cls, *args, **kwargs): + instance = object.__new__(cls) +- instance.__deinit = gnutls_rsa_params_deinit +- instance._c_object = gnutls_rsa_params_t() ++ instance.__deinit = gnutls_x509_privkey__deinit ++ instance._c_object =gnutls_x509_privkey_t() + return instance + + @method_args(int) + def __init__(self, bits=1024): +- gnutls_rsa_params_init(byref(self._c_object)) +- gnutls_rsa_params_generate2(self._c_object, bits) ++ gnutls_x509_privkey_init(byref(self._c_object)) ++ gnutls_x509_privkey_generate2(self._c_object, bits) + + def __get__(self, obj, type_=None): + return self._c_object +diff -wbBur python-gnutls-2.0.1.org/gnutls/library/functions.py python-gnutls-2.0.1/gnutls/library/functions.py +--- python-gnutls-2.0.1.org/gnutls/library/functions.py 2014-06-26 20:01:34.000000000 +0400 ++++ python-gnutls-2.0.1/gnutls/library/functions.py 2015-04-20 20:08:50.482643536 +0300 +@@ -84,10 +84,6 @@ + gnutls_certificate_client_get_request_status.argtypes = [gnutls_session_t] + gnutls_certificate_client_get_request_status.restype = c_int + +-gnutls_certificate_client_set_retrieve_function = libgnutls.gnutls_certificate_client_set_retrieve_function +-gnutls_certificate_client_set_retrieve_function.argtypes = [gnutls_certificate_credentials_t, gnutls_certificate_client_retrieve_function] +-gnutls_certificate_client_set_retrieve_function.restype = None +- + gnutls_certificate_expiration_time_peers = libgnutls.gnutls_certificate_expiration_time_peers + gnutls_certificate_expiration_time_peers.argtypes = [gnutls_session_t] + gnutls_certificate_expiration_time_peers.restype = time_t +@@ -129,9 +125,9 @@ + gnutls_certificate_server_set_request.argtypes = [gnutls_session_t, gnutls_certificate_request_t] + gnutls_certificate_server_set_request.restype = None + +-gnutls_certificate_server_set_retrieve_function = libgnutls.gnutls_certificate_server_set_retrieve_function +-gnutls_certificate_server_set_retrieve_function.argtypes = [gnutls_certificate_credentials_t, gnutls_certificate_server_retrieve_function] +-gnutls_certificate_server_set_retrieve_function.restype = None ++gnutls_certificate_set_retrieve_function2 = libgnutls.gnutls_certificate_set_retrieve_function2 ++gnutls_certificate_set_retrieve_function2.argtypes = [gnutls_certificate_credentials_t, gnutls_certificate_retrieve_function2] ++gnutls_certificate_set_retrieve_function2.restype = None + + gnutls_certificate_set_dh_params = libgnutls.gnutls_certificate_set_dh_params + gnutls_certificate_set_dh_params.argtypes = [gnutls_certificate_credentials_t, gnutls_dh_params_t] +@@ -141,10 +137,6 @@ + gnutls_certificate_set_params_function.argtypes = [gnutls_certificate_credentials_t, gnutls_params_function] + gnutls_certificate_set_params_function.restype = None + +-gnutls_certificate_set_rsa_export_params = libgnutls.gnutls_certificate_set_rsa_export_params +-gnutls_certificate_set_rsa_export_params.argtypes = [gnutls_certificate_credentials_t, gnutls_rsa_params_t] +-gnutls_certificate_set_rsa_export_params.restype = None +- + gnutls_certificate_set_verify_flags = libgnutls.gnutls_certificate_set_verify_flags + gnutls_certificate_set_verify_flags.argtypes = [gnutls_certificate_credentials_t, c_uint] + gnutls_certificate_set_verify_flags.restype = None +@@ -209,10 +201,6 @@ + gnutls_certificate_type_list.argtypes = [] + gnutls_certificate_type_list.restype = POINTER(gnutls_certificate_type_t) + +-gnutls_certificate_type_set_priority = libgnutls.gnutls_certificate_type_set_priority +-gnutls_certificate_type_set_priority.argtypes = [gnutls_session_t, POINTER(c_int)] +-gnutls_certificate_type_set_priority.restype = c_int +- + gnutls_certificate_verify_peers2 = libgnutls.gnutls_certificate_verify_peers2 + gnutls_certificate_verify_peers2.argtypes = [gnutls_session_t, POINTER(c_uint)] + gnutls_certificate_verify_peers2.restype = c_int +@@ -245,10 +233,6 @@ + gnutls_cipher_list.argtypes = [] + gnutls_cipher_list.restype = POINTER(gnutls_cipher_algorithm_t) + +-gnutls_cipher_set_priority = libgnutls.gnutls_cipher_set_priority +-gnutls_cipher_set_priority.argtypes = [gnutls_session_t, POINTER(c_int)] +-gnutls_cipher_set_priority.restype = c_int +- + gnutls_cipher_suite_get_name = libgnutls.gnutls_cipher_suite_get_name + gnutls_cipher_suite_get_name.argtypes = [gnutls_kx_algorithm_t, gnutls_cipher_algorithm_t, gnutls_mac_algorithm_t] + gnutls_cipher_suite_get_name.restype = c_char_p +@@ -273,10 +257,6 @@ + gnutls_compression_list.argtypes = [] + gnutls_compression_list.restype = POINTER(gnutls_compression_method_t) + +-gnutls_compression_set_priority = libgnutls.gnutls_compression_set_priority +-gnutls_compression_set_priority.argtypes = [gnutls_session_t, POINTER(c_int)] +-gnutls_compression_set_priority.restype = c_int +- + gnutls_credentials_clear = libgnutls.gnutls_credentials_clear + gnutls_credentials_clear.argtypes = [gnutls_session_t] + gnutls_credentials_clear.restype = None +@@ -465,10 +445,6 @@ + gnutls_kx_list.argtypes = [] + gnutls_kx_list.restype = POINTER(gnutls_kx_algorithm_t) + +-gnutls_kx_set_priority = libgnutls.gnutls_kx_set_priority +-gnutls_kx_set_priority.argtypes = [gnutls_session_t, POINTER(c_int)] +-gnutls_kx_set_priority.restype = c_int +- + gnutls_mac_get = libgnutls.gnutls_mac_get + gnutls_mac_get.argtypes = [gnutls_session_t] + gnutls_mac_get.restype = gnutls_mac_algorithm_t +@@ -489,26 +465,14 @@ + gnutls_mac_list.argtypes = [] + gnutls_mac_list.restype = POINTER(gnutls_mac_algorithm_t) + +-gnutls_mac_set_priority = libgnutls.gnutls_mac_set_priority +-gnutls_mac_set_priority.argtypes = [gnutls_session_t, POINTER(c_int)] +-gnutls_mac_set_priority.restype = c_int +- + gnutls_pem_base64_decode = libgnutls.gnutls_pem_base64_decode + gnutls_pem_base64_decode.argtypes = [c_char_p, POINTER(gnutls_datum_t), POINTER(c_ubyte), POINTER(size_t)] + gnutls_pem_base64_decode.restype = c_int + +-gnutls_pem_base64_decode_alloc = libgnutls.gnutls_pem_base64_decode_alloc +-gnutls_pem_base64_decode_alloc.argtypes = [c_char_p, POINTER(gnutls_datum_t), POINTER(gnutls_datum_t)] +-gnutls_pem_base64_decode_alloc.restype = c_int +- + gnutls_pem_base64_encode = libgnutls.gnutls_pem_base64_encode + gnutls_pem_base64_encode.argtypes = [c_char_p, POINTER(gnutls_datum_t), c_char_p, POINTER(size_t)] + gnutls_pem_base64_encode.restype = c_int + +-gnutls_pem_base64_encode_alloc = libgnutls.gnutls_pem_base64_encode_alloc +-gnutls_pem_base64_encode_alloc.argtypes = [c_char_p, POINTER(gnutls_datum_t), POINTER(gnutls_datum_t)] +-gnutls_pem_base64_encode_alloc.restype = c_int +- + gnutls_perror = libgnutls.gnutls_perror + gnutls_perror.argtypes = [c_int] + gnutls_perror.restype = None +@@ -613,10 +577,6 @@ + gnutls_protocol_list.argtypes = [] + gnutls_protocol_list.restype = POINTER(gnutls_protocol_t) + +-gnutls_protocol_set_priority = libgnutls.gnutls_protocol_set_priority +-gnutls_protocol_set_priority.argtypes = [gnutls_session_t, POINTER(c_int)] +-gnutls_protocol_set_priority.restype = c_int +- + gnutls_psk_allocate_client_credentials = libgnutls.gnutls_psk_allocate_client_credentials + gnutls_psk_allocate_client_credentials.argtypes = [POINTER(gnutls_psk_client_credentials_t)] + gnutls_psk_allocate_client_credentials.restype = c_int +@@ -705,46 +665,6 @@ + gnutls_rehandshake.argtypes = [gnutls_session_t] + gnutls_rehandshake.restype = c_int + +-gnutls_rsa_export_get_modulus_bits = libgnutls.gnutls_rsa_export_get_modulus_bits +-gnutls_rsa_export_get_modulus_bits.argtypes = [gnutls_session_t] +-gnutls_rsa_export_get_modulus_bits.restype = c_int +- +-gnutls_rsa_export_get_pubkey = libgnutls.gnutls_rsa_export_get_pubkey +-gnutls_rsa_export_get_pubkey.argtypes = [gnutls_session_t, POINTER(gnutls_datum_t), POINTER(gnutls_datum_t)] +-gnutls_rsa_export_get_pubkey.restype = c_int +- +-gnutls_rsa_params_cpy = libgnutls.gnutls_rsa_params_cpy +-gnutls_rsa_params_cpy.argtypes = [gnutls_rsa_params_t, gnutls_rsa_params_t] +-gnutls_rsa_params_cpy.restype = c_int +- +-gnutls_rsa_params_deinit = libgnutls.gnutls_rsa_params_deinit +-gnutls_rsa_params_deinit.argtypes = [gnutls_rsa_params_t] +-gnutls_rsa_params_deinit.restype = None +- +-gnutls_rsa_params_export_pkcs1 = libgnutls.gnutls_rsa_params_export_pkcs1 +-gnutls_rsa_params_export_pkcs1.argtypes = [gnutls_rsa_params_t, gnutls_x509_crt_fmt_t, POINTER(c_ubyte), POINTER(size_t)] +-gnutls_rsa_params_export_pkcs1.restype = c_int +- +-gnutls_rsa_params_export_raw = libgnutls.gnutls_rsa_params_export_raw +-gnutls_rsa_params_export_raw.argtypes = [gnutls_rsa_params_t, POINTER(gnutls_datum_t), POINTER(gnutls_datum_t), POINTER(gnutls_datum_t), POINTER(gnutls_datum_t), POINTER(gnutls_datum_t), POINTER(gnutls_datum_t), POINTER(c_uint)] +-gnutls_rsa_params_export_raw.restype = c_int +- +-gnutls_rsa_params_generate2 = libgnutls.gnutls_rsa_params_generate2 +-gnutls_rsa_params_generate2.argtypes = [gnutls_rsa_params_t, c_uint] +-gnutls_rsa_params_generate2.restype = c_int +- +-gnutls_rsa_params_import_pkcs1 = libgnutls.gnutls_rsa_params_import_pkcs1 +-gnutls_rsa_params_import_pkcs1.argtypes = [gnutls_rsa_params_t, POINTER(gnutls_datum_t), gnutls_x509_crt_fmt_t] +-gnutls_rsa_params_import_pkcs1.restype = c_int +- +-gnutls_rsa_params_import_raw = libgnutls.gnutls_rsa_params_import_raw +-gnutls_rsa_params_import_raw.argtypes = [gnutls_rsa_params_t, POINTER(gnutls_datum_t), POINTER(gnutls_datum_t), POINTER(gnutls_datum_t), POINTER(gnutls_datum_t), POINTER(gnutls_datum_t), POINTER(gnutls_datum_t)] +-gnutls_rsa_params_import_raw.restype = c_int +- +-gnutls_rsa_params_init = libgnutls.gnutls_rsa_params_init +-gnutls_rsa_params_init.argtypes = [POINTER(gnutls_rsa_params_t)] +-gnutls_rsa_params_init.restype = c_int +- + gnutls_server_name_get = libgnutls.gnutls_server_name_get + gnutls_server_name_get.argtypes = [gnutls_session_t, c_void_p, POINTER(size_t), POINTER(c_uint), c_uint] + gnutls_server_name_get.restype = c_int +@@ -785,10 +705,6 @@ + gnutls_session_set_ptr.argtypes = [gnutls_session_t, c_void_p] + gnutls_session_set_ptr.restype = None + +-gnutls_set_default_export_priority = libgnutls.gnutls_set_default_export_priority +-gnutls_set_default_export_priority.argtypes = [gnutls_session_t] +-gnutls_set_default_export_priority.restype = c_int +- + gnutls_set_default_priority = libgnutls.gnutls_set_default_priority + gnutls_set_default_priority.argtypes = [gnutls_session_t] + gnutls_set_default_priority.restype = c_int +@@ -797,14 +713,6 @@ + gnutls_sign_get_name.argtypes = [gnutls_sign_algorithm_t] + gnutls_sign_get_name.restype = c_char_p + +-gnutls_sign_callback_get = libgnutls.gnutls_sign_callback_get +-gnutls_sign_callback_get.argtypes = [gnutls_session_t, POINTER(c_void_p)] +-gnutls_sign_callback_get.restype = gnutls_sign_func +- +-gnutls_sign_callback_set = libgnutls.gnutls_sign_callback_set +-gnutls_sign_callback_set.argtypes = [gnutls_session_t, gnutls_sign_func, c_void_p] +-gnutls_sign_callback_set.restype = None +- + gnutls_strerror = libgnutls.gnutls_strerror + gnutls_strerror.argtypes = [c_int] + gnutls_strerror.restype = c_char_p +@@ -1285,10 +1193,6 @@ + gnutls_x509_crt_verify.argtypes = [gnutls_x509_crt_t, POINTER(gnutls_x509_crt_t), c_int, c_uint, POINTER(c_uint)] + gnutls_x509_crt_verify.restype = c_int + +-gnutls_x509_crt_verify_data = libgnutls.gnutls_x509_crt_verify_data +-gnutls_x509_crt_verify_data.argtypes = [gnutls_x509_crt_t, c_uint, POINTER(gnutls_datum_t), POINTER(gnutls_datum_t)] +-gnutls_x509_crt_verify_data.restype = c_int +- + gnutls_x509_dn_deinit = libgnutls.gnutls_x509_dn_deinit + gnutls_x509_dn_deinit.argtypes = [gnutls_x509_dn_t] + gnutls_x509_dn_deinit.restype = None +@@ -1708,18 +1612,10 @@ + gnutls_srp_base64_decode.argtypes = [POINTER(gnutls_datum_t), c_char_p, POINTER(size_t)] + gnutls_srp_base64_decode.restype = c_int + +- gnutls_srp_base64_decode_alloc = libgnutls.gnutls_srp_base64_decode_alloc +- gnutls_srp_base64_decode_alloc.argtypes = [POINTER(gnutls_datum_t), POINTER(gnutls_datum_t)] +- gnutls_srp_base64_decode_alloc.restype = c_int +- + gnutls_srp_base64_encode = libgnutls.gnutls_srp_base64_encode + gnutls_srp_base64_encode.argtypes = [POINTER(gnutls_datum_t), c_char_p, POINTER(size_t)] + gnutls_srp_base64_encode.restype = c_int + +- gnutls_srp_base64_encode_alloc = libgnutls.gnutls_srp_base64_encode_alloc +- gnutls_srp_base64_encode_alloc.argtypes = [POINTER(gnutls_datum_t), POINTER(gnutls_datum_t)] +- gnutls_srp_base64_encode_alloc.restype = c_int +- + gnutls_srp_free_client_credentials = libgnutls.gnutls_srp_free_client_credentials + gnutls_srp_free_client_credentials.argtypes = [gnutls_srp_client_credentials_t] + gnutls_srp_free_client_credentials.restype = None +diff -wbBur python-gnutls-2.0.1.org/gnutls/library/types.py python-gnutls-2.0.1/gnutls/library/types.py +--- python-gnutls-2.0.1.org/gnutls/library/types.py 2010-01-22 11:20:36.000000000 +0300 ++++ python-gnutls-2.0.1/gnutls/library/types.py 2015-04-20 20:29:35.621935109 +0300 +@@ -27,6 +27,7 @@ + gnutls_certificate_status_t = c_int # enum + gnutls_certificate_type_t = c_int # enum + gnutls_certificate_verify_flags = c_int # enum ++gnutls_privkey_type_t = c_int # enum + gnutls_cipher_algorithm_t = c_int # enum + gnutls_close_request_t = c_int # enum + gnutls_compression_method_t = c_int # enum +@@ -76,11 +77,10 @@ + class gnutls_x509_privkey_int(Structure): + _fields_ = [] + gnutls_x509_privkey_t = POINTER(gnutls_x509_privkey_int) +-gnutls_rsa_params_t = POINTER(gnutls_x509_privkey_int) + + class params(Union): + _fields_ = [('dh', gnutls_dh_params_t), +- ('rsa_export', gnutls_rsa_params_t)] ++ ('rsa_export', gnutls_x509_privkey_t)] + + class gnutls_priority_st(Structure): + _fields_ = [] +@@ -153,8 +153,9 @@ + _fields_ = [('x509', gnutls_x509_privkey_t), + ('pgp', gnutls_openpgp_privkey_t)] + +-class gnutls_retr_st(Structure): +- _fields_ = [('type', gnutls_certificate_type_t), ++class gnutls_retr2_st(Structure): ++ _fields_ = [('cert_type', gnutls_certificate_type_t), ++ ('key_type', gnutls_privkey_type_t), + ('cert', cert), + ('ncerts', c_uint), + ('key', key), +@@ -179,8 +180,7 @@ + + gnutls_alloc_function = CFUNCTYPE(c_void_p, size_t) + gnutls_calloc_function = CFUNCTYPE(c_void_p, size_t, size_t) +-gnutls_certificate_client_retrieve_function = CFUNCTYPE(c_int, gnutls_session_t, POINTER(gnutls_datum_t), c_int, POINTER(gnutls_pk_algorithm_t), c_int, POINTER(gnutls_retr_st)) +-gnutls_certificate_server_retrieve_function = CFUNCTYPE(c_int, gnutls_session_t, POINTER(gnutls_retr_st)) ++gnutls_certificate_retrieve_function2 = CFUNCTYPE(c_int, gnutls_session_t, c_void_p, c_int, c_void_p, c_int, POINTER(gnutls_retr2_st)) + gnutls_db_remove_func = CFUNCTYPE(c_int, c_void_p, gnutls_datum_t) + gnutls_db_retr_func = CFUNCTYPE(gnutls_datum_t, c_void_p, gnutls_datum_t) + gnutls_db_store_func = CFUNCTYPE(c_int, c_void_p, gnutls_datum_t, gnutls_datum_t) Copied: python2-gnutls/repos/community-staging-any/libraryinit.patch (from rev 404789, python2-gnutls/trunk/libraryinit.patch) =================================================================== --- community-staging-any/libraryinit.patch (rev 0) +++ community-staging-any/libraryinit.patch 2018-11-09 21:55:50 UTC (rev 404790) @@ -0,0 +1,12 @@ +diff -wbBur python-gnutls-2.0.1/gnutls/library/__init__.py python-gnutls-2.0.1.my/gnutls/library/__init__.py +--- python-gnutls-2.0.1/gnutls/library/__init__.py 2014-06-26 20:01:34.000000000 +0400 ++++ python-gnutls-2.0.1.my/gnutls/library/__init__.py 2015-04-20 17:43:39.153403713 +0300 +@@ -56,7 +56,7 @@ + raise RuntimeError('cannot find libgnutls on this system') + + +-libgnutls = load_library(version=28) ++libgnutls = load_library(version=30) + libgnutls.gnutls_global_init() + +