Upgrade to 1.0 release

Resolves: RHEL-60089

Signed-off-by: Simo Sorce <simo@redhat.com>
This commit is contained in:
Simo Sorce 2025-02-11 14:02:32 -05:00
parent 1e4ddce444
commit 61db950bcf
4 changed files with 5 additions and 53 deletions

2
.gitignore vendored
View File

@ -4,3 +4,5 @@
/pkcs11-provider-0.3.tar.xz.asc
/pkcs11-provider-0.5.tar.xz
/pkcs11-provider-0.5.tar.xz.asc
/pkcs11-provider-1.0.tar.xz
/pkcs11-provider-1.0.tar.xz.asc

View File

@ -1,49 +0,0 @@
From 9fa16b7fd398b62f06cb10892fe93dc574d67399 Mon Sep 17 00:00:00 2001
From: Simo Sorce <simo@redhat.com>
Date: Wed, 5 Jun 2024 11:22:35 -0400
Subject: [PATCH] Fix types for old 32 bit systems
On x86 CK_ULONG and size_t have different sizes, ensure we use
compatible types on our helper functions.
Signed-off-by: Simo Sorce <simo@redhat.com>
---
src/asymmetric_cipher.c | 4 ++--
src/util.h | 2 +-
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/src/asymmetric_cipher.c b/src/asymmetric_cipher.c
index 4d87b1c..3256fd2 100644
--- a/src/asymmetric_cipher.c
+++ b/src/asymmetric_cipher.c
@@ -251,12 +251,12 @@ static int p11prov_rsaenc_decrypt_init(void *ctx, void *provkey,
static int
p11prov_tls_constant_time_depadding(struct p11prov_rsaenc_ctx *encctx,
unsigned char *out, unsigned char *buf,
- size_t *out_size, CK_ULONG *ret_cond)
+ CK_ULONG *out_size, CK_ULONG *ret_cond)
{
unsigned char randbuf[SSL_MAX_MASTER_KEY_LENGTH];
CK_ULONG ver_cond = 0;
CK_ULONG cond = 0;
- size_t length = SSL_MAX_MASTER_KEY_LENGTH;
+ CK_ULONG length = SSL_MAX_MASTER_KEY_LENGTH;
int err;
/* always generate a random buffer, to constant_time swap in
diff --git a/src/util.h b/src/util.h
index bcbc2db..1b24666 100644
--- a/src/util.h
+++ b/src/util.h
@@ -120,7 +120,7 @@ static inline int constant_select_int(CK_ULONG cond, int a, int b)
return (int)((A & mask) | (B & ~mask));
}
-static inline void constant_select_buf(CK_ULONG cond, size_t size,
+static inline void constant_select_buf(CK_ULONG cond, CK_ULONG size,
unsigned char *dst, unsigned char *a,
unsigned char *b)
{
--
2.45.0

View File

@ -2,7 +2,7 @@
%bcond_with gpgcheck
Name: pkcs11-provider
Version: 0.5
Version: 1.0
Release: %autorelease
Summary: A PKCS#11 provider for OpenSSL 3.0+
License: Apache-2.0
@ -35,7 +35,6 @@ BuildRequires: gnutls-utils
BuildRequires: xz
BuildRequires: expect
Patch01: 0001-Fix-types-for-old-32-bit-systems.patch
%description
This is an Openssl 3.x provider to access Hardware or Software Tokens using

View File

@ -1,2 +1,2 @@
SHA512 (pkcs11-provider-0.5.tar.xz) = df292ba7da467608aad5343041708ccbe896422f21718092235ae3610035c91b57ffc6f4e495edd29c55f6f48d9c88f29e0c251ab5ff865f3b1554de37d1492d
SHA512 (pkcs11-provider-0.5.tar.xz.asc) = 2ad0b47e965171313fec76b399a613633671aa62438614abe42484a98d3f54388e6615f7169aed5b27c729684ffeae6df80a34b0c05a34515a73c72e51b843e2
SHA512 (pkcs11-provider-1.0.tar.xz) = 004eeb8816903a670abff51c150e50b93515aeeeb29af7cdf921578981326286ffc7432057abf8e9b4e35972800a8bf554255ace3f8bf2359c010cc343194798
SHA512 (pkcs11-provider-1.0.tar.xz.asc) = a19bea50f056a5dbe66ed3fc21960107eb49eb893d25b5b32599388042124bb06776a34596191cddd20ab660e07dccc14d4fb593eb8a001f84c94a9a5d4dd3c4