mirror of
https://github.com/PowerShell/Win32-OpenSSH.git
synced 2025-07-24 06:25:35 +02:00
Updated ssh.exe examples (markdown)
parent
5b881de8ef
commit
4698370637
@ -18,7 +18,8 @@
|
||||
3. Copy `id_rsa.pub` (client's public key) to corresponding user's directory on ssh HOST
|
||||
* as `%systemdrive%\users\user\.ssh\authorized_keys`
|
||||
4. Adjust permissions on authorized_keys file
|
||||
``` $authorizedKeyPath = "%systemdrive%\users\user\.ssh\authorized_keys"
|
||||
```
|
||||
$authorizedKeyPath = "%systemdrive%\users\user\.ssh\authorized_keys"
|
||||
$acl = get-acl $authorizedKeyPath
|
||||
$ar = New-Object System.Security.AccessControl.FileSystemAccessRule("NT Service\sshd", "Read", "Allow")
|
||||
$acl.SetAccessRule($ar)
|
||||
|
Loading…
x
Reference in New Issue
Block a user