Devolutions.Now.Policy.Model
2026.7.13
Prefix Reserved
dotnet add package Devolutions.Now.Policy.Model --version 2026.7.13
NuGet\Install-Package Devolutions.Now.Policy.Model -Version 2026.7.13
<PackageReference Include="Devolutions.Now.Policy.Model" Version="2026.7.13" />
<PackageVersion Include="Devolutions.Now.Policy.Model" Version="2026.7.13" />
<PackageReference Include="Devolutions.Now.Policy.Model" />
paket add Devolutions.Now.Policy.Model --version 2026.7.13
#r "nuget: Devolutions.Now.Policy.Model, 2026.7.13"
#:package Devolutions.Now.Policy.Model@2026.7.13
#addin nuget:?package=Devolutions.Now.Policy.Model&version=2026.7.13
#tool nuget:?package=Devolutions.Now.Policy.Model&version=2026.7.13
Devolutions NOW policy model for .NET
Devolutions.Now.Policy.Model contains the .NET policy document model for Devolutions NOW package broker policies. It is the .NET counterpart to the Rust now-policy crate and represents the policy files used to decide whether package operations are allowed or denied.
Purpose
This package is focused on policy documents, not broker transport. It is used by .NET code that needs to create, parse, inspect, or serialize Devolutions NOW policy files.
The model is used to:
- represent package broker policy documents in C#;
- parse strict JSON policy documents;
- parse YAML policy documents by converting them to the same JSON model;
- serialize policy documents with the canonical JSON shape;
- share policy enums and document types with the package broker API compatibility layer.
Architecture
PolicyModels.csdefinesPolicyDocument, metadata, enforcement, rules, match criteria, constraints, and version range types.Enums.csdefines policy-level enums such as operation, manager, scope, architecture, elevation, decision, and rule precedence.PolicyJson.csdefines sharedJsonSerializerOptions, including strict parsing that rejects unknown JSON members.
PolicyDocument.Create provides a simple helper for constructing a new policy document with metadata and default enforcement. PolicyDocument.ParseJson and PolicyDocument.ParseYaml are the main entry points for reading policy documents.
Validation
Run the Rust policy schema/tests as well when changing shared policy semantics.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net9.0 is compatible. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 is compatible. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net10.0
- YamlDotNet (>= 16.2.0)
-
net9.0
- YamlDotNet (>= 16.2.0)
NuGet packages (1)
Showing the top 1 NuGet packages that depend on Devolutions.Now.Policy.Model:
| Package | Downloads |
|---|---|
|
Devolutions.Now.Policy.Api
Request and response DTOs for the Devolutions NOW package broker API. |
GitHub repositories
This package is not used by any popular GitHub repositories.