]> git.pld-linux.org Git - packages/python-cryptography.git/blame - python-cryptography-openssl3.0.1.patch
- added openssl3.0.1 patch
[packages/python-cryptography.git] / python-cryptography-openssl3.0.1.patch
CommitLineData
f7fe41d0
JB
1https://github.com/pyca/cryptography/pull/6403
2
3From 076560a9507bbe26180f499adf750bc3851b97e8 Mon Sep 17 00:00:00 2001
4From: Alex Gaynor <alex.gaynor@gmail.com>
5Date: Mon, 11 Oct 2021 09:43:28 -0400
6Subject: [PATCH] Specify the out length when obtaining the tag for poly1305
7
8---
9 src/cryptography/hazmat/backends/openssl/poly1305.py | 2 +-
10 1 file changed, 1 insertion(+), 1 deletion(-)
11
12diff --git a/src/cryptography/hazmat/backends/openssl/poly1305.py b/src/cryptography/hazmat/backends/openssl/poly1305.py
13index 35f6819ce87..2ddae9847a4 100644
14--- a/src/cryptography/hazmat/backends/openssl/poly1305.py
15+++ b/src/cryptography/hazmat/backends/openssl/poly1305.py
16@@ -51,7 +51,7 @@ def update(self, data):
17
18 def finalize(self):
19 buf = self._backend._ffi.new("unsigned char[]", _POLY1305_TAG_SIZE)
20- outlen = self._backend._ffi.new("size_t *")
21+ outlen = self._backend._ffi.new("size_t *", _POLY1305_TAG_SIZE)
22 res = self._backend._lib.EVP_DigestSignFinal(self._ctx, buf, outlen)
23 self._backend.openssl_assert(res != 0)
24 self._backend.openssl_assert(outlen[0] == _POLY1305_TAG_SIZE)
This page took 0.053056 seconds and 4 git commands to generate.