[pkg-opensc-commit] [opensc] 05/11: debian/patches/0001-pkcs15_compute_cert_length.diff, debian/patches/0002-fix-for-aventra-myeid.diff: Drop upstreamed patches.

Eric Dorland eric at moszumanska.debian.org
Sat Jul 5 21:24:22 UTC 2014


This is an automated email from the git hooks/post-receive script.

eric pushed a commit to branch master
in repository opensc.

commit 80d6cc3e239cc48847fe6e83ff1c32fb4cf5317c
Author: Eric Dorland <eric at debian.org>
Date:   Sat Jul 5 15:24:09 2014 -0400

    debian/patches/0001-pkcs15_compute_cert_length.diff, debian/patches/0002-fix-for-aventra-myeid.diff: Drop upstreamed patches.
---
 debian/changelog                                   |   3 +
 .../patches/0001-pkcs15_compute_cert_length.diff   | 109 ---------------------
 debian/patches/0002-fix-for-aventra-myeid.diff     |  28 ------
 debian/patches/series                              |   2 -
 4 files changed, 3 insertions(+), 139 deletions(-)

diff --git a/debian/changelog b/debian/changelog
index 2c4c540..5e3f5d3 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -2,6 +2,9 @@ opensc (0.14.0-1) unstable; urgency=medium
 
   * New upstream release. (Closes: #746694, #731235)
   * debian/watch: Update to new GitHub location.
+  * debian/patches/0001-pkcs15_compute_cert_length.diff,
+    debian/patches/0002-fix-for-aventra-myeid.diff: Drop upstreamed
+    patches.
 
  --
 
diff --git a/debian/patches/0001-pkcs15_compute_cert_length.diff b/debian/patches/0001-pkcs15_compute_cert_length.diff
deleted file mode 100644
index b2de773..0000000
--- a/debian/patches/0001-pkcs15_compute_cert_length.diff
+++ /dev/null
@@ -1,109 +0,0 @@
-From cc5a171ddcc8e49b2252135daac9ad3aa6d66ae7 Mon Sep 17 00:00:00 2001
-From: Viktor Tarasov <viktor.tarasov at gmail.com>
-Date: Tue, 25 Dec 2012 20:05:45 +0100
-Subject: [PATCH] pkcs15: regression in e35febe: compute cert length
-
-parse_x509_cert() reviewed.
-Now certificate's DER data are allocated and the DER data length is determined in one place.
-
-https://github.com/OpenSC/OpenSC/pull/114
-https://github.com/OpenSC/OpenSC/commit/e35febe
----
- src/libopensc/pkcs15-cert.c | 37 +++++++++++++++++++------------------
- 1 file changed, 19 insertions(+), 18 deletions(-)
-
---- a/src/libopensc/pkcs15-cert.c
-+++ b/src/libopensc/pkcs15-cert.c
-@@ -34,13 +34,13 @@
- #include "pkcs15.h"
- 
- static int
--parse_x509_cert(sc_context_t *ctx, const u8 *buf, size_t buflen, struct sc_pkcs15_cert *cert)
-+parse_x509_cert(sc_context_t *ctx, struct sc_pkcs15_der *der, struct sc_pkcs15_cert *cert)
- {
- 	int r;
- 	struct sc_algorithm_id sig_alg;
--	struct sc_pkcs15_pubkey  * pubkey = NULL;
--	u8 *serial = NULL;
--	size_t serial_len = 0;
-+	struct sc_pkcs15_pubkey *pubkey = NULL;
-+	unsigned char *serial = NULL, *buf =  der->value;
-+	size_t serial_len = 0, data_len = 0, buflen = der->len;
- 	struct sc_asn1_entry asn1_version[] = {
- 		{ "version", SC_ASN1_INTEGER, SC_ASN1_TAG_INTEGER, 0, &cert->version, NULL },
- 		{ NULL, 0, 0, 0, NULL, NULL }
-@@ -87,30 +87,32 @@ parse_x509_cert(sc_context_t *ctx, const
- 	if (obj == NULL)
- 		LOG_TEST_RET(ctx, SC_ERROR_INVALID_ASN1_OBJECT, "X.509 certificate not found");
- 
--	cert->data.len = objlen + (obj - buf);
-+	data_len = objlen + (obj - buf);
-+	cert->data.value = malloc(data_len);
-+	if (!cert->data.value)
-+		LOG_FUNC_RETURN(ctx, SC_ERROR_OUT_OF_MEMORY);
-+	memcpy(cert->data.value, buf, data_len);
-+	cert->data.len = data_len;
-+
- 	r = sc_asn1_decode(ctx, asn1_cert, obj, objlen, NULL, NULL);
- 	LOG_TEST_RET(ctx, r, "ASN.1 parsing of certificate failed");
- 
- 	cert->version++;
- 
--	if (pubkey) {
--		cert->key = pubkey;
--		pubkey = NULL;
--	}
--	else {
-+	if (!pubkey)
- 		LOG_TEST_RET(ctx, SC_ERROR_INVALID_ASN1_OBJECT, "Unable to decode subjectPublicKeyInfo from cert");
--	}
-+	cert->key = pubkey;
-+
- 	sc_asn1_clear_algorithm_id(&sig_alg);
--	if (r < 0)
--		return r;
- 
- 	if (serial && serial_len)   {
- 		sc_format_asn1_entry(asn1_serial_number + 0, serial, &serial_len, 1);
- 		r = sc_asn1_encode(ctx, asn1_serial_number, &cert->serial, &cert->serial_len);
- 		free(serial);
-+		LOG_TEST_RET(ctx, r, "ASN.1 encoding of serial failed");
- 	}
- 
--	return r;
-+	return SC_SUCCESS;
- }
- 
- 
-@@ -125,7 +127,7 @@ sc_pkcs15_pubkey_from_cert(struct sc_con
- 	if (cert == NULL)
- 		return SC_ERROR_OUT_OF_MEMORY;
- 
--	rv = parse_x509_cert(ctx, cert_blob->value, cert_blob->len, cert);
-+	rv = parse_x509_cert(ctx, cert_blob, cert);
- 
- 	*out = cert->key;
- 	cert->key = NULL;
-@@ -158,20 +160,19 @@ sc_pkcs15_read_certificate(struct sc_pkc
- 		return SC_ERROR_OBJECT_NOT_FOUND;
- 	}
- 
--
- 	cert = malloc(sizeof(struct sc_pkcs15_cert));
- 	if (cert == NULL) {
- 		free(der.value);
- 		return SC_ERROR_OUT_OF_MEMORY;
- 	}
- 	memset(cert, 0, sizeof(struct sc_pkcs15_cert));
--	if (parse_x509_cert(p15card->card->ctx, der.value, der.len, cert)) {
-+	if (parse_x509_cert(p15card->card->ctx, &der, cert)) {
- 		free(der.value);
- 		sc_pkcs15_free_certificate(cert);
- 		return SC_ERROR_INVALID_ASN1_OBJECT;
- 	}
-+	free(der.value);
- 
--	cert->data = der;
- 	*cert_out = cert;
- 	return SC_SUCCESS;
- }
diff --git a/debian/patches/0002-fix-for-aventra-myeid.diff b/debian/patches/0002-fix-for-aventra-myeid.diff
deleted file mode 100644
index 44b39b4..0000000
--- a/debian/patches/0002-fix-for-aventra-myeid.diff
+++ /dev/null
@@ -1,28 +0,0 @@
-From: =?UTF-8?q?Toni=20Sj=C3=B6blom?= <development at aventra.fi>
-Date: Fri, 18 Jan 2013 16:26:36 +0200
-Subject: [PATCH 1/1] Fixed file-id in myeid.profile
-Origin: https://github.com/OpenSC/OpenSC/commit/58679a5
-Bug: https://github.com/OpenSC/OpenSC/issues/120
-Forwarded: not-needed
-Applied-Upstream: 58679a5df13d45a13fc35b29ce10511218fcbaae
-
----
- src/pkcs15init/myeid.profile |    2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/pkcs15init/myeid.profile b/src/pkcs15init/myeid.profile
-index 46ae44c..8b84c95 100644
---- a/src/pkcs15init/myeid.profile
-+++ b/src/pkcs15init/myeid.profile
-@@ -201,7 +201,7 @@ filesystem {
-                     acl       = READ=$PIN, UPDATE=$PIN, DELETE=$PIN;
-                 }
-                 EF data {
--                    file-id   = 4501;
-+                    file-id   = 4601;
-                     structure = transparent;
-                     acl       = READ=NONE, UPDATE=$PIN, DELETE=$PIN;
-                 }
--- 
-1.7.9.5
-
diff --git a/debian/patches/series b/debian/patches/series
deleted file mode 100644
index 68c8584..0000000
--- a/debian/patches/series
+++ /dev/null
@@ -1,2 +0,0 @@
-0001-pkcs15_compute_cert_length.diff
-0002-fix-for-aventra-myeid.diff

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-opensc/opensc.git



More information about the pkg-opensc-commit mailing list