Repository navigation
[ci] Re-enable signing validation in the official pipeline - #39524
Conversation
Arcade SignCheck, which is about to be re-enabled for the official pipeline, treats .js files as signable and reports NavMenu.razor.js as unsigned. The two copies of this file (maui-blazor and maui-blazor-solution) are shipped in the Microsoft.Maui.Templates.net11 package, and again inside the nested pack nupkg of each of the three Microsoft.Maui.Templates.net11.Msi.* workload installers, which makes 8 findings in total. ReconnectModal.razor.js, the only other .js file in the templates, is already signed through FileSignInfo (#35026, where the Visual Studio signing scan flagged it as unsigned). NavMenu.razor.js was added to the .NET 11 templates in #34945 and was missed. Sign it the same way, with the Microsoft400 certificate. SignCheck only runs on Windows, so I could not run it. Instead I inspected the PackageArtifacts of official build 3109012 (net11.0 @ 1f6ecca) and applied SignCheck's file type rules: apart from NavMenu.razor.js, every file it would verify (PE files, MSIs and the WiX custom action binaries embedded in them, the nupkgs nested in the MSIs) carries a signature. The effect of this change can only be observed in an official build: the two NavMenu.razor.js files should end with a '// SIG // Begin signature block' section. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Set enableSigningValidation back to true so the Arcade post-build 'Signing Validation' job (SignCheck) runs in the 'Validate Build Assets' stage and verifies the nupkgs in PackageArtifacts, including the MSIs and the nupkgs nested in them. Until now nothing verified the signatures of the shipped packages in the pipeline: the job was skipped in every official build. History: validation was enabled in the first Arcade based official pipeline (c72387d) and was switched off in bd7aead (#25986, 2024-11-20), in a commit named 'Dont validate sigining' that was one of the ten it took to get a green official build while fixing the signing of the template fonts. Nothing turned it back on. The 'Disable for now as we test the new signing process' comment never applied to signing validation: it was written for the enableSourceLinkValidation line below it, and was left behind when the line above it was flipped. Arcade has since removed SourceLink validation (the parameter is only kept so existing pipelines don't break), so reword the comment accordingly. The job downloads PackageArtifacts, so it does not look at the APIScanFiles artifact (pre-signing build outputs) that the 1ES CodeSign Validation reports. Expected in the next official build: the 'Signing Validation' job runs (it was skipped) and succeeds. It gates 'Publish using Darc' through publishDependsOn, so if SignCheck reports something unexpected the build fails before publishing. Only add an eng/SignCheckExclusionsFile.txt entry for content that is intentionally unsigned, with a justification for each entry. The previous commit signs NavMenu.razor.js, the only file I expect SignCheck to flag. Checked with a dry run (preview) of the dotnet-maui pipeline on dnceng/internal: the only difference in the expanded pipeline is the condition of that job, eq(False, 'true') becoming eq(True, 'true'). PostBuildSign, the variable that would still skip the job, is not set in the repository, the pipeline variables or its variable groups. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
The official build reports 313 CodeSign.MissingSigningCert findings, for
example in build 3109012:
file:///D:/a/_work/_temp/APIScanFiles/Release/net11.0/Microsoft.Maui.dll
They come from the 'Guardian: CodeSign Validation' step that 1ES PT adds
to the APIScan job, not from Arcade, and all of them are in the
APIScanFiles artifact. stage-pack.yml fills that artifact with the
Controls.Core build output before the packages are signed, so those
files are unsigned by design. The shipped packages are signed.
1ES PT adds the step because the APIScan job is a releaseJob with
isProduction: true, and for the inputs of production release jobs it
runs CodeSign Validation, SBOM validation, source build validation and
branch validation. The job releases nothing, it only hands the artifact
to APIScan, so declare it as a non-production release job instead.
Today the findings only warn ('CSV is enabled in audit mode to collect
telemetry for future enforcement'), so this also avoids the APIScan
stage failing once 1ES enforces it.
Side effects, all limited to the APIScan job and stage, as seen in the
expanded pipeline: the 'Branch Validation', 'Validate SBoM Manifest',
'Post-SBoM Validation' and 'Validate Source Build' steps are gone, the
stage no longer has a productionReadinessPolicy check, and the run is
tagged 1ES.PT.Release.NonProduction instead of 1ES.PT.Release.Production.
That includes the audit mode error from 'Validate Source Build' that
net11.0 is not a production branch in dnceng/internal: it no longer shows
up here, but the branch classification itself is not changed by this.
What is built, signed and published does not change, and APIScan scans
the same files as before.
Checked with a dry run (preview) of the dotnet-maui pipeline on
dnceng/internal, with the modified stage inlined because the preview
reads templates from the branch on the server. Expected in the next
official build from net11.0, main or release/*: the APIScan job has no
'Guardian: CodeSign Validation' step and the stage still succeeds.
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
The previous commit replaced the comment 'Disable for now as we test the new signing process' with a note that Arcade removed SourceLink validation and that the parameter has no effect. That holds for net11.0's eng/common, but main still has the older Arcade, whose post-build template has a real 'SourceLink Validation' job that enableSourceLinkValidation controls. So the new comment was wrong on main. Don't describe Arcade at all and drop the comment instead. It was written for the enableSourceLinkValidation line below it, and now that signing validation is enabled it only misleads when it sits under that setting. enableSourceLinkValidation stays false, as before. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
|
🚀 Dogfood this PR with:
curl -fsSL https://raw.githubusercontent.com/dotnet/maui/main/eng/scripts/get-maui-pr.sh | bash -s -- 39524Or
iex "& { $(irm https://raw.githubusercontent.com/dotnet/maui/main/eng/scripts/get-maui-pr.ps1) } 39524" |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
|
This comment has been minimized.
This comment has been minimized.
|
2 similar comments
|
|
|
1 similar comment
|
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
|
|
|
…ning-validation Conflict in eng/pipelines/arcade/stage-api-scan.yml: main already marks the APIScan job as non-production (#38735), so take main's version. This branch no longer changes that file. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
|
/rebase |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
Tests Failure Analysis
🧪 CI Analysis — click to expand📊 maui-prNo failures found. 🧪 maui-pr-devicetestsTarget history lacks equivalent parameterized diagnostics.
🧪 maui-pr-uitestsMatching diagnostics: target
🧭 Follow-up — actions and refreshNext action: Inspect Android completion; compare device/FlexLayout failures with equivalent base configurations.
|
|
/review run-tests |
Selected UI Tests
🧪 Test selection — click to expandℹ️ The AI found no UI-test-relevant changes, so no GPT-6.1 Sol: No UI tests needed: changes only affect official-build signing and package signature validation. 🧪 Running — nothingNo UI tests run for this PR. ⏭️ Skipped — 77 categories, 4 platformsPlatforms not run: Android, iOS, MacCatalyst, Windows Each skipped platform and category is listed as a Skipped 🤖 Why these tests — AI rationale (GPT-6.1 Sol + Claude Opus 5.5)Each model chose independently; every test that runs was selected by at least one of them.
GPT-6.1 Sol — No UI tests needed: changes only affect official-build signing and package signature validation.
Claude Opus 5.5 — Signing-only changes for the official pipeline; no UI tests needed.
Generated by /review run-tests. A targeted run is a fast signal, not full-suite certification. |
There was a problem hiding this comment.
🔵 Needs a closer look
The production publication-gate change requires maintainer confirmation of official-build SignCheck results and signed artifacts because real-certificate signing and nested MSI validation cannot be independently verified here.
No open issues 🎉
What changed in this PR
Restores post-build signing validation in the official .NET MAUI pipeline and adds signing coverage for the Blazor templates’ navigation script.
Changes:
- Enables signing validation before package publication.
- Adds
NavMenu.razor.jsto the signing configuration usingMicrosoft400, matchingReconnectModal.razor.js. - Removes an obsolete comment while leaving SourceLink validation disabled.
| File | Description |
|---|---|
eng/Signing.props |
Adds signing configuration for NavMenu.razor.js. |
eng/pipelines/ci-official.yml |
Re-enables signing validation and removes the obsolete comment. |
Review effort: Balanced
…otnet test migration to net11 (#40763) <!-- Please let the below note in for people that find this PR --> > [!NOTE] > Are you waiting for the changes in this PR to be merged? > It would be very helpful if you could [test the resulting artifacts](https://github.com/dotnet/maui/wiki/Testing-PR-Builds) from this PR and let us know in a comment if this change resolves your issue. Thank you! <!-- Open .NET 11 fix PRs against net11 for review; target main for next-major features. After approval, a maintainer manually retargets the fix PR to the active inflight branch and merges it directly there. Do not merge individual fixes into net11. Bots must not retarget or merge. Candidate integration into net11 and release/* changes are separate, explicitly coordinated release work. --> ### Target Branch | This PR is for | Initial base | | --- | --- | | New features, API changes, or .NET 12 work (including .NET 12 fixes) | `main` | | .NET 11 servicing fixes | `net11`, for review | | Older servicing, release integration, infrastructure, or documentation | The branch designated for that work | - [x] I selected the applicable base branch using the [contribution guide](https://github.com/dotnet/maui/blob/main/.github/CONTRIBUTING.md#choose-your-pr-base-before-starting). Repository infrastructure only; targets `net11` so its CI, agentic and release tooling matches `main`. ### Description of Change Brings the repository-infrastructure merges from `main` (since `net11` diverged) to `net11`: `/review` run-tests / run-ui-tests / run-device-tests, MAUI Autopilot, release tooling, signing validation and related docs. Each commit is a `git cherry-pick -x` of the merged PR; all applied without conflicts (the `eng/` part of #40545 was already backported in #40629). **Included (28 commits):** - [release] Recover from squash-merged CI normalization PRs (#40566) - [Release state] Advance 11.0.1xx to SR3 (#40571) - [ci] /review run-tests, run-ui-tests and run-device-tests; MAI Code 2 as the second model (#40545) - Document that forward PRs must never use long-lived branches as head (#40582) - [ci] /review run-tests: standard /review comment layout; fix MAI Code 2 (#40591) - [ci] /review run-tests: don't rewrite Result badges of older comments (#40592) - [ci] /review run-tests: show each Azure DevOps job as a check on the PR (#40612) - Remove standalone /review gate workflow (#40595) - [ci] Hide /review run-tests command comments once acknowledged (#40593) - [ci] /review run-tests: report jobs as commit statuses named after the pipeline (#40624) - Remove standalone /review tests failure-analysis lane (#40596) - [ci] /review run-tests: build PRs only with their target branch's pipeline (#40628) - [ci] /review run-tests: report skipped, selection and run checks as commit statuses (#40627) - [ci] /review run-tests: fix the dispatch crash on existing statuses; log refused dispatches (#40631) - [ci] /review run-tests: let release-branch dispatches be pushed (#40634) - [ci] Re-enable signing validation in the official pipeline (#39524) - Group Dependabot NuGet updates for main and net11 (#40650) - [ci] Hide dogfood and skill validation comments (#40651) - Add MAUI Autopilot: /review autopilot drives review → fix → tests on opted-in PRs (#40668) - MAUI Autopilot: three-model cross-examined fixes (adds Claude Opus 5.5), Copilot review threads, test failure evidence, clear endings (#40672) - [release] Merge candidate into inflight daily without rewriting history (#40671) - MAUI Autopilot: three-model triage of failing tests and a needs-maintainer-decision label (#40707) - MAUI Autopilot: install the repository .NET SDK so fix rounds can run unit tests (#40732) - MAUI Autopilot: a maintainer's /review autopilot always runs (#40738) - MAUI Autopilot: every /review autopilot handles all earlier review suggestions; stop no-op issue mentions (#40743) - MAUI Autopilot: fix fork follow-ups (squash out-of-src commits, proper endings) and never fail on missing test evidence (#40746) - MAUI Autopilot: resolve merge conflicts, add UI screenshot baselines from Azure DevOps, back off on rate limits (#40750) - Migrate tests from Helix and XHarness to native dotnet test (#40661) [net11] — conflicts resolved to the net11 tree CI-validated in #40703 (`net11.0` TFM, CoreCLR **and Mono** device-test runtimes, net11 Arcade SDK); SourceGen tests for .NET 12-only features are not brought over. **Deliberately excluded:** - .NET 12 product features and bug fixes (animations, ContentButton, ScrollAnchorMode, trimming, XSG styles, Label.IsTextSelectable, Preferences enums, image metadata, QueryProperty, binding/route/XAML fixes, …). - #40060 Move main to .NET 12; main-only build-break fixes (#40666, #40674, #40708, #40720, #40751) and #40663 platform-compatibility re-enable (product code changes). - Dependabot bumps (#40639, #40640, #40641, #40643) — `net11` gets its own grouped Dependabot updates (#40650); localization check-ins. - #40615 — empty commit upstream. **Note for reviewers:** #40672 adds `maui-expert-autopilot-opus` (Claude Opus 5.5). `CopilotPipeline.Tests.ps1` → "contains no Anthropic model identifiers" fails on it exactly as it does on `main` today. Drop that workflow here if `net11` should keep that policy test green. ### Validation **CI (`/azp run` on this PR):** | Pipeline | Result | | --- | --- | | `maui-pr` [1703708](https://dev.azure.com/dnceng-public/public/_build/results?buildId=1703708) (build, pack, unit + integration tests on `dotnet test`/MTP) | ✅ succeeded | | `maui-pr-uitests` [1703714](https://dev.azure.com/dnceng-public/public/_build/results?buildId=1703714) | ✅ succeeded | | `maui-pr-devicetests` [1703715](https://dev.azure.com/dnceng-public/public/_build/results?buildId=1703715) | 38/41 jobs ✅ — all Android, iOS, Mac Catalyst (CoreCLR + Mono) pass | Device-test failures (Windows only): - `Windows controls packaged/unpackaged`: test host terminates with `0xDEAD` in the NavigationPage category — the known Windows blocker listed in #40661; the same two jobs fail on `main` after #40661 ([1703728](https://dev.azure.com/dnceng-public/public/_build/results?buildId=1703728)) and on #40703 ([1703325](https://dev.azure.com/dnceng-public/public/_build/results?buildId=1703325)). - `Windows blazorwebview unpackaged`: one test, `InterceptedResponseWithoutABodyIsServedWithASingleContentTypeHeader(isContentNull: False)`, timed out after 30 s waiting for CoreWebView2. The same lane passed on #40703. GitHub checks: `Validate (PR)` (Release Readiness) fails in `MauiReleaseConfiguration.Tests.ps1` ("Wrong evaluated label on candidate/11.0.1xx-sr1"). It is triggered here because #40566 touches `MauiReleaseConfiguration.psm1`, and #40566 failed the same check on `main`; it also fails locally on unmodified `net11`. Skill-validation evals fail on unavailable `COPILOT_PAT_*` tokens and fixture fetches, the same as on #40661/#40703. **Local:** `actionlint` on changed workflows (exit 0); YAML and PowerShell parse of all changed files (no errors). Pester over the `powershell-script-tests.yml` paths: 26 failures vs 28 on unmodified `net11`. The only new failure is the Anthropic-model policy test (see note above), which also fails on `main`. ### Issues Fixed N/A — repository infrastructure sync. ### Let AI finish this PR - [ ] **Let the MAUI agent address review feedback and fix remaining issues on this PR.** Maintainers still decide whether it is merged. For PRs from forks, the agent opens a follow-up PR that keeps your commits. ---------
Note
Are you waiting for the changes in this PR to be merged?
It would be very helpful if you could test the resulting artifacts from this PR and let us know in a comment if this change resolves your issue. Thank you!
Target Branch
mainnet11, for reviewFor .NET 11 fixes, only a maintainer retargets the approved PR to the active
inflight lane and merges it after CI validates that final base. Do not merge
individual fixes directly into
net11; agents must not retarget or merge.Description of Change
The official pipeline (
dotnet-maui) signs the packages it ships with the real certificates (_SignTypeisreal), but nothing verifies them afterwards, because the post-build signing validation is switched off.Re-enable signing validation (
eng/pipelines/ci-official.yml)enableSigningValidationgoes back totrue. Arcade's "Signing Validation" job (SignCheck) then runs in the "Validate Build Assets" stage and verifies everything inPackageArtifacts, including the MSIs and the nupkgs nested in them.Publish using Darcdepends on that stage, so unsigned content in a package can no longer be published unnoticed.It was switched off in #25986 ("Fix signing fonts, add public pipeline"), in a commit named "Dont validate sigining", and nothing turned it back on. The comment under the setting, "Disable for now as we test the new signing process", was written for the
enableSourceLinkValidationline below, not for signing validation, so this PR removes it.Sign
NavMenu.razor.js(eng/Signing.props)SignCheck checks
.jsfiles, and the two copies ofNavMenu.razor.jsin the Blazor templates (maui-blazorandmaui-blazor-solution) aren't signed, unlikeReconnectModal.razor.js(#35026). In the templates package of the official build 3130460 ofmain, they have no signature. With signing validation on, SignCheck would flag them there, and again in the nupkg nested in eachMicrosoft.Maui.Templates.*.Msi.*package.CodeSign Validation on
APIScanFiles(already fixed onmain)The official build also reported 313
CodeSign.MissingSigningCertfindings from the 1ES PT step "Guardian: CodeSign Validation" (build 3109012 of net11.0). They were all for the unsigned build outputs inAPIScanFiles, which is the input of the APIScan job. #38735 already fixed that onmain, by marking the APIScan job and theAPIScanFilesartifact as non-production, so this PR doesn't change it. In the official build 3130460 ofmain, the APIScan job succeeded, and it doesn't have the steps "Guardian: CodeSign Validation", "Branch Validation", SBOM and "Validate Source Build".Validation
Only an official build can show this, because PR builds use the unofficial template. Official build 3138536 (internal) of this branch at 90f0ec3 (
mainat 8744f99 plus the two changes in this PR) succeeded:No signing issues found,Total Files: 6600, Signed: 1888, Unsigned: 0, Skipped: 4712, Excluded: 0. Among the signed files are the 60 nupkgs inPackageArtifacts, the 39 MSIs, the 33 nupkgs nested in them and 1668 DLLs. Noeng/SignCheckExclusionsFile.txtis needed. The job takes about 7 minutes and runs next to NuGet Validation.NavMenu.razor.js(two in the templates package, and two in the nupkg nested in each of the threeMicrosoft.Maui.Templates.net11.Msi.*packages) and the 4 copies ofReconnectModal.razor.jsasSigned. In the templates nupkg of this build, bothNavMenu.razor.jsend with a signature block (// SIG // End signature block).Issues Fixed
N/A, there is no GitHub issue.