{"id":10864,"date":"2024-01-14T06:12:20","date_gmt":"2024-01-14T06:12:20","guid":{"rendered":"https:\/\/greenwebpage.com\/community\/?p=10864"},"modified":"2024-03-30T11:18:53","modified_gmt":"2024-03-30T11:18:53","slug":"how-to-set-up-ssh-keys-on-ubuntu-22-04","status":"publish","type":"post","link":"https:\/\/greenwebpage.com\/community\/how-to-set-up-ssh-keys-on-ubuntu-22-04\/","title":{"rendered":"How to Set Up SSH Keys on Ubuntu 22.04"},"content":{"rendered":"<p><a href=\"https:\/\/www.openssh.com\/\"><strong>SSH<\/strong><\/a> key is a set of cryptographic keys which is used to create secure communication channels. This key pair is composed of private and public keys and enables secure authentication without the need for passwords.<\/p>\n<p>When connecting remotely, the server recognizes your public key and grants you access. SSH uses different algorithms, such as RSA, DSA, ECDSA, and Ed25519, to generate this pair of keys.<\/p>\n<p>This post covers the procedure for establishing SSH keys on Ubuntu 22.04.<\/p>\n<h2><strong>How to Set Up SSH Keys on Ubuntu 22.04?<\/strong><\/h2>\n<p>These are the essential steps to set up SSH keys on the Ubuntu 22.04 operating system.<\/p>\n<h3><strong>Step 1: Install OpenSSH Server<\/strong><\/h3>\n<p>For secure communication via SSH and set up SSH keys on your Ubuntu 22.04 system, it is necessary to install the OpenSSH server:<\/p>\n<table>\n<thead>\n<tr>\n<th>\n<pre>sudo apt install openssh-server -y<\/pre>\n<\/th>\n<\/tr>\n<\/thead>\n<\/table>\n<pre><img fetchpriority=\"high\" decoding=\"async\" width=\"978\" height=\"579\" class=\"wp-image-10865\" src=\"http:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-1.png\" srcset=\"https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-1.png 978w, https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-1-300x178.png 300w, https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-1-768x455.png 768w\" sizes=\"(max-width: 978px) 100vw, 978px\" \/> <img decoding=\"async\" width=\"979\" height=\"581\" class=\"wp-image-10866\" src=\"http:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-2.png\" srcset=\"https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-2.png 979w, https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-2-300x178.png 300w, https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-2-768x456.png 768w\" sizes=\"(max-width: 979px) 100vw, 979px\" \/><\/pre>\n<p>If the command runs without any error, it confirms that the package is successfully installed on your Ubuntu machine.<\/p>\n<h3><strong>Step 2: Check OpenSSH Server Status<\/strong><\/h3>\n<p>Run the command to check that the OpenSSH server is running properly on your machine:<\/p>\n<table>\n<thead>\n<tr>\n<th>\n<pre>sudo systemctl status ssh<\/pre>\n<\/th>\n<\/tr>\n<\/thead>\n<\/table>\n<pre><img decoding=\"async\" width=\"975\" height=\"465\" class=\"wp-image-10867\" src=\"http:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-3.png\" srcset=\"https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-3.png 975w, https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-3-300x143.png 300w, https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-3-768x366.png 768w\" sizes=\"(max-width: 975px) 100vw, 975px\" \/><\/pre>\n<p>Make sure the status is <strong>Active<\/strong> after executing the command.<\/p>\n<h3><strong>Step 3: Generate SSH Key Pair<\/strong><\/h3>\n<p>After installing the OpenSSH server, you can now generate an SSH key pair using the simple command:<\/p>\n<table>\n<thead>\n<tr>\n<th>\n<pre>ssh-keygen<\/pre>\n<\/th>\n<\/tr>\n<\/thead>\n<\/table>\n<pre><img loading=\"lazy\" decoding=\"async\" width=\"972\" height=\"556\" class=\"wp-image-10868\" src=\"http:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-4.png\" srcset=\"https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-4.png 972w, https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-4-300x172.png 300w, https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-4-768x439.png 768w\" sizes=\"(max-width: 972px) 100vw, 972px\" \/><\/pre>\n<p>The output will provide information about the default SSH key pair, including your key&#8217;s location, algorithm(RSA), and bits (3072).<\/p>\n<p>You can also specify algorithms and bits as per your requirements using the syntax:<\/p>\n<table>\n<thead>\n<tr>\n<th>\n<pre>ssh-keygen -t &lt;algorithm: rsa,dsa&gt; -b &lt;bits: 2048,3072&gt;<\/pre>\n<\/th>\n<\/tr>\n<\/thead>\n<\/table>\n<h3><strong>Step 4: Locate the SSH Keys<\/strong><\/h3>\n<p>To check for SSH keys in your local directory, navigate to <strong>~\/.ssh<\/strong>, and then run the command to view the generated SSH key pairs:<\/p>\n<table>\n<thead>\n<tr>\n<th>\n<pre>ls<\/pre>\n<\/th>\n<\/tr>\n<\/thead>\n<\/table>\n<pre><img loading=\"lazy\" decoding=\"async\" width=\"884\" height=\"77\" class=\"wp-image-10869\" src=\"http:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-5.png\" srcset=\"https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-5.png 884w, https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-5-300x26.png 300w, https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-5-768x67.png 768w\" sizes=\"(max-width: 884px) 100vw, 884px\" \/><\/pre>\n<p>There will be two files, id_rsa and id_rsa.pub in your ~\/.ssh folder, where the <strong>id_rsa<\/strong> file is the private key, while the<strong> id_rsa.pub<\/strong> file is the public key in the SSH key pair.<\/p>\n<h3><strong>Step 5: Copy SSH Key to Server<\/strong><\/h3>\n<p>Use the following syntax to add the generated public key to the remote server:<\/p>\n<table>\n<thead>\n<tr>\n<th>\n<pre>ssh-copy-id techpub@127.0.0.1<\/pre>\n<\/th>\n<\/tr>\n<\/thead>\n<\/table>\n<pre><img loading=\"lazy\" decoding=\"async\" width=\"974\" height=\"459\" class=\"wp-image-10870\" src=\"http:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-6.png\" srcset=\"https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-6.png 974w, https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-6-300x141.png 300w, https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-6-768x362.png 768w\" sizes=\"(max-width: 974px) 100vw, 974px\" \/><\/pre>\n<p>When the command executes, it will prompt a few questions, and answer them accordingly.<\/p>\n<p>Don&#8217;t forget to replace the <strong>techpub@127.0.0.1<\/strong> with your own\/preferred server.<\/p>\n<h3><strong>Step 6: Copy a Particular Key to Server<\/strong><\/h3>\n<p>OpenSSH allows you to copy a particular key to the server. Use the <strong>-i<\/strong> option followed by the key\u2019s path in the following way:<\/p>\n<table>\n<thead>\n<tr>\n<th>\n<pre>ssh-copy-id -i ~\/.ssh\/id_rsa.pub techpub@127.0.0.1<\/pre>\n<\/th>\n<\/tr>\n<\/thead>\n<\/table>\n<pre><img loading=\"lazy\" decoding=\"async\" width=\"974\" height=\"462\" class=\"wp-image-10871\" src=\"http:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-7.png\" srcset=\"https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-7.png 974w, https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-7-300x142.png 300w, https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-7-768x364.png 768w\" sizes=\"(max-width: 974px) 100vw, 974px\" \/><\/pre>\n<p>This command adds the SSH key to the remote server. You can verify the number of keys added to the server in the output.<\/p>\n<h3><strong>Step 7: Test the SSH Connection<\/strong><\/h3>\n<p>After completing the aforementioned process to set up an SSH key, run the command to test the connection:<\/p>\n<table>\n<thead>\n<tr>\n<th>\n<pre>ssh techpub@127.0.0.1<\/pre>\n<\/th>\n<\/tr>\n<\/thead>\n<\/table>\n<pre><img loading=\"lazy\" decoding=\"async\" width=\"969\" height=\"365\" class=\"wp-image-10872\" src=\"http:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-8.png\" srcset=\"https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-8.png 969w, https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-8-300x113.png 300w, https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-8-768x289.png 768w\" sizes=\"(max-width: 969px) 100vw, 969px\" \/><\/pre>\n<p>If you have successfully logged into the remote server from your terminal, the SSH key is set up correctly.<\/p>\n<h2><strong>How to Remove the SSH Key From the Remote Server?<\/strong><\/h2>\n<p>You can remove the SSH key from the remote server at any time with these steps.<\/p>\n<h3><strong>Step 1: Navigate the SSH Keys<\/strong><\/h3>\n<p>To remove the SSH key from the remote server, log in to it, and then run the following command to navigate the keys:<\/p>\n<table>\n<thead>\n<tr>\n<th>\n<pre>sudo nano ~\/.ssh\/authorized_keys<\/pre>\n<\/th>\n<\/tr>\n<\/thead>\n<\/table>\n<pre><img loading=\"lazy\" decoding=\"async\" width=\"966\" height=\"75\" class=\"wp-image-10873\" src=\"http:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-9.png\" srcset=\"https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-9.png 966w, https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-9-300x23.png 300w, https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-9-768x60.png 768w, https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-9-960x75.png 960w\" sizes=\"(max-width: 966px) 100vw, 966px\" \/><\/pre>\n<h3><strong>Step 2: Remove the SSH Key<\/strong><\/h3>\n<p>The command <strong>sudo nano ~\/.ssh\/authorized_keys <\/strong>will open the key files in the Nano editor. Navigate to the line containing the key you want to remove, and then use <strong>Ctrl + K<\/strong> on your keyboard to delete the key:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"975\" height=\"627\" class=\"wp-image-10874\" src=\"http:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-10.png\" srcset=\"https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-10.png 975w, https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-10-300x193.png 300w, https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-10-768x494.png 768w\" sizes=\"(max-width: 975px) 100vw, 975px\" \/><\/p>\n<p>To exit the Nano editor after removing the key, press <strong>Ctrl + X<\/strong>.<\/p>\n<h3><strong>Step 3: Exit the SSH session<\/strong><\/h3>\n<p>To exit or logout from the remote server session, simply type:<\/p>\n<table>\n<thead>\n<tr>\n<th>\n<pre>exit<\/pre>\n<\/th>\n<\/tr>\n<\/thead>\n<\/table>\n<p><img loading=\"lazy\" decoding=\"async\" width=\"945\" height=\"99\" class=\"wp-image-10875\" src=\"http:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-11.png\" srcset=\"https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-11.png 945w, https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-11-300x31.png 300w, https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/word-image-10864-11-768x80.png 768w\" sizes=\"(max-width: 945px) 100vw, 945px\" \/><\/p>\n<p>After using the <strong>exit<\/strong> command, you will be logged out and then the remote connection will be closed.<\/p>\n<h2><strong>Conclusion<\/strong><\/h2>\n<p>Setting up SSH keys on Ubuntu 22.04 enhances security while establishing a <a href=\"https:\/\/greenwebpage.com\/community\/how-to-use-ssh-to-connect-to-a-remote-server-on-ubuntu-22-04\/\">connection to a remote server<\/a>. Installing OpenSSH packages is a prerequisite to generating and setting up SSH keys.<\/p>\n<p>Utilize the command <strong>sudo apt install openssh-server -y<\/strong> to install the package and then use the <strong>ssh-keygen<\/strong> command to generate an SSH key with the RSA algorithm. This post illustrated the procedure of how to set up an SSH key on Ubuntu 22.04.<\/p>\n\n    <div class=\"xs_social_share_widget xs_share_url after_content \t\tmain_content  wslu-style-1 wslu-share-box-shaped wslu-fill-colored wslu-none wslu-share-horizontal wslu-theme-font-no wslu-main_content\">\n\n\t\t\n        <ul>\n\t\t\t        <\/ul>\n    <\/div> \n","protected":false},"excerpt":{"rendered":"<p>SSH key is a set of cryptographic keys which is used to create secure communication channels. This key pair is composed of private and public keys and enables secure authentication without the need for passwords. When connecting remotely, the server recognizes your public key and grants you access. SSH uses different algorithms, such as RSA, [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":10876,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[43],"tags":[266,224],"class_list":["post-10864","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-tutorials","tag-ssh","tag-ubuntu-22-04"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v26.5 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>How to Set Up SSH Keys on Ubuntu 22.04 - Greenwebpage Community<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/greenwebpage.com\/community\/how-to-set-up-ssh-keys-on-ubuntu-22-04\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"How to Set Up SSH Keys on Ubuntu 22.04 - Greenwebpage Community\" \/>\n<meta property=\"og:description\" content=\"SSH key is a set of cryptographic keys which is used to create secure communication channels. This key pair is composed of private and public keys and enables secure authentication without the need for passwords. When connecting remotely, the server recognizes your public key and grants you access. SSH uses different algorithms, such as RSA, [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/greenwebpage.com\/community\/how-to-set-up-ssh-keys-on-ubuntu-22-04\/\" \/>\n<meta property=\"og:site_name\" content=\"Greenwebpage Community\" \/>\n<meta property=\"article:published_time\" content=\"2024-01-14T06:12:20+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2024-03-30T11:18:53+00:00\" \/>\n<meta property=\"og:image\" content=\"http:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/How-to-Set-Up-SSH-Keys-on-Ubuntu-22.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"1020\" \/>\n\t<meta property=\"og:image:height\" content=\"600\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"Karim Buzdar\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Karim Buzdar\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"4 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/greenwebpage.com\/community\/how-to-set-up-ssh-keys-on-ubuntu-22-04\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/greenwebpage.com\/community\/how-to-set-up-ssh-keys-on-ubuntu-22-04\/\"},\"author\":{\"name\":\"Karim Buzdar\",\"@id\":\"https:\/\/greenwebpage.com\/community\/#\/schema\/person\/467c100c1d017bc081473ee0440680c8\"},\"headline\":\"How to Set Up SSH Keys on Ubuntu 22.04\",\"datePublished\":\"2024-01-14T06:12:20+00:00\",\"dateModified\":\"2024-03-30T11:18:53+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/greenwebpage.com\/community\/how-to-set-up-ssh-keys-on-ubuntu-22-04\/\"},\"wordCount\":666,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\/\/greenwebpage.com\/community\/#organization\"},\"image\":{\"@id\":\"https:\/\/greenwebpage.com\/community\/how-to-set-up-ssh-keys-on-ubuntu-22-04\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/How-to-Set-Up-SSH-Keys-on-Ubuntu-22.jpg\",\"keywords\":[\"SSH\",\"Ubuntu 22.04\"],\"articleSection\":[\"Tutorials\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/greenwebpage.com\/community\/how-to-set-up-ssh-keys-on-ubuntu-22-04\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/greenwebpage.com\/community\/how-to-set-up-ssh-keys-on-ubuntu-22-04\/\",\"url\":\"https:\/\/greenwebpage.com\/community\/how-to-set-up-ssh-keys-on-ubuntu-22-04\/\",\"name\":\"How to Set Up SSH Keys on Ubuntu 22.04 - Greenwebpage Community\",\"isPartOf\":{\"@id\":\"https:\/\/greenwebpage.com\/community\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/greenwebpage.com\/community\/how-to-set-up-ssh-keys-on-ubuntu-22-04\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/greenwebpage.com\/community\/how-to-set-up-ssh-keys-on-ubuntu-22-04\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/How-to-Set-Up-SSH-Keys-on-Ubuntu-22.jpg\",\"datePublished\":\"2024-01-14T06:12:20+00:00\",\"dateModified\":\"2024-03-30T11:18:53+00:00\",\"breadcrumb\":{\"@id\":\"https:\/\/greenwebpage.com\/community\/how-to-set-up-ssh-keys-on-ubuntu-22-04\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/greenwebpage.com\/community\/how-to-set-up-ssh-keys-on-ubuntu-22-04\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/greenwebpage.com\/community\/how-to-set-up-ssh-keys-on-ubuntu-22-04\/#primaryimage\",\"url\":\"https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/How-to-Set-Up-SSH-Keys-on-Ubuntu-22.jpg\",\"contentUrl\":\"https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/How-to-Set-Up-SSH-Keys-on-Ubuntu-22.jpg\",\"width\":1020,\"height\":600,\"caption\":\"How to Set Up SSH Keys on Ubuntu 22\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/greenwebpage.com\/community\/how-to-set-up-ssh-keys-on-ubuntu-22-04\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/greenwebpage.com\/community\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"How to Set Up SSH Keys on Ubuntu 22.04\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/greenwebpage.com\/community\/#website\",\"url\":\"https:\/\/greenwebpage.com\/community\/\",\"name\":\"Greenwebpage Community\",\"description\":\"Get online in three steps with our wide range of web hosting solutions. Choose from professional business to enterprise options designed to meet your needs.\",\"publisher\":{\"@id\":\"https:\/\/greenwebpage.com\/community\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/greenwebpage.com\/community\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/greenwebpage.com\/community\/#organization\",\"name\":\"Greenwebpage Community\",\"url\":\"https:\/\/greenwebpage.com\/community\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/greenwebpage.com\/community\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2023\/10\/cropped-logomic.png\",\"contentUrl\":\"https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2023\/10\/cropped-logomic.png\",\"width\":512,\"height\":512,\"caption\":\"Greenwebpage Community\"},\"image\":{\"@id\":\"https:\/\/greenwebpage.com\/community\/#\/schema\/logo\/image\/\"}},{\"@type\":\"Person\",\"@id\":\"https:\/\/greenwebpage.com\/community\/#\/schema\/person\/467c100c1d017bc081473ee0440680c8\",\"name\":\"Karim Buzdar\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/greenwebpage.com\/community\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/0628fcbcddd9bc5486245d2cf4a904dbcdeac9ad6c3098f49237094e9d513d0c?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/0628fcbcddd9bc5486245d2cf4a904dbcdeac9ad6c3098f49237094e9d513d0c?s=96&d=mm&r=g\",\"caption\":\"Karim Buzdar\"},\"sameAs\":[\"https:\/\/greenwebpage.com\"],\"url\":\"https:\/\/greenwebpage.com\/community\/author\/karim\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"How to Set Up SSH Keys on Ubuntu 22.04 - Greenwebpage Community","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/greenwebpage.com\/community\/how-to-set-up-ssh-keys-on-ubuntu-22-04\/","og_locale":"en_US","og_type":"article","og_title":"How to Set Up SSH Keys on Ubuntu 22.04 - Greenwebpage Community","og_description":"SSH key is a set of cryptographic keys which is used to create secure communication channels. This key pair is composed of private and public keys and enables secure authentication without the need for passwords. When connecting remotely, the server recognizes your public key and grants you access. SSH uses different algorithms, such as RSA, [&hellip;]","og_url":"https:\/\/greenwebpage.com\/community\/how-to-set-up-ssh-keys-on-ubuntu-22-04\/","og_site_name":"Greenwebpage Community","article_published_time":"2024-01-14T06:12:20+00:00","article_modified_time":"2024-03-30T11:18:53+00:00","og_image":[{"width":1020,"height":600,"url":"http:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/How-to-Set-Up-SSH-Keys-on-Ubuntu-22.jpg","type":"image\/jpeg"}],"author":"Karim Buzdar","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Karim Buzdar","Est. reading time":"4 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/greenwebpage.com\/community\/how-to-set-up-ssh-keys-on-ubuntu-22-04\/#article","isPartOf":{"@id":"https:\/\/greenwebpage.com\/community\/how-to-set-up-ssh-keys-on-ubuntu-22-04\/"},"author":{"name":"Karim Buzdar","@id":"https:\/\/greenwebpage.com\/community\/#\/schema\/person\/467c100c1d017bc081473ee0440680c8"},"headline":"How to Set Up SSH Keys on Ubuntu 22.04","datePublished":"2024-01-14T06:12:20+00:00","dateModified":"2024-03-30T11:18:53+00:00","mainEntityOfPage":{"@id":"https:\/\/greenwebpage.com\/community\/how-to-set-up-ssh-keys-on-ubuntu-22-04\/"},"wordCount":666,"commentCount":0,"publisher":{"@id":"https:\/\/greenwebpage.com\/community\/#organization"},"image":{"@id":"https:\/\/greenwebpage.com\/community\/how-to-set-up-ssh-keys-on-ubuntu-22-04\/#primaryimage"},"thumbnailUrl":"https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/How-to-Set-Up-SSH-Keys-on-Ubuntu-22.jpg","keywords":["SSH","Ubuntu 22.04"],"articleSection":["Tutorials"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/greenwebpage.com\/community\/how-to-set-up-ssh-keys-on-ubuntu-22-04\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/greenwebpage.com\/community\/how-to-set-up-ssh-keys-on-ubuntu-22-04\/","url":"https:\/\/greenwebpage.com\/community\/how-to-set-up-ssh-keys-on-ubuntu-22-04\/","name":"How to Set Up SSH Keys on Ubuntu 22.04 - Greenwebpage Community","isPartOf":{"@id":"https:\/\/greenwebpage.com\/community\/#website"},"primaryImageOfPage":{"@id":"https:\/\/greenwebpage.com\/community\/how-to-set-up-ssh-keys-on-ubuntu-22-04\/#primaryimage"},"image":{"@id":"https:\/\/greenwebpage.com\/community\/how-to-set-up-ssh-keys-on-ubuntu-22-04\/#primaryimage"},"thumbnailUrl":"https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/How-to-Set-Up-SSH-Keys-on-Ubuntu-22.jpg","datePublished":"2024-01-14T06:12:20+00:00","dateModified":"2024-03-30T11:18:53+00:00","breadcrumb":{"@id":"https:\/\/greenwebpage.com\/community\/how-to-set-up-ssh-keys-on-ubuntu-22-04\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/greenwebpage.com\/community\/how-to-set-up-ssh-keys-on-ubuntu-22-04\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/greenwebpage.com\/community\/how-to-set-up-ssh-keys-on-ubuntu-22-04\/#primaryimage","url":"https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/How-to-Set-Up-SSH-Keys-on-Ubuntu-22.jpg","contentUrl":"https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2024\/01\/How-to-Set-Up-SSH-Keys-on-Ubuntu-22.jpg","width":1020,"height":600,"caption":"How to Set Up SSH Keys on Ubuntu 22"},{"@type":"BreadcrumbList","@id":"https:\/\/greenwebpage.com\/community\/how-to-set-up-ssh-keys-on-ubuntu-22-04\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/greenwebpage.com\/community\/"},{"@type":"ListItem","position":2,"name":"How to Set Up SSH Keys on Ubuntu 22.04"}]},{"@type":"WebSite","@id":"https:\/\/greenwebpage.com\/community\/#website","url":"https:\/\/greenwebpage.com\/community\/","name":"Greenwebpage Community","description":"Get online in three steps with our wide range of web hosting solutions. Choose from professional business to enterprise options designed to meet your needs.","publisher":{"@id":"https:\/\/greenwebpage.com\/community\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/greenwebpage.com\/community\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/greenwebpage.com\/community\/#organization","name":"Greenwebpage Community","url":"https:\/\/greenwebpage.com\/community\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/greenwebpage.com\/community\/#\/schema\/logo\/image\/","url":"https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2023\/10\/cropped-logomic.png","contentUrl":"https:\/\/greenwebpage.com\/community\/wp-content\/uploads\/2023\/10\/cropped-logomic.png","width":512,"height":512,"caption":"Greenwebpage Community"},"image":{"@id":"https:\/\/greenwebpage.com\/community\/#\/schema\/logo\/image\/"}},{"@type":"Person","@id":"https:\/\/greenwebpage.com\/community\/#\/schema\/person\/467c100c1d017bc081473ee0440680c8","name":"Karim Buzdar","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/greenwebpage.com\/community\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/0628fcbcddd9bc5486245d2cf4a904dbcdeac9ad6c3098f49237094e9d513d0c?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/0628fcbcddd9bc5486245d2cf4a904dbcdeac9ad6c3098f49237094e9d513d0c?s=96&d=mm&r=g","caption":"Karim Buzdar"},"sameAs":["https:\/\/greenwebpage.com"],"url":"https:\/\/greenwebpage.com\/community\/author\/karim\/"}]}},"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/greenwebpage.com\/community\/wp-json\/wp\/v2\/posts\/10864","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/greenwebpage.com\/community\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/greenwebpage.com\/community\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/greenwebpage.com\/community\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/greenwebpage.com\/community\/wp-json\/wp\/v2\/comments?post=10864"}],"version-history":[{"count":3,"href":"https:\/\/greenwebpage.com\/community\/wp-json\/wp\/v2\/posts\/10864\/revisions"}],"predecessor-version":[{"id":11230,"href":"https:\/\/greenwebpage.com\/community\/wp-json\/wp\/v2\/posts\/10864\/revisions\/11230"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/greenwebpage.com\/community\/wp-json\/wp\/v2\/media\/10876"}],"wp:attachment":[{"href":"https:\/\/greenwebpage.com\/community\/wp-json\/wp\/v2\/media?parent=10864"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/greenwebpage.com\/community\/wp-json\/wp\/v2\/categories?post=10864"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/greenwebpage.com\/community\/wp-json\/wp\/v2\/tags?post=10864"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}