From e906bdb57f0aa010910654a06c60c13195067769 Mon Sep 17 00:00:00 2001 From: Maya Costantini Date: Tue, 27 Jun 2023 13:13:42 +0000 Subject: [PATCH] Remove Sigstore signer subclass Given the API change with SigningContext, it does not make sense anymore to create a wrapper class around AnsibleBaseSignatureSigner --- src/ansible_sign/cli.py | 1 - src/ansible_sign/signing/__init__.py | 1 - src/ansible_sign/signing/sigstore/__init__.py | 2 -- src/ansible_sign/signing/sigstore/signer.py | 19 ------------------- 4 files changed, 23 deletions(-) delete mode 100644 src/ansible_sign/signing/sigstore/signer.py diff --git a/src/ansible_sign/cli.py b/src/ansible_sign/cli.py index fe34919..585ed70 100755 --- a/src/ansible_sign/cli.py +++ b/src/ansible_sign/cli.py @@ -48,7 +48,6 @@ from ansible_sign.signing import GPGSigner from ansible_sign.signing import GPGVerifier from ansible_sign.signing import SigstoreVerifier -from ansible_sign.signing import SigstoreSigner __author__ = "Rick Elrod" diff --git a/src/ansible_sign/signing/__init__.py b/src/ansible_sign/signing/__init__.py index 95670b4..3677ea0 100644 --- a/src/ansible_sign/signing/__init__.py +++ b/src/ansible_sign/signing/__init__.py @@ -13,7 +13,6 @@ from .gpg import GPGSigner # noqa: F401 from .gpg import GPGVerifier # noqa: F401 -from .sigstore import SigstoreSigner # noqa: F401 from .sigstore import SigstoreVerifier # noqa: F401 # from .base import * diff --git a/src/ansible_sign/signing/sigstore/__init__.py b/src/ansible_sign/signing/sigstore/__init__.py index a452b08..c1a38e9 100644 --- a/src/ansible_sign/signing/sigstore/__init__.py +++ b/src/ansible_sign/signing/sigstore/__init__.py @@ -1,6 +1,4 @@ """ This package handles Sigstore signing and validation for Ansible content. """ - -from .signer import SigstoreSigner # noqa: F401 from .verifier import SigstoreVerifier # noqa: F401 diff --git a/src/ansible_sign/signing/sigstore/signer.py b/src/ansible_sign/signing/sigstore/signer.py deleted file mode 100644 index bb276b2..0000000 --- a/src/ansible_sign/signing/sigstore/signer.py +++ /dev/null @@ -1,19 +0,0 @@ -"""This module handles Sigstore signature generation for Ansible content using the sigstore-python library.""" - -from sigstore.sign import Signer as SigstoreBaseSigner -from sigstore.sign import SigningResult as SigstoreBaseSigningResult - -from ansible_sign.signing.base import SignatureSigner as AnsibleBaseSignatureSigner -from ansible_sign.signing.base import SignatureSigningResult as AnsibleBaseSignatureSigningResult - -__author__ = "Maya Costantini" -__copyright__ = "(c) 2022 Red Hat, Inc." -__license__ = "MIT" - - -class SigstoreSigner(SigstoreBaseSigner, AnsibleBaseSignatureSigner): - """A wrapper around the sigstore Signer class.""" - - -class SigstoreSigningResult(SigstoreBaseSigningResult, AnsibleBaseSignatureSigningResult): - """A wrapper class around the sigstore SigningResult class."""