Skip to content

Commit

Permalink
Rename Envelope sign and verify methods
Browse files Browse the repository at this point in the history
sign is renamed to create_sig and verify is renamed to verify_sigs,
so it does not clashes with other methods of current signature
wrappers.

This has to be done to avoid any breaking change while integrating
DSSE in in-toto and tuf projects.

Signed-off-by: Pradyumna Krishna <git@onpy.in>
  • Loading branch information
PradyumnaKrishna committed Sep 5, 2022
1 parent 70074f5 commit f418b3f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions securesystemslib/metadata.py
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ def pae(self) -> bytes:
self.payload,
)

def sign(self, signer: Signer) -> Signature:
def create_sig(self, signer: Signer) -> Signature:
"""Sign the payload and create the signature.
Arguments:
Expand All @@ -126,7 +126,7 @@ def sign(self, signer: Signer) -> Signature:

return signature

def verify(self, keys: List[Key], threshold: int) -> Dict[str, Key]:
def verify_sigs(self, keys: List[Key], threshold: int) -> Dict[str, Key]:
"""Verify the payload with the provided Keys.
Arguments:
Expand Down

0 comments on commit f418b3f

Please sign in to comment.