<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>The interent is hard</title>
    <description>Musings of a software engineer. Thoughts are mine only. Some random combination of DevOps, Distributed Systems, gay culture, and my side projects. 
</description>
    <link>https://bdawg.org/</link>
    <atom:link href="https://bdawg.org/feed.xml" rel="self" type="application/rss+xml"/>
    <pubDate>Sun, 06 Nov 2016 20:50:04 +0000</pubDate>
    <lastBuildDate>Sun, 06 Nov 2016 20:50:04 +0000</lastBuildDate>
    <generator>Jekyll v3.3.0</generator>
    
      <item>
        <title>Using the YubiKey4 as your SSH key</title>
        <description>&lt;p&gt;One of the more annoying things I deal with on a daily basis is having multiple laptops. I spend a lot of time &lt;code class=&quot;highlighter-rouge&quot;&gt;ssh&lt;/code&gt;ing to servers I own, or even more commonly &lt;code class=&quot;highlighter-rouge&quot;&gt;git clone&lt;/code&gt; and &lt;code class=&quot;highlighter-rouge&quot;&gt;git push&lt;/code&gt;ing stuff. Naturally, I use SSH for that as well.&lt;/p&gt;

&lt;p&gt;I own a &lt;a href=&quot;https://www.yubico.com/products/yubikey-hardware/yubikey4/&quot;&gt;YubiKey4&lt;/a&gt; and it’s simple enough, with decent instructions for how do normal &lt;a href=&quot;https://developers.yubico.com/yubico-piv-tool/SSH_with_PIV_and_PKCS11.html&quot;&gt;SSH Auth&lt;/a&gt; with it. Howerver, to my fellow devs looking, one thing it slightly misses it making sure SSH will use the YubiKey as a default smartcard/auth method.&lt;/p&gt;

&lt;p&gt;For OS X, I had to do&lt;/p&gt;

&lt;figure class=&quot;highlight&quot;&gt;&lt;pre&gt;&lt;code class=&quot;language-bash&quot; data-lang=&quot;bash&quot;&gt;&lt;span class=&quot;gp&quot;&gt;$ &lt;/span&gt;brew install OpenSC&lt;/code&gt;&lt;/pre&gt;&lt;/figure&gt;

&lt;p&gt;In your &lt;code class=&quot;highlighter-rouge&quot;&gt;~/.ssh/config&lt;/code&gt; simply adding&lt;/p&gt;

&lt;figure class=&quot;highlight&quot;&gt;&lt;pre&gt;&lt;code class=&quot;language-bash&quot; data-lang=&quot;bash&quot;&gt;Host &lt;span class=&quot;k&quot;&gt;*&lt;/span&gt;
	SmartcardDevice /usr/local/Cellar/opensc/0.15.0/lib/pkcs11/opensc-pkcs11.so&lt;/code&gt;&lt;/pre&gt;&lt;/figure&gt;

&lt;p&gt;For Linux (ubuntu 16)&lt;/p&gt;

&lt;figure class=&quot;highlight&quot;&gt;&lt;pre&gt;&lt;code class=&quot;language-bash&quot; data-lang=&quot;bash&quot;&gt;&lt;span class=&quot;gp&quot;&gt;$ &lt;/span&gt;apt-get install opensc-pkcs11&lt;/code&gt;&lt;/pre&gt;&lt;/figure&gt;

&lt;p&gt;And my resulting &lt;code class=&quot;highlighter-rouge&quot;&gt;~/.ssh/config&lt;/code&gt;&lt;/p&gt;

&lt;figure class=&quot;highlight&quot;&gt;&lt;pre&gt;&lt;code class=&quot;language-bash&quot; data-lang=&quot;bash&quot;&gt;Host &lt;span class=&quot;k&quot;&gt;*&lt;/span&gt;
	SmartCardDevice /usr/lib/x86_64-linux-gnu/opensc-pkcs11.so&lt;/code&gt;&lt;/pre&gt;&lt;/figure&gt;

&lt;p&gt;Hope this helps you reach your state of SSH nirvana!&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Your paths will almost surely vary, ensure those are set for your particular computer :)&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;–breland&lt;/p&gt;
</description>
        <pubDate>Mon, 09 May 2016 03:03:18 +0000</pubDate>
        <link>https://bdawg.org/ssh/yubikey/2016/05/09/yubikey4-ssh.html</link>
        <guid isPermaLink="true">https://bdawg.org/ssh/yubikey/2016/05/09/yubikey4-ssh.html</guid>
        
        
        <category>ssh</category>
        
        <category>yubikey</category>
        
      </item>
    
  </channel>
</rss>
