Skip to content

[Security]Check file permissions of system wide ssh_config file. #1753

Closed
@bagajjal

Description

@bagajjal

Windows don't have a system-wide ssh folder ($env:Programdata\ssh) by default.
Assume a non-admin user creates the system-wide ssh folder and then the admin user installs the win32-OpenSSH.
Admin user later manually creates the system-wide ssh_config ($env:Programdata\ssh\ssh_config). By default, this file inherits the parent folder permissions i.e., the non-admin user has the write permission.
This is not desirable.

Proposed fix - ssh.exe should check the file permissions on system-wide ssh_config file. If this file has write permissions for non admin users then fail the ssh connection.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions