Skip to content

docs: add XML documentation for CMS SignedData stream generator (Batch 13a)#687

Open
KonradSop wants to merge 1 commit into
bcgit:masterfrom
KonradSop:feature/cms-signed-stream-docs
Open

docs: add XML documentation for CMS SignedData stream generator (Batch 13a)#687
KonradSop wants to merge 1 commit into
bcgit:masterfrom
KonradSop:feature/cms-signed-stream-docs

Conversation

@KonradSop

Copy link
Copy Markdown
Contributor

Description

Adds XML documentation to CmsSignedDataStreamGenerator — the streaming entry point for creating CMS SignedData (PKCS#7 signed-data) messages, the counterpart to CmsSignedDataGenerator (Batch 12a-3, #686):

  • Class summary — describes the streaming Open/write/close workflow, the relationship to CmsSignedGenerator, and a usage example.
  • Stream-handling note — closing the returned stream finalizes the CMS structure (certificates, CRLs, signer infos) but does not close the underlying stream; callers close it separately.
  • Constructors — default and SecureRandom overload.
  • SetBufferSize — documents the buffer length for the encapsulated content OCTET STRING segments.
  • AddDigests overloads — both params string[] and IEnumerable<string>.
  • AddSigner overloads — all eight families documented (certificate vs subject key id; default attributes vs AttributeTable vs CmsAttributeTableGenerator; inferred vs explicit encryption OID).
  • Open overloads — documents encapsulated vs non-encapsulated content, explicit content type OID, and the optional data-output copy stream; <exception> tags on the core overload where it validates the supplied streams.

Legacy /** block comments converted to XML.

Key Accomplishments

  • CMS streaming discoverability: IDE tooltips now cover the full public stream-generator surface used with AddCertificates / AddCrls from the base class.
  • Accurate exception contracts: ArgumentNullException / ArgumentException documented only on the Open overload that validates its stream arguments.
  • Consistent style: matches Batch 12a documentation conventions (1 → 22 <summary> blocks).
  • No overlap with merged work: single file, disjoint from CmsSignedDataGenerator (docs: add XML documentation for CMS SignedData generator (Batch 12a-3) #686).

Verification

  • Build Status: dotnet build crypto/src/BouncyCastle.Crypto.csproj -c Release — 0 errors, no new warnings.
  • Scope: Documentation-only; no behavioural or signature changes.

Checklist before requesting a review

  • I have performed a self-review of my code
  • I have kept the patch limited to only change the parts related to the patch
  • This change requires a documentation update

See also Contributing Guidelines.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant