Skip to content

Conversation

@tgauth
Copy link
Collaborator

@tgauth tgauth commented Oct 15, 2025

PR Summary

  • update MSI and install script to create RedirectionGuard reg keys, if they do not already exist, for ssh-agent and sshd services
  • should have no impact on typical usage of either service

PR Context

@tgauth
Copy link
Collaborator Author

tgauth commented Oct 15, 2025

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@tgauth tgauth requested review from TravisEz13 and Copilot October 15, 2025 20:15
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR enables RedirectionGuard mitigation for both sshd.exe and ssh-agent.exe services by creating registry keys during installation. This security enhancement addresses unsafe junction traversal vulnerabilities in Windows as detailed in the Microsoft MSRC blog post from June 2025.

  • Registry keys are created under Image File Execution Options for both sshd.exe and ssh-agent.exe with MitigationOptions values
  • Both the PowerShell installer script and WiX MSI installer are updated to create these registry entries
  • Registry entries are marked as permanent (persisting through uninstall) and only created if they don't already exist

Reviewed Changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
contrib/win32/openssh/install-sshd.ps1 Adds registry key creation logic for RedirectionGuard mitigation for both sshd.exe and ssh-agent.exe
contrib/win32/install/shared.wxs Adds MSI component to create ssh-agent.exe RedirectionGuard registry key
contrib/win32/install/server.wxs Adds MSI component to create sshd.exe RedirectionGuard registry key

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@tgauth tgauth merged commit 92326c0 into PowerShell:latestw_all Oct 16, 2025
4 checks passed
@tgauth tgauth deleted the enable-redirection-guard branch October 16, 2025 13:50
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.

2 participants