Skip to content

Commit ec7f79a

Browse files
committed
fix more API errors
1 parent decb2cb commit ec7f79a

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

sigstore/dsse/__init__.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818

1919
from __future__ import annotations
2020

21+
import base64
2122
import logging
2223
from typing import Any, Literal, Optional
2324

@@ -270,9 +271,9 @@ def _sign(key: ec.EllipticCurvePrivateKey, stmt: Statement) -> Envelope:
270271
signature = key.sign(pae, ec.ECDSA(hashes.SHA256()))
271272
return Envelope(
272273
_Envelope(
273-
payload=stmt._contents,
274+
payload=base64.b64encode(stmt._contents),
274275
payload_type=Envelope._TYPE,
275-
signatures=[_Signature(sig=signature)],
276+
signatures=[_Signature(sig=base64.b64encode(signature))],
276277
)
277278
)
278279

sigstore/sign.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -188,7 +188,7 @@ def _finalize_sign(
188188

189189
# Submit the proposed entry to the transparency log
190190
entry = self._signing_ctx._rekor.create_entry(proposed_entry)
191-
_logger.debug(f"Transparency log entry created with index: {entry.log_index}")
191+
_logger.debug(f"Transparency log entry created with index: {entry._inner.log_index}")
192192

193193
return Bundle._from_parts(cert, content, entry, signed_timestamp)
194194

0 commit comments

Comments
 (0)