Skip to content

Commit

Permalink
fix(signing): remove duplicate timezone information from SigningTime (
Browse files Browse the repository at this point in the history
#266)

Fixes #265

Signed-off-by: Sergei Shishov <sshishov.sshishov@gmail.com>
  • Loading branch information
sshishov authored Sep 11, 2024
1 parent efd473f commit 5abbcc1
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions signxml/xades/xades.py
Original file line number Diff line number Diff line change
Expand Up @@ -187,8 +187,7 @@ def _add_reference_to_signed_info(self, sig_root, node_to_reference, **attrs):
def add_signing_time(self, signed_signature_properties, sig_root, signing_settings: SigningSettings):
signing_time = SubElement(signed_signature_properties, xades_tag("SigningTime"), nsmap=self.namespaces)
# TODO: make configurable
utc_iso_ts = datetime.datetime.now(datetime.timezone.utc).isoformat(timespec="seconds")
signing_time.text = f"{utc_iso_ts}+00:00"
signing_time.text = datetime.datetime.now(datetime.timezone.utc).isoformat(timespec="seconds")

def add_signing_certificate(self, signed_signature_properties, sig_root, signing_settings: SigningSettings):
# TODO: check if we need to support SigningCertificate
Expand Down

0 comments on commit 5abbcc1

Please sign in to comment.