跳到正文
DEV Community· ProofCloak·· 3 小時前AI 評分40

.NET 建置成功,保護預檢仍可能失敗

A green .NET build can still fail a protection precheck

AI 導讀

InvoiceDesk 的 .NET Release 建置雖然成功,保護預檢仍因 virtualization 與所選設定不相容而回報 Not supported for this profile and route,錯誤碼為 selection_no_match。

正文

ProofCloak

A Release build of InvoiceDesk, a small .NET console sample, compiled successfully. On November 8 its protection precheck still returned Not supported for this profile and route. The precheck was evaluating the selected transformations against an actual build artifact. The compiler had already finished its own checks.

One incompatible setting stopped the profile

On the managed-il route, the selected profile requested renaming, string protection, control-flow changes and virtualization. The first three were allowed for this input. Virtualization was marked incompatible for this combination, and the full profile was refused with selection_no_match.

The selected profile is refused on the managed-il route and virtualization is marked incompatible

Removing virtualization and rerunning the precheck against the same input and route produced Supported for this profile and route. That result applies to the revised selection.

The revised profile is supported on the same managed-il route

How to use the result in a release pipeline

  1. Run the compatibility check on the exact Release artifact. Record the artifact digest, profile version and route.
  2. If the profile is refused, stop the protection step and keep the reason code. Review the profile change before trying again so the intended release settings remain auditable.
  3. Run the behavior tests on the protected output you plan to distribute. For InvoiceDesk, that means accepted and rejected licenses, price calculations and existing JSON settings. For a desktop app, add the startup and configuration paths customers use.

The screenshots come from ProofCloak's InvoiceDesk sample and cover the compatibility decision. Runtime behavior still needs its own test results. The sample source is available in the InvoiceDesk repository.

Which test catches regressions in the .NET artifact you actually ship?

Disclosure: AI helped draft this write-up from the recorded test and screenshots. ProofCloak maintains the sample and the tool used in the example.

來源:DEV Community · dev.to