Skip to content

Commit

Permalink
Ignore extra options passed to the sign function if not supported
Browse files Browse the repository at this point in the history
  • Loading branch information
scheibling committed Jun 23, 2022
1 parent 263e268 commit 91ddf34
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/sshkey_tools/fields.py
Original file line number Diff line number Diff line change
Expand Up @@ -1348,7 +1348,7 @@ def from_decode(cls, data: bytes) -> Tuple["RSASignatureField", bytes]:
data,
)

def sign(self, data: bytes, hash_alg: RsaAlgs = RsaAlgs.SHA256) -> None:
def sign(self, data: bytes, hash_alg: RsaAlgs = RsaAlgs.SHA256, **kwargs) -> None:
"""
Signs the provided data with the provided private key
Expand Down Expand Up @@ -1436,7 +1436,7 @@ def from_decode(cls, data: bytes) -> Tuple["DSASignatureField", bytes]:

return cls(private_key=None, signature=signature), data

def sign(self, data: bytes) -> None:
def sign(self, data: bytes, **kwargs) -> None:
"""
Signs the provided data with the provided private key
Expand Down Expand Up @@ -1535,7 +1535,7 @@ def from_decode(cls, data: bytes) -> Tuple["ECDSASignatureField", bytes]:
data,
)

def sign(self, data: bytes) -> None:
def sign(self, data: bytes, **kwargs) -> None:
"""
Signs the provided data with the provided private key
Expand Down Expand Up @@ -1612,7 +1612,7 @@ def from_decode(cls, data: bytes) -> Tuple["ED25519SignatureField", bytes]:

return cls(private_key=None, signature=signature), data

def sign(self, data: bytes) -> None:
def sign(self, data: bytes, **kwargs) -> None:
"""
Signs the provided data with the provided private key
Expand Down

0 comments on commit 91ddf34

Please sign in to comment.