Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

cms builders: how can I surface signing errors?

Aperta
#1,987 1 commento 0 reazioni 0 assegnatari Vedi su GitHub

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
5/5
Tempo stimato
Più di una settimana
Idoneità per principianti
35/100
Tipo di issue
Funzionalità
Chiarezza
Abbastanza chiara
Stato di attività
Tranquilla
Stack tecnologico
rust
Ambito
cryptography

Direzione di ricerca

Start with cms/src/builder.rs around lines 400-419, especially the map_err call that drops the Signer::try_sign error. Trace how signing errors are represented and determine what API behavior would preserve useful, secretless context without violating signature::Error's design. Done requires a concrete, reviewed approach for exposing or retaining those errors.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

I'm not sure how I'm supposed to access the underlying error when it gets dropped on line 415:

https://github.com/RustCrypto/formats/blob/cfacd3efed49b28f38e69612221b8af5f33a5cbf/cms/src/builder.rs#L400-L419

For my use case, I'm signing remotely using Google KMS, and so there are numerous failure conditions (e.g. web request failed, couldn't deserialize response body, checksum didn't match), but any useful information I put into my errors in my Signer::try_sign impl get dropped by the map_err above

I understand the concerns about leaking secrets and hence the design of signature::Error - no issues there, but even if I'm wanting to provide useful secretless errors I can't because they get swallowed in internal library code

Thus I'd like to understand why the API was designed like this, and if potentially this could be changed in the future. Naturally this limitation can be worked around one way or another, but it's cumbersome to do so

Lingua principale
Rust
Stelle
338
Fork
188
Merge medio
4g 6h
PR unite (30g)
15

Guida per i contributori

Nessuna guida per i contributori indicizzata per questo repository

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di RustCrypto/formats

Tutte le issue di RustCrypto/formats

Issue simili

Altre issue su Rust

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.