{"id":2449,"date":"2018-09-10T19:52:22","date_gmt":"2018-09-10T14:22:22","guid":{"rendered":"https:\/\/pheonixsolutions.com\/blog\/?p=2449"},"modified":"2026-09-28T20:26:45","modified_gmt":"2026-09-28T14:56:45","slug":"how-to-configure-ssh-key-access-to-linux-server-using-windows-client","status":"publish","type":"post","link":"https:\/\/pheonixsolutions.com\/blog\/how-to-configure-ssh-key-access-to-linux-server-using-windows-client\/","title":{"rendered":"How to configure SSH Key access to a Linux server using Windows (client)?"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">Post Date: September 10, 2018<br>Last Updated: September 24, 2026<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Introduction<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">SSH key-based authentication provides a secure way to connect to a Linux server without entering the account password each time.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">In this setup, a <strong>Windows client<\/strong> uses PuTTY and PuTTYgen to generate and use an SSH key pair, while the Linux server uses OpenSSH to authenticate the connection.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">SSH key authentication uses two keys:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Private Key<\/strong> \u2013 Stored securely on the Windows client and should never be shared.<\/li>\n\n\n\n<li><strong>Public Key<\/strong> \u2013 Added to the Linux user&#8217;s <code>authorized_keys<\/code> file.<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\">When the client connects to the server, the SSH server verifies that the client has the corresponding private key. If authentication succeeds, the user can access the server without entering the Linux account password.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">This article explains how to configure SSH key-based authentication between a Windows client and a Linux server using <strong>PuTTY and PuTTYgen<\/strong>.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Prerequisites<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Before starting, ensure that you have:<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>A Linux server with OpenSSH installed.<\/li>\n\n\n\n<li>SSH access to the Linux server using an existing password.<\/li>\n\n\n\n<li>A Windows client.<\/li>\n\n\n\n<li>PuTTY installed on the Windows client.<\/li>\n\n\n\n<li>PuTTYgen installed on the Windows client.<\/li>\n\n\n\n<li>A Linux user account for which SSH key authentication will be configured.<\/li>\n<\/ol>\n\n\n\n<h3 class=\"wp-block-heading\">Environment Used<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">This example assumes:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Linux Server:<\/strong> CentOS 7<\/li>\n\n\n\n<li><strong>Windows Client:<\/strong> Windows 10<\/li>\n\n\n\n<li><strong>SSH Server:<\/strong> OpenSSH<\/li>\n\n\n\n<li><strong>SSH Client:<\/strong> PuTTY<\/li>\n\n\n\n<li><strong>Key Generation Tool:<\/strong> PuTTYgen<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\">The same general approach can also be used with other Linux distributions such as Ubuntu and Debian.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Understanding SSH Key Authentication<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">SSH key authentication uses a key pair consisting of a <strong>public key<\/strong> and a <strong>private key<\/strong>.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">The private key remains on the client machine and must be protected carefully. The public key is placed on the Linux server in the user&#8217;s SSH configuration.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">The public key is normally stored in:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">~\/.ssh\/authorized_keys<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">For example, for a user named <code>admin<\/code>:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">\/home\/admin\/.ssh\/authorized_keys<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">During authentication, the SSH server verifies that the connecting client possesses the corresponding private key.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">SSH Authentication Flow<\/h3>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">Windows Client\n      \u2502\n      \u2502 Private Key\n      \u25bc\n   PuTTY\n      \u2502\n      \u2502 SSH Connection\n      \u25bc\nLinux Server\n      \u2502\n      \u2502 Checks Public Key\n      \u25bc\n~\/.ssh\/authorized_keys\n      \u2502\n      \u25bc\nAuthentication Successful\n      \u2502\n      \u25bc\nSSH Session<\/pre>\n\n\n\n<blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\">\n<p class=\"wp-block-paragraph\"><strong>Security Note:<\/strong> Never share or upload the private key to the server. Only the public key should be installed on the Linux server.<\/p>\n<\/blockquote>\n\n\n\n<h1 class=\"wp-block-heading\">Implementation<\/h1>\n\n\n\n<h2 class=\"wp-block-heading\">Step 1: Install PuTTY and PuTTYgen.<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Download and install <strong>PuTTY<\/strong> and <strong>PuTTYgen<\/strong> on the Windows client.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">PuTTY is used to establish the SSH connection, while PuTTYgen is used to generate the SSH key pair.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Step 2: Generate an SSH Key Pair<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Open <strong>PuTTYgen<\/strong> on the Windows machine.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Generate a new SSH key pair by following these steps:<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>Open PuTTYgen.<\/li>\n\n\n\n<li>Select the appropriate key type supported by your environment.<\/li>\n\n\n\n<li>Generate the key pair.<\/li>\n\n\n\n<li>Move the mouse over the blank area when prompted to generate randomness.<\/li>\n\n\n\n<li>Enter a <strong>key passphrase<\/strong>.<\/li>\n\n\n\n<li>Save the private key securely.<\/li>\n\n\n\n<li>Copy the generated public key.<\/li>\n<\/ol>\n\n\n\n<p class=\"wp-block-paragraph\">The passphrase provides an additional layer of protection for the private key.<\/p>\n\n\n\n<blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\">\n<p class=\"wp-block-paragraph\"><strong>Important:<\/strong> Keep the private key and its passphrase secure. Anyone who obtains the private key and can use it may be able to authenticate as the associated user.<\/p>\n<\/blockquote>\n\n\n\n<h2 class=\"wp-block-heading\">Step 3: Log in to the Linux Server<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Log in to the Linux server using the existing password-based SSH access.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">For example:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">ssh username@SERVER_IP<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Replace <code>username<\/code> and <code>SERVER_IP<\/code> with the appropriate values.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Step 4: Create the <code>.ssh<\/code> Directory<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Navigate to the user&#8217;s home directory:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">cd ~<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Check whether the <code>.ssh<\/code> directory exists:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">ls -la<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">If it does not exist, create it:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">mkdir -p ~\/.ssh<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Set the appropriate permissions:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">chmod 700 ~\/.ssh<\/pre>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h2 class=\"wp-block-heading\">Step 5: Add the Public Key<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Navigate to the <code>.ssh<\/code> directory:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">cd ~\/.ssh<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Create or edit the authorized keys file:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">vi authorized_keys<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Copy the <strong>public key generated by PuTTYgen<\/strong> and paste it into this file as a single line.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Alternatively, if you have copied the public key to the clipboard, you can append it using an appropriate shell command.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">For example:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">echo 'PASTE_PUBLIC_KEY_HERE' >> ~\/.ssh\/authorized_keys<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Set the appropriate permissions:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">chmod 600 ~\/.ssh\/authorized_keys<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Make sure the files are owned by the correct Linux user:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">chown -R username:username ~\/.ssh<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Replace <code>username<\/code> with the actual account name.<\/p>\n\n\n\n<blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\">\n<p class=\"wp-block-paragraph\"><strong>Important:<\/strong> The filename is <code>authorized_keys<\/code>, not <code>authorization_keys<\/code>.<\/p>\n<\/blockquote>\n\n\n\n<h2 class=\"wp-block-heading\">Step 6: Configure PuTTY to Use the Private Key<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Open PuTTY on the Windows client.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Enter the Linux server&#8217;s IP address or hostname.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Navigate to:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">Connection\n\u2192 SSH\n\u2192 Auth<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Under the private key configuration, select the private key file generated and saved using PuTTYgen.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">If your PuTTY version provides the <strong>Credentials<\/strong> section, the private key option will be available there.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Step 7: Configure the SSH Username<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">In PuTTY, navigate to:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">Connection\n\u2192 Data<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Enter the username that corresponds to the public key installed on the server.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Alternatively, you can enter the username when PuTTY prompts for login.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">For example:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">login as: username<\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">Step 8: Connect to the Linux Server<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Start the SSH connection from PuTTY.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">The server should recognize the public key associated with the private key configured in PuTTY.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">If the private key has a passphrase, PuTTY will request it.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">After successful authentication, you should receive an SSH shell without needing to enter the Linux account password.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Example:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">login as: admin\nAuthenticating with public key \"admin-key\"\nPassphrase for key \"admin-key\":<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">After entering the correct passphrase, the SSH session should open.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Step 9: Verify Key-Based Authentication<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Once logged in, verify that the session was authenticated using the configured SSH key.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">If troubleshooting is required, use verbose SSH output from a compatible client:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">ssh -v username@SERVER_IP<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">For PuTTY, you can also review the session and connection logs through the PuTTY configuration options.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h2 class=\"wp-block-heading\">Troubleshooting<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">If SSH key authentication does not work, check the following.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Check <code>.ssh<\/code> Permissions<\/h3>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">chmod 700 ~\/.ssh\nchmod 600 ~\/.ssh\/authorized_keys<\/pre>\n\n\n\n<h3 class=\"wp-block-heading\">Check Ownership<\/h3>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">chown -R username:username ~\/.ssh<\/pre>\n\n\n\n<h3 class=\"wp-block-heading\">Verify the Public Key<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Make sure the public key in:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">~\/.ssh\/authorized_keys<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">matches the key pair generated by PuTTYgen.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Check the SSH Service<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">On CentOS 7:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">systemctl status sshd<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">If necessary:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">systemctl restart sshd<\/pre>\n\n\n\n<h3 class=\"wp-block-heading\">Check SSH Configuration<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">The SSH server configuration is normally located at:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">\/etc\/ssh\/sshd_config<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Verify that public-key authentication is enabled according to the server&#8217;s SSH configuration.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">After modifying the configuration, validate it before restarting SSH:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">sshd -t<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">If the configuration is valid, restart the service:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">systemctl restart sshd<\/pre>\n\n\n\n<blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\">\n<p class=\"wp-block-paragraph\"><strong>Warning:<\/strong> Be careful when modifying SSH configuration on a remote server. Keep an existing administrative session open until the new configuration has been tested successfully so that an incorrect configuration does not lock you out.<\/p>\n<\/blockquote>\n\n\n\n<h2 class=\"wp-block-heading\">Conclusion<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">SSH key-based authentication provides a convenient and secure way to access Linux servers from Windows without relying on password authentication for every login.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">The process involves:<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>Installing PuTTY and PuTTYgen.<\/li>\n\n\n\n<li>Generating a public\/private SSH key pair.<\/li>\n\n\n\n<li>Keeping the private key securely on the Windows client.<\/li>\n\n\n\n<li>Adding the public key to the Linux user&#8217;s <code>~\/.ssh\/authorized_keys<\/code>.<\/li>\n\n\n\n<li>Configuring PuTTY to use the private key.<\/li>\n\n\n\n<li>Connecting to the Linux server using the configured key.<\/li>\n<\/ol>\n\n\n\n<p class=\"wp-block-paragraph\">Using a passphrase-protected private key provides an additional layer of protection if the private key file is ever exposed.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">FAQ<\/h2>\n\n\n\n<h4 class=\"wp-block-heading\">1. What is SSH key authentication?<\/h4>\n\n\n\n<p class=\"wp-block-paragraph\">SSH key authentication is a method of authenticating to an SSH server using a cryptographic key pair instead of relying solely on a password.<\/p>\n\n\n\n<h4 class=\"wp-block-heading\">2. Where should the public key be stored?<\/h4>\n\n\n\n<p class=\"wp-block-paragraph\">The public key should be added to:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">~\/.ssh\/authorized_keys<\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">for the Linux user who will use the key.<\/p>\n\n\n\n<h4 class=\"wp-block-heading\">3. Where should the private key be stored?<\/h4>\n\n\n\n<p class=\"wp-block-paragraph\">The private key should remain securely on the Windows client. It should not be copied to the Linux server or shared with other users.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Related Articles<\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Bash Script to Capture Login Activity Logs<\/strong><\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\">Talk to our experts<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Looking for the right technology solution for your business? Our team of experts can help you with development, cloud, DevOps, design, and a wide range of other technology needs. Get in touch with our team <a target=\"_blank\" rel=\"noreferrer noopener\" href=\"https:\/\/pheonixsolutions.com\/contact?utm_source=chatgpt.com\">here<\/a>.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Post Date: September 10, 2018Last Updated: September 24, 2026 Introduction SSH key-based authentication provides a secure way to connect to [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"site-sidebar-layout":"default","site-content-layout":"","ast-site-content-layout":"default","site-content-style":"default","site-sidebar-style":"default","ast-global-header-display":"","ast-banner-title-visibility":"","ast-main-header-display":"","ast-hfb-above-header-display":"","ast-hfb-below-header-display":"","ast-hfb-mobile-header-display":"","site-post-title":"","ast-breadcrumbs-content":"","ast-featured-img":"","footer-sml-layout":"","ast-disable-related-posts":"","theme-transparent-header-meta":"","adv-header-id-meta":"","stick-header-meta":"","header-above-stick-meta":"","header-main-stick-meta":"","header-below-stick-meta":"","astra-migrate-meta-layouts":"default","ast-page-background-enabled":"default","ast-page-background-meta":{"desktop":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"ast-content-background-meta":{"desktop":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":false,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2},"jetpack_post_was_ever_published":false},"categories":[1024],"tags":[410,411,334,409],"class_list":["post-2449","post","type-post","status-publish","format-standard","hentry","category-security","tag-key-authentication","tag-puttygen","tag-ssh-key","tag-windows-client-remote-access-to-linux-server","psol-cat-security"],"jetpack_publicize_connections":[],"jetpack_shortlink":"https:\/\/wp.me\/phn2x7-Dv","jetpack_sharing_enabled":true,"jetpack_featured_media_url":"","_links":{"self":[{"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/posts\/2449","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/comments?post=2449"}],"version-history":[{"count":2,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/posts\/2449\/revisions"}],"predecessor-version":[{"id":11986,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/posts\/2449\/revisions\/11986"}],"wp:attachment":[{"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/media?parent=2449"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/categories?post=2449"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/tags?post=2449"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}