11
0

13 Commits

Author SHA256 Message Date
c8aaabd165 Accepting request 1298176 from devel:languages:python
- Refresh the source tarball.
- add patch use-c99-for-preproccessing.patch to fix build

OBS-URL: https://build.opensuse.org/request/show/1298176
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-tpm2-pytss?expand=0&rev=7
2025-08-08 13:12:02 +00:00
e2edcafc86 Accepting request 1206411 from devel:languages:python
- Update to version 2.3.0:
  * FAPI: support exists_ok for create_nv
  * Compatibility with python-cryptography 42
  * scripts: update regex for #defines
  * cryptography: fixes for newer version of cryptography
  * docs/maintainers: add gpg key details
  * docs: fix whitespace error
  * docs: fix error on SECURITY.md not being used
  * cryptography: add module for using TPM keys with the cryptography module
  * encoding: add deprecation warning to tools_encdec
  * internal/crypto: fix _MyRSAPrivateNumbers with cryptograpy >= 42.0.1
  * test: disable pcr_set_auth_value and pcr_set_auth_policy tests for swtpm
- Drop patch python-tpm2-pytss-RSAPrivateNumbers.patch, included upstream.
- Switch to pyproject macros.

OBS-URL: https://build.opensuse.org/request/show/1206411
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-tpm2-pytss?expand=0&rev=6
2024-10-09 20:12:46 +00:00
3c36aff150 - Update to version 2.3.0:
* FAPI: support exists_ok for create_nv
  * Compatibility with python-cryptography 42
  * scripts: update regex for #defines
  * cryptography: fixes for newer version of cryptography
  * docs/maintainers: add gpg key details
  * docs: fix whitespace error
  * docs: fix error on SECURITY.md not being used
  * cryptography: add module for using TPM keys with the cryptography module
  * encoding: add deprecation warning to tools_encdec
  * internal/crypto: fix _MyRSAPrivateNumbers with cryptograpy >= 42.0.1
  * test: disable pcr_set_auth_value and pcr_set_auth_policy tests for swtpm
- Drop patch python-tpm2-pytss-RSAPrivateNumbers.patch, included upstream.
- Switch to pyproject macros.

OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-tpm2-pytss?expand=0&rev=11
2024-10-09 04:01:48 +00:00
50006b9517 Accepting request 1152931 from devel:languages:python
OBS-URL: https://build.opensuse.org/request/show/1152931
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-tpm2-pytss?expand=0&rev=5
2024-02-28 18:47:51 +00:00
fb2280729f Accepting request 1152904 from home:pmonrealgonzalez:branches:devel:languages:python
- Fix tpm2-pkcs11 build:
  * internal/crypto: fix _MyRSAPrivateNumbers with cryptograpy >= 42.0.1
  * Upstream: github.com/tpm2-software/tpm2-pytss/pull/562
  * Add python-tpm2-pytss-RSAPrivateNumbers.patch

- Update to version 2.2.0:
  * docs: use same requirements as in setup.cfg
  * policy: fix hardcoded size in description
  * policy: fix hardcoded size in get_calculated_json
  * readthedocs: switch to new build specification format
  * test: test against python 3.12
  * test: skip tests if ECC curves aren't supported.
  * init: provide a better error message for missing symbols
  * scripts: remove references to TPMS_ALGORITHM_DESCRIPTION
  * tctildr: use Tss2_TctiLdr_GetInfo to lookup tcti backend
  * setup: fixup compilation with fortify source enabled
  * setup: drop python 3.7
  * test: add check for renamed cryptography types
  * constants: use relative import over absolute
  * constants: support unmarshal and marshal routines
  * ESAPI: fix check on ESYS_TR in policy_secret
  * constants: add routine for making ESYS_TR from parts
  * setup: define __float128 for pycparse
  * Remove fix_pycparse_float128.patch fixed upstream

OBS-URL: https://build.opensuse.org/request/show/1152904
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-tpm2-pytss?expand=0&rev=9
2024-02-28 13:21:33 +00:00
7b13058015 Accepting request 1066386 from devel:languages:python
OBS-URL: https://build.opensuse.org/request/show/1066386
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-tpm2-pytss?expand=0&rev=4
2023-02-17 15:45:47 +00:00
e252b5f565 Accepting request 1066385 from home:aplanas:branches:devel:languages:python
OBS-URL: https://build.opensuse.org/request/show/1066385
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-tpm2-pytss?expand=0&rev=7
2023-02-17 13:24:28 +00:00
948eeb54f5 Accepting request 1066210 from devel:languages:python
OBS-URL: https://build.opensuse.org/request/show/1066210
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-tpm2-pytss?expand=0&rev=3
2023-02-16 20:09:57 +00:00
a0e5571812 Accepting request 1066209 from home:aplanas:branches:devel:languages:python
- Update to version 2.1.0:
  * CHANGELOG: update for 2.1.0
  * SECURITY.md: initial commit
  * TCTISPIHelper: add missing pass
  * TCTISPIHelper: update docs on exceptions
  * build(deps): bump gitpython from 3.1.24 to 3.1.30 in /docs
  * ci: set publish to use ubuntu-20.04
  * CHANGELOG: update for 2.1.0-rc0
  * TCTI: Implement bindings to spi-helper
  * ci: add 4.0.0, drop 2.4.6
  * docs: fix PyTCTI members
  * use released tss2 versions for library version checking
  * build(deps): bump certifi from 2021.10.8 to 2022.12.7 in /docs
  * Add util functions to convert a credential from and to tpm2-tools format
  * ESAPI: start_auth_session support strs for auth_hash
  * ESAPI: start_auth_session support strings for symdef
  * types: add parse to TPMT_SYM_[DEF|_OBJECT]
  * internal: check for sphinx not unittest.mock for docs workaround

