Skip to content

Protect setup files and avoid publisher trust prompts - #103

Draft
AmirMS (AmelBawa-msft) wants to merge 2 commits into
mainfrom
user/amelbawa/dev-config-pe
Draft

AmirMS (AmelBawa-msft) wants to merge 2 commits into
mainfrom
user/amelbawa/dev-config-pe

Conversation

@AmelBawa-msft

Copy link
Copy Markdown
Collaborator

No description provided.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🟡 Changes recommended

Signature verification currently fails on supported PowerShell versions before 7.4, and existing install roots may prevent reboot resume.

Get a fresh assessment by requesting another Copilot review.

Pull request overview

Secures Calm OS setup files and replaces AllSigned launches with verified, prompt-free RemoteSigned execution.

Changes:

  • Adds signature and ACL validation.
  • Installs under protected %ProgramData%\CalmOS.
  • Updates bootstrap, relaunch behavior, and documentation.
File summaries
File Description
src/windows-dev-config/steps/_security.ps1 Adds signature and permission checks.
src/windows-dev-config/steps/_elevation.ps1 Uses RemoteSigned for relaunches.
src/windows-dev-config/dev-config.ps1 Validates files before loading helpers.
src/windows-dev-config/bootstrap.ps1 Adds protected download, installation, and elevation.
src/windows-dev-config/README.md Documents the new security model.
src/docs/development.md Updates contributor guidance.
Review details
  • Files reviewed: 6/6 changed files
  • Comments generated: 3
  • Review effort level: Balanced

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread src/windows-dev-config/bootstrap.ps1
Comment thread src/windows-dev-config/dev-config.ps1
Assert-DevConfigProtectedPath -Path $ancestor.FullName -Ancestor
}

if (-not (Test-Path -LiteralPath $Path)) {

@JohnMcPMS JohnMcPMS left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Given the lack of support for the memory-based signature check, I think the path is:

  1. First run creates directory under install root, copies all scripts there.
  2. Changes owner and ACLs to admin only write with everyone read/execute
  3. Verifies signature on the entry point script one more time
  4. Invokes the entry point script with signature validation elevated
  5. Elevated script revalidates signatures for all files
  6. Continue with actual work

Comment thread src/windows-dev-config/bootstrap.ps1 Outdated
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.

3 participants