Smrt.SupportBundle¶
Assembly:
Smrt.SupportBundle
Namespace: Smrt.SupportBundle¶
ISupportBundleExporter¶
Contract for building sanitized SmrtHub support bundles that follow Operational Data Policy paths and logging rules.
Methods¶
ExportAsync(Smrt.SupportBundle.Models.ExportOptions options, IProgress progress, Threading.CancellationToken ct)¶
Builds a sanitized ZIP bundle using the supplied options and emits progress aligned with the exporter pipeline.
Parameters
options— Scope, filtering, sanitization, and output preferences; must specify canonical destinations per Operational Data Policy.progress— Optional progress reporter receiving coarse-grained stage updates and current artifact names.ct— Cancellation token that aborts discovery, sanitization, and packaging when triggered.
Returns: An export result describing the generated bundle path, manifest location, review report, hashes, and soft warnings.
SupportBundleExporter¶
Default implementation of Smrt.SupportBundle.ISupportBundleExporter that orchestrates planning, sanitization, manifest/report generation, and packaging.
Methods¶
ExportAsync(Smrt.SupportBundle.Models.ExportOptions options, IProgress progress, Threading.CancellationToken ct)¶
Builds a sanitized support bundle using the provided options and writes progress updates as stages complete.
Parameters
options— Controls scope, filters, sanitization rules, and output location for the bundle.progress— Optional progress reporter invoked with coarse-grained stages and file names.ct— Cancellation token for aborting the export safely; throwsSystem.OperationCanceledExceptionwhen triggered.
Returns: An Smrt.SupportBundle.Models.ExportResult describing the generated bundle, manifest, review report, hashes, and soft failures.
Exceptions
System.ArgumentException— Thrown when required fields onoptionsare missing or invalid.System.OperationCanceledException— Thrown ifctis canceled while the export is running.System.Exception— Propagates unexpected failures from discovery, sanitization, packaging, or file IO.
SupportBundleExporter()¶
Creates a new exporter instance wired with the default planning, sanitization, packaging, and reporting components.
Namespace: Smrt.SupportBundle.Compliance¶
ComplianceReportArtifact¶
Important evidence artifacts (logs, signed snapshots) included in the compliance bundle.
Propertys¶
Category¶
Category derived from the Support Bundle manifest entry.
Path¶
Relative path of the artifact inside the compliance bundle.
Sha256¶
SHA-256 hash of the artifact for tamper detection.
SizeBytes¶
Size of the artifact in bytes.
ComplianceReportGenerator¶
Provides a turnkey workflow for building compliance-focused bundles with immutable hashes and retention summaries.
Methods¶
ComplianceReportGenerator()¶
Creates a generator that wires up the default Smrt.SupportBundle.SupportBundleExporter.
ComplianceReportGenerator(Smrt.SupportBundle.ISupportBundleExporter param0, Smrt.SupportBundle.Internal.IHashComputer param1)¶
Allows dependency injection/testing with custom exporter + hash implementations.
GenerateAsync(Smrt.SupportBundle.Compliance.ComplianceReportOptions param0, IProgress param1, Threading.CancellationToken param2)¶
Generates a signed compliance bundle plus JSON summary.
ComplianceReportOptions¶
Options controlling how compliance reports are generated.
Propertys¶
FileNamePrefix¶
File name prefix for the compliance bundle. Defaults to smrthub-compliance.
Modules¶
Optional set of additional modules to include (merged with the canonical compliance modules).
OutputDirectory¶
Destination directory for the generated bundle and summary artifacts. Required.
RelativeWindowHours¶
Relative window (in hours) used to scope log collection. Defaults to the last 168 hours (7 days).
Severities¶
Optional severity filter overrides (defaults to Warning, Error, Fatal).
ComplianceReportResult¶
Result of a compliance report generation run.
Propertys¶
BundleHashPath¶
Path to the sidecar hash file (.sha256) written next to the bundle.
BundlePath¶
Full path to the generated compliance bundle ZIP file.
BundleSha256¶
SHA-256 of the bundle for audit trails.
Reports¶
Persisted review reports copied beside the bundle, keyed by report kind.
Summary¶
Strongly typed representation of the JSON summary.
SummaryPath¶
Path to the JSON summary describing evidence that landed in the bundle.
ComplianceReportSummary¶
Human and machine readable view of the compliance evidence emitted by the bundle run.
Propertys¶
Artifacts¶
Collection of important files (logs, signatures) emitted in the bundle.
BundleFile¶
File name of the generated compliance bundle ZIP.
BundleSha256¶
SHA-256 hash of the compliance bundle ZIP.
GeneratedUtc¶
UTC timestamp recorded when the compliance run completed.
ManifestSha256¶
SHA-256 hash of the manifest contained within the bundle.
Modules¶
Modules whose logs were included in the bundle.
Retention¶
Retention evidence summary parsed from the Support Bundle manifest.
Severities¶
Log severities included in the compliance report run.
Status¶
Overall health indicator derived from retention evidence (healthy/warning/error/unknown).
StorageGuard¶
Latest Storage Guard telemetry snapshot highlighting ACL and quota posture.
WindowEndUtc¶
End timestamp for the evidence collection window captured in the bundle.
WindowStartUtc¶
Start timestamp for the evidence collection window captured in the bundle.
ComplianceRetentionProviderSummary¶
Provider-level retention compliance snapshot.
Propertys¶
FreeSpacePercent¶
Free space percentage reported by Storage Guard for the provider path.
ItemsOutsidePolicy¶
Number of items outside the configured retention policy.
ItemsWithinPolicy¶
Number of items currently within policy for the provider.
LegalHoldMatches¶
Count of files or items that match an active legal hold.
Notes¶
Optional free-form notes supplied by the verifier.
Provider¶
Provider slug the summary applies to (e.g., hub-window, storage-guard).
Status¶
Provider-specific retention status string.
ComplianceRetentionSummary¶
Summary of the latest retention verification exported with the bundle.
Propertys¶
ErrorCount¶
Count of retention errors detected during verification.
GeneratedUtc¶
UTC timestamp of the retention verification snapshot.
KeyIds¶
Key identifiers used when attempting verification.
LegalHoldsSha256¶
SHA-256 hash of the legal holds JSON file.
PoliciesSha256¶
SHA-256 hash of the retention policy JSON file.
Providers¶
Provider-specific retention summaries included with the verification snapshot.
SignatureError¶
Error captured during signature verification, if any.
SignatureIncluded¶
Indicates whether the retention snapshot signature was present and validated.
SignatureIssuedAtUtc¶
UTC timestamp of the issued signature document, when present.
SignatureVerified¶
Indicates whether the signature could be validated with available trust roots.
SignatureVerifiedAtUtc¶
UTC timestamp when the signature was validated during bundle creation.
VerificationId¶
Retention verification identifier reported by the Support Bundle.
WarningCount¶
Count of retention warnings detected during verification.
ComplianceStorageGuardAclInsight¶
ACL inspection details included with the Storage Guard snapshot.
Propertys¶
Identifier¶
Stable identifier used in Storage Guard issue codes.
InheritsFromParent¶
Indicates whether the directory inherits ACLs from its parent.
Message¶
Additional context about the ACL state.
MissingPrincipals¶
Principals missing from the ACL.
Status¶
Outcome of the ACL inspection.
Target¶
Friendly name for the inspected directory.
ComplianceStorageGuardIssue¶
Issue surfaced by Storage Guard when evaluating a host.
Propertys¶
Code¶
Stable machine-readable code emitted by the guard.
Message¶
Human-readable message describing the issue.
Severity¶
Severity classification for the issue.
ComplianceStorageGuardQuotaForecast¶
Storage quota risk forecast mapped into the compliance summary.
Propertys¶
AvailableBytes¶
Current free space in bytes.
CriticalThresholdBytes¶
Critical threshold applied during forecasting.
FreePercent¶
Percentage of free space remaining, when known.
Message¶
Explanation of the reported risk.
Risk¶
Risk indicator reported by Storage Guard.
TotalBytes¶
Total bytes available on the monitored volume.
WarningThresholdBytes¶
Warning threshold applied during forecasting.
ComplianceStorageGuardSummary¶
Storage Guard telemetry distilled for compliance consumers.
Propertys¶
AclDriftCount¶
Total number of ACL insights flagged as non-healthy.
AclInsights¶
ACL inspection results for evidence directories.
CapturedUtc¶
Capture timestamp of the snapshot bundled in the report.
Issues¶
Issues raised by Storage Guard during the snapshot.
QuotaForecast¶
Quota forecast derived from the SmrtSpace volume.
RetentionConfigHash¶
SHA-256 hash of the retention configuration captured with the snapshot.
SmrtSpaceName¶
Friendly SmrtSpace name detected on the host.
SmrtSpaceRoot¶
Absolute path for the SmrtSpace root.
IComplianceReportGenerator¶
Abstraction for generating compliance reports. Enables easier unit testing of CLI callers.
Methods¶
GenerateAsync(Smrt.SupportBundle.Compliance.ComplianceReportOptions options, IProgress progress, Threading.CancellationToken ct)¶
Generates a compliance report bundle and summary artifacts.
Parameters
options— Controls export destinations, time windows, and filtering.progress— Optional export progress callback used by CLI callers.ct— Cancellation token for long-running bundle exports.
Returns: Detailed result including bundle path, hash, and JSON summary.
Namespace: Smrt.SupportBundle.Internal¶
IArtifactProvider¶
Discovers artifacts for a specific Operational Data Policy category (logs, diagnostics, system info, or config).
Methods¶
Discover(Smrt.SupportBundle.Models.ExportOptions options)¶
Discovers artifacts matching the provided options and yields bundle-relative metadata that downstream sanitizers can process.
Parameters
options— Caller-supplied export scope, including modules, categories, time windows, and sanitization flags.
Returns: An enumerable sequence of planned artifacts with canonical bundle-relative paths.
Propertys¶
Category¶
Category of artifacts provided.
IExportPlanner¶
Plans the export operation by discovering what artifacts will be included.
Methods¶
PlanAsync(Smrt.SupportBundle.Models.ExportOptions options, Threading.CancellationToken ct)¶
Plans the export operation by invoking all registered artifact providers and collating their results.
Parameters
options— Export scope, filters, and sanitization flags that control provider discovery.ct— Cancellation token that aborts discovery before any filesystem work if triggered.
Returns: A plan containing discovered artifacts and non-fatal warnings for downstream stages.
IHashComputer¶
Computes SHA-256 hashes for files.
Methods¶
ComputeSha256Async(IO.Stream stream, Threading.CancellationToken ct)¶
Computes the SHA-256 hash of the supplied stream without consuming ownership of the stream.
Parameters
stream— Readable stream positioned at the start of the content to hash.ct— Cancellation token that aborts hashing during long-running operations.
Returns: Hex-encoded SHA-256 digest.
IPackager¶
Creates a ZIP package from sanitized artifacts.
Methods¶
CreateZipAsync(Collections.Generic.IEnumerable artifacts, Smrt.SupportBundle.Internal.PackageOptions options, Threading.CancellationToken ct)¶
Creates a ZIP bundle from sanitized artifacts.
Parameters
artifacts— Sanitized artifacts staged for packaging with bundle-relative metadata.options— Packaging options such as output directory, deterministic ordering, and size caps.ct— Cancellation token that aborts packaging before writing the ZIP.
Returns: Packaging result containing bundle location, staging directory, total size, and soft errors.
IReviewReportBuilder¶
Builds a human-readable HTML review report.
Methods¶
BuildAsync(Smrt.SupportBundle.Internal.ReportBuildContext context, Threading.CancellationToken ct)¶
Builds the requested HTML report variants for a bundle export run.
Parameters
context— Context describing the manifest, redactions, staging root, and target reports.ct— Cancellation token for aborting report generation before file IO completes.
ISanitizer¶
Sanitizes artifacts by redacting sensitive information.
Methods¶
SanitizeAsync(Smrt.SupportBundle.Internal.Models.PlannedArtifact artifact, Smrt.SupportBundle.Internal.Models.SanitizationContext context, Threading.CancellationToken ct)¶
Sanitizes an artifact asynchronously.
Parameters
artifact— Planned artifact metadata including source path and bundle-relative destination.context— Sanitization context (data classes, staging directory, unredacted preview settings).ct— Cancellation token that aborts sanitization during long-running operations.
Returns: A sanitized artifact that references the staged, redacted file.
PackageOptions¶
Options for packaging.
Propertys¶
DeterministicZip¶
When true, ensures sorted entries and fixed timestamps for deterministic output.
FileNamePrefix¶
File name prefix applied to the generated ZIP, defaulting to smrthub-support.
MaxBundleSizeMB¶
Soft size cap in megabytes; packaging logs a warning when exceeded but still completes.
OutputDirectory¶
Directory where the final ZIP will be written; must already follow Operational Data Policy guidance.
StagingDirectory¶
Optional staging directory that already contains sanitized artifacts; if null a temporary directory is created.
ZipPassword¶
Optional password for ZIP encryption (reserved for future implementation).
PackageResult¶
Result of packaging.
Propertys¶
BundlePath¶
Full path to the generated bundle ZIP.
Errors¶
Non-fatal errors encountered while copying artifacts or compressing the bundle.
StagingDirectory¶
Staging directory used during packaging; callers may delete it after successful export.
TotalSizeBytes¶
Total size in bytes of the packaged bundle.
PlanResult¶
Result of export planning.
Propertys¶
Artifacts¶
Artifacts selected for inclusion in the bundle, expressed with source and bundle-relative metadata.
Warnings¶
Non-fatal warnings emitted by providers (missing directories, skipped files, etc.).
ReportBuildContext¶
Encapsulates the data required to build review reports.
ReportBuildResult¶
Result describing all generated report paths.
Namespace: Smrt.SupportBundle.Internal.Models¶
Manifest¶
Manifest included in every support bundle with metadata and file list.
PlannedArtifact¶
Represents an artifact that has been planned for inclusion in the bundle.
SanitizationContext¶
Context for sanitization operations.
SanitizedArtifact¶
Represents an artifact that has been sanitized and is ready for packaging.
Namespace: Smrt.SupportBundle.Internal.Packaging¶
ManifestBuilder¶
Builds the bundle manifest with metadata and file listing.
Methods¶
BuildManifestAsync(string stagingDirectory, Smrt.SupportBundle.Models.ExportOptions options, Smrt.SupportBundle.Models.RedactionSummary redactionSummary, Collections.Generic.List errors, Threading.CancellationToken ct)¶
Enumerates staged artifacts and constructs the manifest with hashes, filters, host info, and redaction summaries.
Parameters
stagingDirectory— Directory containing sanitized artifacts staged for packaging.options— Original export options used to populate filter metadata.redactionSummary— Aggregate redaction counts grouped by data class.errors— Collection of soft warnings captured during earlier stages; appended to the manifest.ct— Cancellation token for aborting manifest generation.
Returns: Manifest describing bundle contents and metadata.
WriteManifestAsync(Smrt.SupportBundle.Internal.Models.Manifest manifest, string outputPath, Threading.CancellationToken ct)¶
Serializes the manifest to disk using camelCase JSON suitable for bundle consumption.
Parameters
manifest— Manifest produced bySmrt.SupportBundle.Internal.Packaging.ManifestBuilder.BuildManifestAsync(System.String,Smrt.SupportBundle.Models.ExportOptions,Smrt.SupportBundle.Models.RedactionSummary,System.Collections.Generic.List{System.String},System.Threading.CancellationToken).outputPath— Destination path formanifest.jsoninside the staging directory.ct— Cancellation token guarding file IO.
Returns: A task that completes when the manifest file has been written.
Packager¶
Creates ZIP packages from sanitized artifacts.
Methods¶
CreateZipAsync(Collections.Generic.IEnumerable param0, Smrt.SupportBundle.Internal.PackageOptions param1, Threading.CancellationToken param2)¶
No summary provided.
Namespace: Smrt.SupportBundle.Internal.Planning¶
ExportPlanner¶
Plans the export operation by discovering artifacts from all providers.
Methods¶
PlanAsync(Smrt.SupportBundle.Models.ExportOptions param0, Threading.CancellationToken param1)¶
No summary provided.
Namespace: Smrt.SupportBundle.Internal.Providers¶
ConfigSnapshotProvider¶
Provides a sanitized snapshot of application configuration.
DiagnosticsProvider¶
Discovers diagnostic artifacts (crash dumps, diagnostic reports, etc.).
Methods¶
GetDiagnosticsRoot()¶
Resolves the diagnostics root under %AppData%/SmrtHub/Diagnostics used by crash dump and report providers.
LogsProvider¶
Discovers and filters log files from Smrt.Logging's output directories.
Methods¶
GetLogRoot()¶
Resolves the canonical structured log root under %LocalAppData%/SmrtHub/Logs per the Operational Data Policy.
GetTimeWindow(Smrt.SupportBundle.Models.ExportOptions param0)¶
Calculates the effective time window by combining absolute and relative filters.
RetentionEvidenceProvider¶
Packages retention policies, legal holds, verification artifacts, and provider automation logs.
StorageGuardProvider¶
Emits the most recent signed Storage Guard snapshot, its signature, and a verification report for cryptographic proof.
SystemInfoProvider¶
Provides system information snapshot (OS, memory, disk, etc.).
Namespace: Smrt.SupportBundle.Internal.Reporting¶
ProviderEvidenceFile¶
Represents a provider automation artifact copied into the bundle.
RetentionArtifactData¶
Aggregates retention artifacts copied into the bundle so report composers can surface richer context.
Propertys¶
Configuration¶
Loaded retention configuration describing policies and legal holds.
ConfigurationWarning¶
Notes when configuration parsing fell back to a non-validated path.
Health¶
Rolling health snapshot emitted by retention automation.
ProviderFiles¶
Provider automation logs that were bundled under system-info/retention/providers.
RetentionArtifactLoader¶
Helper that loads retention artifacts from the staging directory for use during report rendering.
ReviewReportBuilder¶
Builds branded overview reports for support, legal, and compliance stakeholders.
Namespace: Smrt.SupportBundle.Internal.Sanitization¶
RedactionRule¶
Represents a redaction rule with pattern and replacement.
Sanitizer¶
Sanitizes artifacts by applying redaction rules to remove sensitive information.
Methods¶
SafeCopyFile(string param0, string param1)¶
Safely copies a file using FileShare.ReadWrite to handle files that may be actively written by other processes.
SanitizeAsync(Smrt.SupportBundle.Internal.Models.PlannedArtifact param0, Smrt.SupportBundle.Internal.Models.SanitizationContext param1, Threading.CancellationToken param2)¶
No summary provided.
Namespace: Smrt.SupportBundle.Internal.Utilities¶
HashComputer¶
Computes SHA-256 hashes for files and streams.
Methods¶
ComputeSha256Async(IO.Stream param0, Threading.CancellationToken param1)¶
No summary provided.
Namespace: Smrt.SupportBundle.Models¶
DataClassFlags¶
Data classes that control what gets redacted or included.
Fields¶
All¶
Shortcut that enables redaction for all known data classes.
Credentials¶
Secrets that grant access to resources, for example passwords and API keys.
HostInfo¶
Host hardware and OS fingerprints that may be considered sensitive.
NetInfo¶
Network information (addresses, ports) that could expose topology.
None¶
No sensitive classes are redacted or tracked.
PII¶
Personally identifiable information such as names, emails, and addresses.
Paths¶
File system or network paths that could reveal install locations.
Tokens¶
Tokenized secrets such as JWTs that should never leave the host.
ExportCategories¶
Categories of artifacts that can be included in the support bundle.
Fields¶
All¶
Shortcut that combines all artifact categories.
Config¶
Include configuration snapshots and policy files.
Diagnostics¶
Include diagnostic captures such as traces, dumps, and profiler outputs.
Logs¶
Include text and JSON log files emitted by SmrtHub components.
None¶
No artifacts are exported.
SystemInfo¶
Include machine and environment details gathered during export.
ExportOptions¶
Options controlling what data to include in the support bundle and how to package it.
Propertys¶
Categories¶
Categories of artifacts to include in the bundle.
DataClasses¶
Data classes that control sanitization behavior.
DeterministicZip¶
If true, produce deterministic ZIPs (sorted entries, fixed timestamps). Default: true.
FileNamePrefix¶
File name prefix for the bundle. Default: "smrthub-support".
IncludeHtmlLog¶
If true, include any available HTML log viewer files (e.g., component-log.html). Default: false.
IncludeRawUnredactedPreview¶
If true, include a raw unredacted preview (DANGEROUS - for debugging only).
IncludeRetentionWindowDays¶
If set, pre-filter logs to the last N days during discovery.
InjectedConfiguration¶
Optional configuration snapshot to include (e.g., from IConfiguration).
MaxBundleSizeMB¶
Soft cap on bundle size in MB. If exceeded, warn but continue.
Modules¶
Component/module names to include. Empty means all.
OutputDirectory¶
Output directory for the bundle. Required.
PersistReviewReports¶
When true, copies generated review reports to the output directory so they remain available after packaging.
RelativeWindowHours¶
If set, overrides TimeStartUtc/TimeEndUtc with a relative window (e.g., last 24 hours).
ReportKinds¶
Report variants to emit alongside the bundle. Defaults to all supported report kinds.
Severities¶
Log severities to include. Empty means all.
SignManifest¶
If true, write a manifest.sig (SHA-256 of manifest.json) into the bundle. Default: true.
SignWithCertThumbprint¶
Optional certificate thumbprint for signing (not implemented initially).
TimeEndUtc¶
End of the time window (UTC). If null, defaults to Now.
TimeStartUtc¶
Start of the time window (UTC). If null, no lower bound.
ZipPassword¶
Optional password for ZIP encryption (not implemented initially).
ExportProgress¶
Progress information for support bundle export operations.
Propertys¶
CurrentItem¶
Current item being processed (optional).
Percent¶
Percentage complete (0-100).
Stage¶
Current stage of the export process.
ExportResult¶
Result of a support bundle export operation.
Propertys¶
BundlePath¶
Full path to the generated bundle ZIP file.
Errors¶
Non-fatal errors encountered during export.
Hashes¶
SHA-256 hashes of all files in the bundle (relative path -> hash).
ManifestPath¶
Full path to the manifest.json file (inside staging, before zipping).
RedactionSummary¶
Summary of redaction operations performed.
ReportPaths¶
All generated HTML report variants keyed by report kind.
ReviewReportPath¶
Full path to the legacy support review HTML (inside staging).
TotalFiles¶
Total number of files included in the bundle.
TotalSizeBytes¶
Total size of the bundle in bytes.
RedactionSummary¶
Summary of redaction operations performed during export.
Propertys¶
ByClass¶
Redaction counts by data class (PII, Credentials, Tokens, Paths, etc.).
ByRule¶
Redaction counts by rule name.
Samples¶
Safe anonymized preview samples of redactions.
ReportKind¶
Identifies the HTML report variants emitted with a support bundle.
Fields¶
Compliance¶
Compliance-focused view highlighting hashes and guard posture.
Legal¶
Retention, legal hold, and signature evidence summary.
Support¶
Operator-facing review summarizing bundle scope and redactions.
SmrtSupportPreset¶
SmrtSupport bundle presets exposed through HubWindow diagnostics.
Fields¶
Assist¶
Operator-focused assist preset (broad capture of the last 24 hours).
Compliance¶
Compliance preset – wraps the compliance generator with hardened settings.
Legal¶
Legal evidence preset – scoped to retention and supervisory evidence.
SmrtSupportPresetDefinition¶
Describes how a SmrtSupport preset should be executed.
Propertys¶
ComplianceOptions¶
Compliance generator options when the preset uses Smrt.SupportBundle.Compliance.ComplianceReportGenerator.
DisplayName¶
Human-readable label used in logs/UI.
ExportOptions¶
Exporter options when the preset uses Smrt.SupportBundle.SupportBundleExporter.
Preset¶
Identifies the preset.
PrimaryReport¶
Primary report to auto-launch for the preset.
UsesComplianceGenerator¶
Indicates whether the preset flows through the compliance generator.
SmrtSupportPresets¶
Factory helpers for SmrtSupport presets.
Methods¶
Create(Smrt.SupportBundle.Models.SmrtSupportPreset param0, string param1)¶
Creates a preset definition bound to the specified output directory.