OBS-URL: https://build.opensuse.org/request/show/1066209
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-tpm2-pytss?expand=0&rev=5
2023-02-16 15:37:16 +00:00
4fa7fc286d Accepting request 1041865 from devel:languages:python
OBS-URL: https://build.opensuse.org/request/show/1041865
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-tpm2-pytss?expand=0&rev=2
2022-12-10 20:18:07 +00:00
51ccbc5d57 Accepting request 1041864 from home:aplanas:branches:devel:languages:python
- Update to version 2.0.0:
  * CHANGELOG: update for 2.0 release
  * CHANGELOG: move breaking items to changed
  * Revert "ci: publish_pkg update to tss 4.0.0-rc0"
  * ci: publish_pkg update to tss 4.0.0-rc0
  * ci: update publish script to py3.7
  * README: Update mailing list
  * CHANGELOG: update for 2.0-rc0
  * docs: add PyTCTI to docs
  * README: add newest libraries
  * FAPI: drop unused import Dict
- Drop patch 0001-test_crypto-fix-test_ecc_bad_curves-assert.patch

OBS-URL: https://build.opensuse.org/request/show/1041864
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-tpm2-pytss?expand=0&rev=3
2022-12-09 12:46:44 +00:00
9ca193ea16 Accepting request 988568 from devel:languages:python
The new version of tpm2-pkcs11 (present in Factory) requires this package.  Eventually this TSS bindings will be used in Keylime too.

OBS-URL: https://build.opensuse.org/request/show/988568
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-tpm2-pytss?expand=0&rev=1
2022-07-13 11:45:06 +00:00
e58b4efb36 Accepting request 988380 from home:aplanas:branches:security
tpm2-pytss contains the Python bindings to call the tpm2-tss libraries (mainly FAPI and ESAPI interfaces)

OBS-URL: https://build.opensuse.org/request/show/988380
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-tpm2-pytss?expand=0&rev=1
2022-07-11 16:38:58 +00:00
2 changed files with 0 additions and 56 deletions

View File

@@ -1,53 +0,0 @@
Index: tpm2-pytss-2.2.0/src/tpm2_pytss/internal/crypto.py
===================================================================
--- tpm2-pytss-2.2.0.orig/src/tpm2_pytss/internal/crypto.py
+++ tpm2-pytss-2.2.0/src/tpm2_pytss/internal/crypto.py
@@ -23,7 +23,7 @@ from cryptography.hazmat.primitives.ciph
from cryptography.hazmat.primitives.ciphers import modes, Cipher, CipherAlgorithm
from cryptography.hazmat.backends import default_backend
from cryptography.exceptions import UnsupportedAlgorithm, InvalidSignature
-from typing import Tuple, Type
+from typing import Tuple, Type, Any
import secrets
import sys
@@ -220,7 +220,7 @@ def public_to_key(obj):
return key
-class _MyRSAPrivateNumbers(rsa.RSAPrivateNumbers):
+class _MyRSAPrivateNumbers:
def __init__(self, p: int, n: int, e: int, pubnums: rsa.RSAPublicNumbers):
q = n // p
@@ -231,7 +231,12 @@ class _MyRSAPrivateNumbers(rsa.RSAPrivat
dmq1 = rsa.rsa_crt_dmq1(d, q)
iqmp = rsa.rsa_crt_iqmp(p, q)
- super().__init__(p, q, d, dmp1, dmq1, iqmp, pubnums)
+ self._private_numbers = rsa.RSAPrivateNumbers(
+ p, q, d, dmp1, dmq1, iqmp, pubnums
+ )
+
+ def private_key(self, *args: Any, **kwargs: Any) -> rsa.RSAPrivateKey:
+ return self._private_numbers.private_key(*args, **kwargs)
@staticmethod
def _xgcd(a: int, b: int) -> Tuple[int, int, int]:
@@ -251,15 +256,7 @@ class _MyRSAPrivateNumbers(rsa.RSAPrivat
#
@staticmethod
def _modinv(a, m):
-
- if sys.version_info < (3, 8):
- g, x, y = _MyRSAPrivateNumbers._xgcd(a, m)
- if g != 1:
- raise Exception("modular inverse does not exist")
- else:
- return x % m
- else:
- return pow(a, -1, m)
+ return pow(a, -1, m)
@staticmethod
def _generate_d(p, q, e, n):

View File

@@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:68e1caf6fc81fc93392bc917a72a48bb149bf03acf1c3408ed3a8433095d94d2
size 210068