windows_baseline.dsc.yaml is using deprecated Microsoft.DSC metadata

Open Beginner friendly
#1,831 0 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
1/5
Estimated time
Under an hour
Newbie friendliness
72/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Active
Tech stack
rust, yaml
Domain
devops

Research direction

Read configurations/windows/windows_baseline.dsc.yaml and compare its metadata with the deprecation guidance in issue #1369 and the schema question raised in #1673. Run dsc config get --file windows_baseline.dsc.yaml to confirm the warning, then verify the updated sample runs without warnings using the appropriate schema and security context.

Written by the indexing model from the issue text.

Description

Issue-Bug Need-Review
Prerequisites
  • Write a descriptive title.
  • Make sure you are able to repro it on the latest version
  • Search the existing issues.
Summary

Usage of the Microsoft.DSC metadata has been deprecated after issue #1369.
The windows_baseline.dsc.yaml file still uses it, and issues a warning when run.
Provided samples shouldn't be using deprecated features.
Tested om 3.3.0 and 3.4.0-preview.3

https://github.com/PowerShell/DSC/blob/57d1ad87713cfc55883c0c7ecc38ad6f5aacb5cb/configurations/windows/windows_baseline.dsc.yaml#L1-L5

The fix is very easy, but I've not yet created a pull request, because I think it should be using a newer schema?
But issue #1673 complicates things/confuses me. Maybe I should just create a pull request and wait for the feedback.

# This configuration validates a Windows system against a security baseline configuration
$schema: https://aka.ms/dsc/schemas/v3/bundled/config/document.json
directives:
  securityContext: elevated
Steps to reproduce
  1. run the following command:
dsc config get --file windows_baseline.dsc.yaml
Expected behavior
no warnings
Actual behavior
2026-11-26T03:07:03.201409Z  WARN Using 'Microsoft.DSC' metadata to specify required security context is deprecated. Please use the 'securityContext' directive in the configuration document instead.  See https://github.com/PowerShell/DSC/issues/1369 for more details.
Error details

Environment data
Name                           Value
----                           -----
PSVersion                      7.7.0
PSEdition                      Core
GitCommitId                    7.7.0
OS                             Microsoft Windows 10.0.26300
Platform                       Win32NT
PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0…}
PSRemotingProtocolVersion      2.4
SerializationVersion           1.1.0.1
WSManStackVersion              3.0
Version

dsc 3.3.0

Visuals

No response

Dominant language
Rust
Stars
546
Forks
84
Avg merge
2d 9h
Merged PRs (30d)
25

Getting set up

Open in Codespaces

Starts the project's dev container in your browser, under your own GitHub account.

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from PowerShell/DSC

All issues in PowerShell/DSC

Similar issues

More Rust issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.