Skip to content
This repository has been archived by the owner on Jan 1, 2022. It is now read-only.

Commit

Permalink
main/libetpan: fix user cert
Browse files Browse the repository at this point in the history
  • Loading branch information
ncopa authored and neechbear committed Sep 9, 2018
1 parent 9449abc commit e135bb2
Show file tree
Hide file tree
Showing 4 changed files with 33 additions and 68 deletions.
27 changes: 27 additions & 0 deletions main/libetpan/0001-Fix-user-certificate-with-gnutls-3.0-api.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
From 98ecc14f0cb7130a4651ca4c7bd02af05d5a365a Mon Sep 17 00:00:00 2001
From: Natanael Copa <[email protected]>
Date: Mon, 27 Aug 2018 10:12:10 +0200
Subject: [PATCH] Fix user certificate with gnutls 3.0 api

fixes #288
---
src/data-types/mailstream_ssl.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/data-types/mailstream_ssl.c b/src/data-types/mailstream_ssl.c
index 248d392..cb0a17e 100644
--- a/src/data-types/mailstream_ssl.c
+++ b/src/data-types/mailstream_ssl.c
@@ -568,7 +568,8 @@ static int mailstream_gnutls_client_cert_cb(gnutls_session session,
#if GNUTLS_VERSION_NUMBER <= 0x020c00
st->type = type;
#else
- st->key_type = type;
+ st->cert_type = type;
+ st->key_type = GNUTLS_PRIVKEY_X509;
#endif
st->cert.x509 = &(ssl_context->client_x509);
st->key.x509 = ssl_context->client_pkey;
--
2.18.0

9 changes: 6 additions & 3 deletions main/libetpan/APKBUILD
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Maintainer: Natanael Copa <[email protected]>
pkgname=libetpan
pkgver=1.8
pkgrel=2
pkgrel=1
pkgdesc="a portable middleware for email access"
url="http://www.etpan.org/"
arch="all"
Expand All @@ -10,7 +10,9 @@ subpackages="$pkgname-dev $pkgname-doc"
makedepends="db-dev cyrus-sasl-dev curl-dev expat-dev gnutls-dev libgcrypt-dev
libgpg-error-dev autoconf automake libtool zlib-dev"
depends_dev="cyrus-sasl-dev db-dev"
source="libetpan-$pkgver.tar.gz::https://github.com/dinhviethoa/libetpan/archive/$pkgver.tar.gz"
source="libetpan-$pkgver.tar.gz::https://github.com/dinhviethoa/libetpan/archive/$pkgver.tar.gz
0001-Fix-user-certificate-with-gnutls-3.0-api.patch
"

builddir="$srcdir/$pkgname-$pkgver"

Expand Down Expand Up @@ -44,4 +46,5 @@ package() {
install -Dm644 COPYRIGHT "$pkgdir"/usr/share/licenses/$pkgname/license.txt
}

sha512sums="a5e97998803cc56dbd54356153c8579b52a9675fe95fbf642c3158215428d9d2cb30c4e0060c5f4dd760634fff5b1c2a32ce4bb70a5f2bc6398a071ce95e1efd libetpan-1.8.tar.gz"
sha512sums="a5e97998803cc56dbd54356153c8579b52a9675fe95fbf642c3158215428d9d2cb30c4e0060c5f4dd760634fff5b1c2a32ce4bb70a5f2bc6398a071ce95e1efd libetpan-1.8.tar.gz
884f3c0bde7ba4a9128c6fb86bf6667f2388b6ca197051083c928cb36df7c909367a5cb0042826ce6199ce3d1e5161e36db6f3fc3ce3808eb431ddd8d8d530ef 0001-Fix-user-certificate-with-gnutls-3.0-api.patch"
32 changes: 0 additions & 32 deletions main/libetpan/gnutls-fix-1.patch

This file was deleted.

33 changes: 0 additions & 33 deletions main/libetpan/gnutls-fix-2.patch

This file was deleted.

0 comments on commit e135bb2

Please sign in to comment.