<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>1-800-HOSTING Blog &#187; key-based ssh authentication</title>
	<atom:link href="http://blog.800hosting.com/tag/key-based-ssh-authentication/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.800hosting.com</link>
	<description>Inside 1-800-HOSTING</description>
	<lastBuildDate>Wed, 02 Nov 2011 17:00:58 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>Linux Tip: Setting up key-based authentication.</title>
		<link>http://blog.800hosting.com/2009/11/linux-tip-setting-up-key-based-authentication/</link>
		<comments>http://blog.800hosting.com/2009/11/linux-tip-setting-up-key-based-authentication/#comments</comments>
		<pubDate>Wed, 11 Nov 2009 21:05:06 +0000</pubDate>
		<dc:creator>John Cunningham</dc:creator>
				<category><![CDATA[Technology]]></category>
		<category><![CDATA[tips]]></category>
		<category><![CDATA[key-based ssh authentication]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[linux how-to]]></category>
		<category><![CDATA[linux tips]]></category>

		<guid isPermaLink="false">http://blog.800hosting.com/?p=865</guid>
		<description><![CDATA[In this post I&#8217;ll explain how to use key-based SSH authentication in Linux. This can be used either for non-password based authentication for scripts or other utilities, or for extra security when paired with a pass phrase key. We&#8217;ll need to generate a key-pair, a public-key and a private-key. The public-key will be placed on [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://blog.800hosting.com/2009/11/linux-tip-setting-up-key-based-authentication"><img class="size-full wp-image-877 alignright" title="linux-penguin" src="http://blog.800hosting.com/wp-content/uploads/2009/11/linux-penguin.jpg" alt="linux-penguin" width="125" height="148" /></a>In this post I&#8217;ll explain how to use key-based SSH authentication in Linux.</p>
<p>This can be used either for non-password based authentication for scripts or other utilities, or for extra security when paired with a pass phrase key.<span id="more-865"></span></p>
<p>We&#8217;ll need to generate a key-pair, a public-key and a private-key. The public-key will be placed on the server, and you will log in with your private-key. You will need to enter a passphrase for security (or leave blank for password-less auth.)</p>
<p>First generate the key:</p>
<blockquote><p>ssh-keygen -t rsa -b 1024 -C &#8220;your-email-address&#8221;</p></blockquote>
<p>This will create a 1024 bit key using RSA in your current directory. You will need to transfer it to the server you wish to authenticate with by some means, you can use SCP if you have an SCP client like this:</p>
<blockquote><p>scp -p id_rsa.pub user@server:~/</p></blockquote>
<p>Then log in to the remote server, and put the file in the authorized_keys for the user you want to authenticate with.</p>
<blockquote><p>mkdir ~/.ssh<br />
chmod 700 ~/.ssh<br />
cat ~/id_rsa.pub &gt;&gt; ~/.ssh/authorized_keys<br />
chmod 600 ~/.ssh/authorized_keys<br />
mv id_rsa.pub ~/.ssh</p></blockquote>
<p>Sometimes you may have to delete the public key file on the local machine to be able to log in, e.g.</p>
<blockquote><p>rm rsa.pub</p></blockquote>
<p>Once you&#8217;re done, try to log in to the remote host, and if everything was done right, you should be in!</p>
<h3  class="related_post_title">Related Posts</h3><ul class="related_post"><li><a href="http://blog.800hosting.com/2011/07/workstation-backup-solutions-pt-3-redundancy/" title="Workstation Backup Solutions Pt. 3: Redundancy">Workstation Backup Solutions Pt. 3: Redundancy</a></li><li><a href="http://blog.800hosting.com/2011/07/workstation-backup-solutions-pt-2-methods-retention/" title=" Workstation Backup Solutions Pt. 2: Methods &amp; Retention"> Workstation Backup Solutions Pt. 2: Methods &amp; Retention</a></li><li><a href="http://blog.800hosting.com/2011/06/workstation-backup-solutions-pt-1-having-one/" title="Workstation Backup Solutions Pt. 1: Having One">Workstation Backup Solutions Pt. 1: Having One</a></li><li><a href="http://blog.800hosting.com/2010/02/php-script-tips-and-resources/" title="PHP Script Tips and Resources">PHP Script Tips and Resources</a></li><li><a href="http://blog.800hosting.com/2009/12/a-little-security-goes-a-loooong-way/" title="A Little Security Goes a LOOOONG Way">A Little Security Goes a LOOOONG Way</a></li><li><a href="http://blog.800hosting.com/2009/12/drupal-free-website-building-tool/" title="Drupal &#8211; Free Website Building Tool">Drupal &#8211; Free Website Building Tool</a></li><li><a href="http://blog.800hosting.com/2009/06/memory_cache_in_linux/" title="Linux: Low memory &#8211; feature or a bug?">Linux: Low memory &#8211; feature or a bug?</a></li><li><a href="http://blog.800hosting.com/2009/05/linux-shell-insights-volume-2/" title="Linux Shell Insights: Volume 2">Linux Shell Insights: Volume 2</a></li><li><a href="http://blog.800hosting.com/2009/05/linux-shell-insights-volume-1/" title="Linux Shell Insights: Volume 1">Linux Shell Insights: Volume 1</a></li></ul>]]></content:encoded>
			<wfw:commentRss>http://blog.800hosting.com/2009/11/linux-tip-setting-up-key-based-authentication/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

