Skip to content

[release/13.4] Bump StreamJsonRpc to 2.25.29 to clear MessagePack NU1903#18204

Merged
joperezr merged 8 commits into
release/13.4from
backport/pr-18155-to-release/13.4
Jun 16, 2026
Merged

[release/13.4] Bump StreamJsonRpc to 2.25.29 to clear MessagePack NU1903#18204
joperezr merged 8 commits into
release/13.4from
backport/pr-18155-to-release/13.4

Conversation

@aspire-repo-bot

@aspire-repo-bot aspire-repo-bot Bot commented Jun 15, 2026

Copy link
Copy Markdown
Contributor

Backport of #18155 to release/13.4

/cc @mitchdenny

Customer Impact

Customers running dotnet new aspire-starter see an NU1903 warning that the transitive MessagePack 2.5.192 package has a known high severity vulnerability (GHSA-hv8m-jj95-wg3x / CVE-2026-48109). Aspire is not directly exposed (no MessagePack code paths reached at runtime; JsonRpc traffic uses System.Text.Json over local Unix domain sockets), but the warning is surfaced to every Aspire user on package restore and is noisy enough that customers think they need to act on it.

Testing

Validated by the full CI suite on #18155, including the template tests (templates-* jobs across xUnit / NUnit / MSTest / "new up and build" matrices) which exercise dotnet new aspire-starter and build the generated AppHost projects under both the current and previous SDKs. The NU1903 warning is gone in the generated projects after the bump.

Risk

