Openssh Agent

Posted : admin On 1/29/2022

OpenSSH Authentication Agent (ssh-agent) Service Defaults in Windows 10

Agent to hold private keys used for public key authentication.

Default Settings

Startup type:
Windows 10 Home 1507N/A
Windows 10 Pro 1507N/A
Windows 10 Education 1507N/A
Windows 10 Enterprise 1507N/A
Windows 10 Home 1511N/A
Windows 10 Pro 1511N/A
Windows 10 Education 1511N/A
Windows 10 Enterprise 1511N/A
Windows 10 Home 1607N/A
Windows 10 Pro 1607N/A
Windows 10 Education 1607N/A
Windows 10 Enterprise 1607N/A
Windows 10 Home 1703N/A
Windows 10 Pro 1703N/A
Windows 10 Education 1703N/A
Windows 10 Enterprise 1703N/A
Windows 10 Home 1709N/A
Windows 10 Pro 1709N/A
Windows 10 Education 1709N/A
Windows 10 Enterprise 1709N/A
Windows 10 Home 1803Manual
Windows 10 Pro 1803Manual
Windows 10 Education 1803Manual
Windows 10 Enterprise 1803Manual
Windows 10 Home 1809Disabled
Windows 10 Pro 1809Disabled
Windows 10 Education 1809Disabled
Windows 10 Enterprise 1809Disabled
Windows 10 Home 1903Disabled
Windows 10 Pro 1903Disabled
Windows 10 Education 1903Disabled
Windows 10 Enterprise 1903Disabled
Windows 10 Home 2004Disabled
Windows 10 Pro 2004Disabled
Windows 10 Education 2004Disabled
Windows 10 Enterprise 2004Disabled
Windows 10 Home 20H2Disabled
Windows 10 Pro 20H2Disabled
Windows 10 Education 20H2Disabled
Windows 10 Enterprise 20H2Disabled
Display name:OpenSSH Authentication Agent
Service name:ssh-agent
Service type:own
Error control:normal
Object:LocalSystem
Path:%SystemRoot%System32OpenSSHssh-agent.exe
Registry key:HKEY_LOCAL_MACHINESYSTEMCurrentControlSetServicesssh-agent
Privileges:
  • SeImpersonatePrivilege

Default Behavior

Openssh

OpenSSH Authentication Agent is a Win32 service. It is starting only if the user, an application or another service starts it in all editions of Windows 10 1803. This service is disabled in all editions of Windows 10 1809, Windows 10 1903, Windows 10 2004, Windows 10 20H2.

Oct 09, 2020 Windows 10 already ships with OpenSSH Authentication Agent, which is disabled by default. Hence, if you execute ssh-agent in PowerShell, you will get the following error. Unable to start ssh-agent service, error:1058 It's just the matter of enabling the service either from PowerShell (as Admin) or from Services. The ssh-agent is a helper program that keeps track of user's identity keys and their passphrases. The agent can then use the keys to log into other servers without having the user type in a password or passphrase again. This implements a form of single sign-on (SSO). The SSH agent is used for SSH public key authentication. Secure Shell (SSH) is a protocol allowing secure remote login to a computer on a network using public-key cryptography. SSH client programs (such as ssh from OpenSSH) typically run for the duration of a remote login session and are configured to look for the user's private key in a file in the user's home directory (e.g.ssh/idrsa). The OpenSSH Authentication Agent service is running as LocalSystem in its own process of ssh-agent.exe. It doesn't share its process with other services. If OpenSSH Authentication Agent fails to start, the error is logged. Windows 10 startup proceeds, but a message box is displayed informing you that the ssh-agent service has failed to start. Set-Service ssh-agent -StartupType ‘Automatic’ Start-service ssh-agent Ssh-add.sshidrsa. Once you’ve done this, you’ll want to deploy your public key to the Windows Server 2019 server that you want to use SSH key based authentication with. To do this, perform the following steps (where chancellor is the name of the user account you.

When the OpenSSH Authentication Agent service is started, it is running as LocalSystem in its own process of ssh-agent.exe. If OpenSSH Authentication Agent fails to start, the failure details are being recorded into Event Log. Then Windows 10 will start up and notify the user that the ssh-agent service has failed to start due to the error.

Restore Default Startup Configuration for OpenSSH Authentication Agent

1. Run the Command Prompt as an administrator.

2. Depending on the version of your operating system, copy the commands below, paste them into the command window and press ENTER.

For Windows 10 1803 Home, Windows 10 1803 Pro, Windows 10 1803 Education, Windows 10 1803 Enterprise:
sc config ssh-agent start= demand

Openssh Agent

For Windows 10 1809 Home, Windows 10 1809 Pro, Windows 10 1809 Education, Windows 10 1809 Enterprise, Windows 10 1903 Home, Windows 10 1903 Pro, Windows 10 1903 Education, Windows 10 1903 Enterprise, Windows 10 1909 Home, Windows 10 1909 Pro, Windows 10 1909 Education, Windows 10 1909 Enterprise, Windows 10 2004 Home, Windows 10 2004 Pro, Windows 10 2004 Education, Windows 10 2004 Enterprise, Windows 10 20H2 Home, Windows 10 20H2 Pro, Windows 10 20H2 Education, Windows 10 20H2 Enterprise:
sc stop ssh-agent
sc config ssh-agent start= disabled

3. Close the command window and restart the computer.

Openssh Agent Forwarding

The ssh-agent service is using the ssh-agent.exe file that is located in the %WinDir%System32OpenSSH folder. If the file is changed, damaged or deleted, you can restore its original version from Windows 10 installation media.