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

der: add `ClarifyWriter`

Aperta
#1,835 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à
Ferma
Stack tecnologico
rust
Ambito
cryptography

Direzione di ricerca

Inizia individuando il ClarifyWriter esistente dietro la funzionalità clarify e gli entry point di Encode. Confronta il suo comportamento attuale di pretty-printing con l’output proposto di to_hex_clarify e l’esempio PKCS#15 nell’issue. Il lavoro è completo quando l’output codificato annota i tag e i tipi DER come mostrato.

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

Descrizione

I have a pretty well-written #[cfg(feature = "clarify")] - gated writer that pretty-prints DER.

Proposal: To add Encode::to_hex_clarify, that annotates tags and types.

Example of PKCS#15 ^1:

30 3E <!-- tag: SEQUENCE len: 62 type: AuthenticationObjectChoice -->
	<!-- CHOICE: Pwd -->
	<!-- field: common_object_attributes -->
	30 1B <!-- tag: SEQUENCE len: 27 type: CommonObjectAttributes -->
		<!-- field: label -->
		0C 12 <!-- tag: UTF8String len: 18 type: String -->
			41 75 74 68 65 6E 74 69 63 61 74 69 6F 6E 20 50 
			49 4E <!--  "Authentication PIN" -->
		<!-- end: String -->
		<!-- field: flags -->
		03 02 <!-- tag: BIT STRING type: CommonObjectFlags -->
			06 
			C0 
		<!-- field: auth_id -->
		04 01 <!-- tag: OCTET STRING type: OctetString -->
			05 
		<!-- field: user_consent -->
		<!-- field: access_control_rules -->
		<!-- field: current_lcs -->
	<!-- end: CommonObjectAttributes -->
	<!-- field: class_attributes -->
	30 03 <!-- tag: SEQUENCE type: CommonAuthenticationObjectAttributes -->
		<!-- field: auth_id -->
		04 01 <!-- tag: OCTET STRING type: OctetString -->
			01 
		<!-- field: auth_reference -->
		<!-- field: se_identifier -->
	<!-- field: subclass_attributes -->
	<!-- field: type_attributes -->
	A1 1A <!-- tag: CONTEXT-SPECIFIC [1] (constructed) len: 26 
                          type: ContextSpecificExplicit<PasswordAttributes> -->
		30 18 <!-- tag: SEQUENCE len: 24 type: PasswordAttributes -->
			<!-- field: pwd_flags -->
			03 03 <!-- tag: BIT STRING type: PasswordFlags -->
				04 
				48 10 
			<!-- field: pwd_type -->
			0A 01 <!-- tag: ENUMERATED type: PasswordType -->
				01 
			<!-- field: min_length -->
			02 01 <!-- tag: INTEGER type: IntegerInRange -->
				04 
			<!-- field: stored_length -->
			02 01 <!-- tag: INTEGER type: IntegerInRange -->
				04 
			<!-- field: max_length -->
			02 01 <!-- tag: INTEGER type: IntegerInRange -->
				04 
			<!-- field: pwd_reference -->
			80 01 <!-- tag: CONTEXT-SPECIFIC [0] (primitive) type: Reference -->
				01 
			<!-- field: pad_char -->
			<!-- field: last_password_change -->
			<!-- field: path -->
			30 02 <!-- tag: SEQUENCE type: Path -->
				<!-- field: efid_or_tag_choice -->
				04 00 <!-- tag: OCTET STRING type: EfidOrTagChoice -->
					<!-- CHOICE: EfidOrPath -->
					
				<!-- field: index -->
				<!-- field: length -->
			<!-- field: verif_data_history_length -->
			<!-- field: cio_security_id -->
		<!-- end: ContextSpecificExplicit<PasswordAttributes> -->
	<!-- end: PasswordAttributes -->
<!-- end: AuthenticationObjectChoice -->
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.