Very low. The change is a transitive dependency bump in Aspire.Hosting (StreamJsonRpc 2.22.23 -> 2.25.29) plus a Directory.Packages.props version update. StreamJsonRpc public surface remained backwards compatible and the analyzer-Roslyn-compatibility regression that bit 2.25.25-2.25.28 is fixed in 2.25.29 (vs-streamjsonrpc#1463 / #1399), so no MSBuild workaround is required.

Regression?

No. The MessagePack advisory was published after 13.4 snapped; this is the first cut at it.

mitchdenny and others added 7 commits June 15, 2026 02:55
The aspire-starter template was emitting NU1903 for transitive
MessagePack 2.5.192 (GHSA-hv8m-jj95-wg3x / CVE-2026-48109) because
the shared StreamJsonRpc 2.22.23 dependency pulled it in. Updating
StreamJsonRpc to 2.25.25 brings MessagePack 2.5.198, outside the
advisory's vulnerable range.

The advisory affects only MessagePack's LZ4 decompression path. We
do not use MessagePackFormatter anywhere - all StreamJsonRpc sites
use SystemTextJsonFormatter - and our JSON-RPC transports are local
UDS under the user's home directory, so the underlying vulnerability
was not reachable. This change is warning hygiene.

Fixes #18153

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
StreamJsonRpc 2.25.25 still declares a transitive dep on
MessagePack 2.5.198, which is inside the advisory's vulnerable
range (< 2.5.302). Add a direct PackageReference on MessagePack
to Aspire.Hosting so consumers (including generated AppHosts from
'aspire new aspire-starter') restore the patched version, and
NU1903 is no longer emitted.

This can be removed once StreamJsonRpc ships a release that
depends on MessagePack >= 2.5.302.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
StreamJsonRpc 2.25.25 ships analyzers built against Roslyn 4.14, which
breaks template tests that build generated AppHosts with the .NET 8 SDK
(CSC error CS9057). The MessagePack 2.5.302 direct pin in Aspire.Hosting
already overrides StreamJsonRpc 2.22.23's transitive MessagePack 2.5.192
in consumer projects, so the GHSA-hv8m-jj95-wg3x warning is silenced
without needing the StreamJsonRpc bump.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
StreamJsonRpc 2.25.28 brings MessagePack 2.5.302 transitively, which is
above the GHSA-hv8m-jj95-wg3x / CVE-2026-48109 vulnerable range. This
lets us drop the direct MessagePack PackageReference (and PackageVersion)
we added earlier as a workaround.

StreamJsonRpc 2.25.x ships an analyzer built against Roslyn 4.14, which
is newer than the Roslyn 4.11 in the .NET 8 SDK used by template tests
to build generated AppHost projects (would trigger CSC error CS9057). We
don't use the StreamJsonRpc analyzers anywhere in this assembly, so
ExcludeAssets="analyzers" skips them. NuGet bakes the exclusion into
the Aspire.Hosting nuspec so downstream consumers (AppHost projects)
also skip the analyzer transitively.

See microsoft/vs-streamjsonrpc#1459 for the upstream MessagePack bump.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
ExcludeAssets in Aspire.Hosting alone is not enough: the .NET 8 SDK
discovers analyzer DLLs in the NuGet cache by convention regardless of
the project.assets.json exclude flags, and StreamJsonRpc.Analyzers.dll
(Roslyn 4.14) fails to load under SDK 8's Roslyn 4.11 with CS9057.

Add a target in Aspire.Hosting.AppHost.targets that runs before
CoreCompile and removes any Analyzer item whose path contains
'StreamJsonRpc.Analyzers'. Aspire doesn't depend on any of the
StreamJsonRpc analyzer diagnostics, so dropping them is safe.

Verified locally: building a net8.0 AppHost with the .NET 8 SDK
(Roslyn 4.11) no longer hits CS9057.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
The Aspire.Hosting.AppHost targets file only reaches direct AppHost
consumers — but Aspire.Hosting.Testing also pulls StreamJsonRpc in
transitively, and the test project (.aspire_xunitTests.csproj) hit the
same CS9057 under .NET 8 SDK. Move the analyzer-strip target into
Aspire.Hosting's buildTransitive/Aspire.Hosting.targets so every
consumer of Aspire.Hosting (AppHost projects, test projects, etc.)
automatically drops the StreamJsonRpc analyzer.

Verified locally: a net8.0 test project that references
Aspire.Hosting.Testing builds cleanly under the .NET 8 SDK.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot AI review requested due to automatic review settings June 15, 2026 02:56

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot encountered an error and was unable to review this pull request. You can try again by re-requesting a review.

@github-actions

github-actions Bot commented Jun 15, 2026

Copy link
Copy Markdown
Contributor

🚀 Dogfood this PR with:

⚠️ WARNING: Do not do this without first carefully reviewing the code of this PR to satisfy yourself it is safe.

curl -fsSL https://raw.githubusercontent.com/microsoft/aspire/main/eng/scripts/get-aspire-cli-pr.sh | bash -s -- 18204

Or

  • Run remotely in PowerShell:
iex "& { $(irm https://raw.githubusercontent.com/microsoft/aspire/main/eng/scripts/get-aspire-cli-pr.ps1) } 18204"

@github-actions

Copy link
Copy Markdown
Contributor

CLI E2E Tests unknown — 112 passed, 0 failed, 2 unknown (commit 4b9e4fc)

View all recordings
- Test Detail
AddPackageInteractiveWhileAppHostRunningDetached Recording · Job · CLI logs
AddPackageWhileAppHostRunningDetached Recording · Job · CLI logs
AgentCommands_AllHelpOutputs_AreCorrect Recording · Job · CLI logs
AgentInitCommand_DefaultSelection_InstallsDefaultSkills Recording · Job · CLI logs
AgentInitCommand_MigratesDeprecatedConfig Recording · Job · CLI logs
AgentInitCommand_NonInteractive_BundleOnlySkillsBeyondCliCatalog_AreInstallable Recording · Job · CLI logs
AgentMcpListResources_ExcludesResourceMarkedWithExcludeFromMcp Recording · Job · CLI logs
AgentMcpListStructuredLogsReturnsLogsFromStarterApp Recording · Job · CLI logs
AgentMcpListStructuredLogsReturnsLogsFromStarterApp_DevLocalhost Recording · Job · CLI logs
AgentMcpListStructuredLogsReturnsLogsFromStarterApp_Isolated Recording · Job · CLI logs
AllPublishMethodsBuildDockerImages Recording · Job · CLI logs
AspireAddAndStartWorkAgainstLegacyAppHostTs Recording · Job · CLI logs
AspireAddPackageVersionToDirectoryPackagesProps Recording · Job · CLI logs
AspireInitSingleFileAppHostRunsViaDotnetRunAppHost Recording · Job · CLI logs
AspireInitWithExistingAppHostDirRecreatesMissingNuGetConfigAndPreservesFiles Recording · Job · CLI logs
AspireInitWithSolutionFileGeneratesAppHostThatBuildsAgainstChannelHive Recording · Job · CLI logs
AspireStartUpdatesStaleTypeScriptAppHostPath Recording · Job · CLI logs
AspireUpdateRemovesAppHostPackageVersionFromDirectoryPackagesProps Recording · Job · CLI logs
AspireUpdateRemovesOrphanAppHostPackageVersionWhenSdkAlreadyCurrent Recording · Job · CLI logs
Banner_DisplayedOnFirstRun Recording · Job · CLI logs
Banner_DisplayedWithExplicitFlag Recording · Job · CLI logs
Banner_NotDisplayedWithNoLogoFlag Recording · Job · CLI logs
CertificatesClean_RemovesCertificates Recording · Job · CLI logs
CertificatesTrust_WithNoCert_CreatesAndTrustsCertificate Recording · Job · CLI logs
CertificatesTrust_WithUntrustedCert_TrustsCertificate Recording · Job · CLI logs
ConfigSetGet_CreatesNestedJsonFormat Recording · Job · CLI logs
CreateAndRunAspireStarterProject Recording · Job · CLI logs
CreateAndRunAspireStarterProjectWithBundle Recording · Job · CLI logs
CreateAndRunEmptyAppHostProject Recording · Job · CLI logs
CreateAndRunJavaEmptyAppHostProject Recording · Job · CLI logs
CreateAndRunJsReactProject Recording · Job · CLI logs
CreateAndRunPolyglotAppHostWithDevLocalhostUrls Recording · Job · CLI logs
CreateAndRunPythonReactProject Recording · Job · CLI logs
CreateAndRunTypeScriptEmptyAppHostProject Recording · Job · CLI logs
CreateAndRunTypeScriptStarterProject Recording · Job · CLI logs
CreateJavaAppHostWithViteApp Recording · Job · CLI logs
CreateTypeScriptAppHostWithViteApp_AllowsGuestAppPackageManagerToDiffer Recording · Job · CLI logs
CreateTypeScriptAppHostWithViteApp_UsesConfiguredToolchain Recording · Job · CLI logs
DashboardRunWithAgentMcpListTracesReturnsNoTraces Recording · Job · CLI logs
DashboardRunWithAgentMcpListTracesReturnsNoTraces_DevLocalhost Recording · Job · CLI logs
DashboardRunWithOtelTracesReturnsNoTraces Recording · Job · CLI logs
DashboardRunWithOtelTracesReturnsNoTraces_DevLocalhost Recording · Job · CLI logs
DeployK8sBasicApiService Recording · Job · CLI logs
DeployK8sWithExternalHelmChart Recording · Job · CLI logs
DeployK8sWithGarnet Recording · Job · CLI logs
DeployK8sWithMongoDB Recording · Job · CLI logs
DeployK8sWithMySql Recording · Job · CLI logs
DeployK8sWithPostgres Recording · Job · CLI logs
DeployK8sWithRabbitMQ Recording · Job · CLI logs
DeployK8sWithRedis Recording · Job · CLI logs
DeployK8sWithSqlServer Recording · Job · CLI logs
DeployK8sWithValkey Recording · Job · CLI logs
DeployTypeScriptAppToKubernetes Recording · Job · CLI logs
DescribeCommandResolvesReplicaNames Recording · Job · CLI logs
DescribeCommandShowsRunningResources Recording · Job · CLI logs
DetachFormatJsonProducesValidJson Recording · Job · CLI logs
DetachFormatJsonProducesValidJsonWhenRestartingExistingInstance Recording · Job · CLI logs
DoPublishAndDeployListStepsWork Recording · Job · CLI logs
DocsCommand_RendersInteractiveMarkdownFromLocalSource Recording · Job · CLI logs
DoctorCommand_DetectsDeprecatedAgentConfig Recording · Job · CLI logs
DoctorCommand_TypeScriptAppHostReportsMissingConfiguredToolchain Recording · Job · CLI logs
DoctorCommand_WithSslCertDir_ShowsTrusted Recording · Job · CLI logs
DoctorCommand_WithoutSslCertDir_ShowsPartiallyTrusted Recording · Job · CLI logs
GatewayWithoutExternalEndpoint_FailsPublishWithGuidance Recording · Job · CLI logs
GeneratedAspireDevScript_StartsWatchMode_WithConfiguredToolchain Recording · Job · CLI logs
GlobalMigration_HandlesCommentsAndTrailingCommas Recording · Job · CLI logs
GlobalMigration_HandlesMalformedLegacyJson Recording · Job · CLI logs
GlobalMigration_PreservesAllValueTypes Recording · Job · CLI logs
GlobalMigration_SkipsWhenNewConfigExists Recording · Job · CLI logs
GlobalSettings_MigratedFromLegacyFormat Recording · Job · CLI logs
IngressWithoutExternalEndpoint_FailsPublishWithGuidance Recording · Job · CLI logs
InitTypeScriptAppHost_AugmentsExistingViteRepoInWorkspaceSubdirectory Recording · Job · CLI logs
InteractiveCSharpInitCreatesExpectedFiles Recording · Job · CLI logs
InvalidAppHostPathWithComments_IsHealedOnRun Recording · Job · CLI logs
JavaScriptHostingApisRunFromTypeScriptAppHost Recording · Job · CLI logs
LatestCliCanStartStableChannelAppHost Recording · Job · CLI logs
LatestCliCanStartStableChannelTypeScriptAppHost Recording · Job · CLI logs
LegacySettingsMigration_AdjustsRelativeAppHostPath Recording · Job · CLI logs
LogsCommandShowsResourceLogs Recording · Job · CLI logs
OtelLogsReturnsStructuredLogsFromStarterApp Recording · Job · CLI logs
OtelLogsReturnsStructuredLogsFromStarterAppIsolated Recording · Job · CLI logs
PersistentContainersPreserveDataAcrossAppHostRuns Recording · Job · CLI logs
PsCommandListsRunningAppHost Recording · Job · CLI logs
PsFormatJsonOutputsOnlyJsonToStdout Recording · Job · CLI logs
PublishJavaScriptPatternsGeneratesExpectedDockerComposeArtifacts Recording · Job · CLI logs
PublishWithConfigureEnvFileUpdatesEnvOutput Recording · Job · CLI logs
PublishWithDockerComposeServiceCallbackSucceeds Recording · Job · CLI logs
PublishWithoutOutputPathUsesAppHostDirectoryDefault Recording · Job · CLI logs
ResourceCommand_FailedExecution_DisplaysAppHostLogPathAndLogContainsEntries Recording · Job · CLI logs
ResourceCommand_SetAndDeleteParameterUpdatesDescribeOutput Recording · Job · CLI logs
RestoreGeneratesSdkFiles Recording · Job · CLI logs
RestoreGeneratesSdkFiles_WithConfiguredToolchain Recording · Job · CLI logs
RestoreRefreshesGeneratedSdkAfterAddingIntegration Recording · Job · CLI logs
RestoreSupportsConfigOnlyHelperPackageAndCrossPackageTypes Recording · Job · CLI logs
RunFromParentDirectory_UsesExistingConfigNearAppHost Recording · Job · CLI logs
RunReportsSyntaxErrorsForDotNetAppHost Recording · Job · CLI logs
RunReportsSyntaxErrorsForTypeScriptAppHost Recording · Job · CLI logs
SecretCrudOnDotNetAppHost Recording · Job · CLI logs
SecretCrudOnTypeScriptAppHost Recording · Job · CLI logs
StagingChannel_ConfigureAndVerifySettings_ThenSwitchChannels Recording · Job · CLI logs
StartAndWaitForTypeScriptSqlServerAppHostWithNativeAssets Recording · Job · CLI logs
StartReportsSyntaxErrorsForDotNetAppHost Recording · Job · CLI logs
StartReportsSyntaxErrorsForTypeScriptAppHost Recording · Job · CLI logs
StopAllAppHostsFromAppHostDirectory Recording · Job · CLI logs
StopJavaPolyglotAppHostUsingApphostDirectory Recording · Job · CLI logs
StopNonInteractiveSingleAppHost Recording · Job · CLI logs
StopTypeScriptPolyglotAppHostUsingApphostDirectory Recording · Job · CLI logs
StopWithNoRunningAppHostExitsSuccessfully Recording · Job · CLI logs
TypeScriptAppHostRunDoesNotDeadlockWhenLazyOptionsInvokeAsyncCallback Recording · Job · CLI logs
UnAwaitedChainsCompileWithAutoResolvePromises Recording · Job · CLI logs
UpdateProjectChannelToStable_CSharpEmptyAppHost_PreservesAspireConfigChannel Recording · Job · CLI logs
UpdateProjectChannelToStable_CSharpSingleFileInit_PreservesAspireConfigChannel Recording · Job · CLI logs
UpdateProjectChannelToStable_TypeScriptSingleFileInit_PreservesAspireConfigChannel Recording · Job · CLI logs
UpdateProjectChannelToStable_TypeScript_PreviewsStablePackagesAndPreservesChannel Recording · Job · CLI logs

📹 Recordings uploaded automatically from CI run #27521232193

StreamJsonRpc 2.25.29 ships analyzers compiled against an older Roslyn
that is compatible with the .NET 8 SDK (vs-streamjsonrpc#1463 / #1399),
so the buildTransitive analyzer-strip target and the ExcludeAssets flag
on the PackageReference are no longer needed.

Mirrors the final state of #18155 on main.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@mitchdenny mitchdenny changed the title [release/13.4] Bump StreamJsonRpc to 2.25.28 to clear MessagePack NU1903 [release/13.4] Bump StreamJsonRpc to 2.25.29 to clear MessagePack NU1903 Jun 16, 2026
@joperezr joperezr merged commit a157bd9 into release/13.4 Jun 16, 2026
313 checks passed
@joperezr joperezr deleted the backport/pr-18155-to-release/13.4 branch June 16, 2026 18:22
@github-actions github-actions Bot added this to the 13.4.x milestone Jun 16, 2026
@microsoft-github-policy-service microsoft-github-policy-service Bot removed this from the 13.4.x milestone Jun 16, 2026
This was referenced Jul 10, 2026
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.

6 participants