<?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>Yubikey &#8211; privacyID3A</title>
	<atom:link href="https://www.privacyidea.org/tag/yubikey/feed/" rel="self" type="application/rss+xml" />
	<link>https://www.privacyidea.org</link>
	<description>flexible, Open Source Multi Factor Authentication (2FA)</description>
	<lastBuildDate>Mon, 28 Dec 2020 10:35:09 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.7.5</generator>

<image>
	<url>https://www.privacyidea.org/wp-content/uploads/2016/06/cropped-only-logo-white-background-32x32.png</url>
	<title>Yubikey &#8211; privacyID3A</title>
	<link>https://www.privacyidea.org</link>
	<width>32</width>
	<height>32</height>
</image> 
	<item>
		<title>Enroll a Yubikey as PIV smartcard</title>
		<link>https://www.privacyidea.org/enroll-a-yubikey-as-piv-smartcard/</link>
		
		<dc:creator><![CDATA[Cornelius Kölbel]]></dc:creator>
		<pubDate>Mon, 28 Dec 2020 10:35:08 +0000</pubDate>
				<category><![CDATA[Howto]]></category>
		<category><![CDATA[Tips and Tricks]]></category>
		<category><![CDATA[smartcards]]></category>
		<category><![CDATA[Yubikey]]></category>
		<guid isPermaLink="false">https://www.privacyidea.org/?p=2235</guid>

					<description><![CDATA[privacyIDEA supports enrollment of PIV smartcards. A from the scratch howto to enroll x509 certificates on Yubikeys.]]></description>
										<content:encoded><![CDATA[
<p>In this blog post we will show, how you can enroll a Yubikey as a PIV smartcard. privacyIDEA will issue the certificate request sent by the Yubikey but at the same time require an attestation certificate. This way privacyIDEA will assure, that the key pair indeed has been generated on the smartcard.</p>



<figure class="wp-block-image size-large"><img fetchpriority="high" decoding="async" width="1000" height="469" src="https://www.privacyidea.org/wp-content/uploads/2020/12/enroll-yubikey.jpg" alt="" class="wp-image-2238" srcset="https://www.privacyidea.org/wp-content/uploads/2020/12/enroll-yubikey.jpg 1000w, https://www.privacyidea.org/wp-content/uploads/2020/12/enroll-yubikey-300x141.jpg 300w, https://www.privacyidea.org/wp-content/uploads/2020/12/enroll-yubikey-768x360.jpg 768w" sizes="(max-width: 1000px) 100vw, 1000px" /></figure>



<p>You could then use the Yubikey with the x509 certificate to login to you desktop, sign or decrypt emails. These application examples are not topic of this blog post and might be covered in later posts.</p>



<p>You will need a Yubikey 5 and a <a href="https://www.privacyidea.org/multi-factor-authentication-privacyidea-3-5-released/" data-type="post" data-id="2223">privacyIDEA installation with version 3.5</a>. We also assume in this example, that you are running Linux on your desktop.</p>



<h2 class="wp-block-heading">Setup CA in privacyIDEA</h2>



<p>First we have to setup a certificate authority (CA), that will sign the certificate signing request (CSR) generated by the Yubikey. privacyIDEA currently only supports local openssl based CAs. This could however be a sub CA to your existing enterprise CA. In this example, we create a new root CA.</p>



<p><strong>Note: You need read access to pi.cfg and write access to /etc/privacyidea/ca</strong></p>



<pre class="wp-block-code"><code># pi-manage ca create -t local myLocalCA</code></pre>



<p>This pi-manage command will create the CA files and also the CA configuration within privacyIDEA. You are asked a couple of questions and answer them accordingly:</p>



<pre class="wp-block-code"><code># pi-manage  ca create -t local  myLocalCA

             _                    _______  _______
   ___  ____(_)  _____ _______ __/  _/ _ \/ __/ _ |
  / _ \/ __/ / |/ / _ `/ __/ // // // // / _// __ |
 / .__/_/ /_/|___/\_,_/\__/\_, /___/____/___/_/ |_|
/_/                       /___/

Creating CA connector of type local.
In which directory do you want to create the CA &#91;./ca]: /etc/privacyidea/ca
What should be the keysize of the CA (2048/4096/8192)&#91;4096]: 
How many days should the CA be valid &#91;1800]: 
What is the DN of the CA &#91;/CN=myLocalCA]: 
How many days should the CRL be valid &#91;30]: 
What should be the overlap period of the CRL in days &#91;5]: 
============================================================

        Directory  : /etc/privacyidea/ca
        CA DN      : /CN=myLocalCA
        CA Keysize : 4096
        CA Validity: 1800

        Validity of issued certificates: 365

        CRL validity: 30
        CRL overlap : 5

Is this configuration correct? &#91;y/n] y</code></pre>



<p>You also need to fix the access to the directory</p>



<pre class="wp-block-code"><code>chown privacyidea -R /etc/privacyidea/ca</code></pre>



<p>and create a file <code>/etc/privacyidea/ca/templates.yaml</code> with the contents:</p>



<pre class="wp-block-code"><code>user:
    extenstions: "user"
    days: 365</code></pre>



<p>which will ensure, that the certificate will created as a user certificate with a validity period of 365 days.</p>



<p>You need to do some minor fixtues:</p>



<pre class="wp-block-code"><code>cd /etc/privacyidea/ca
openssl rand -writerand .rnd 
touch index.txt.attr 
chown privacyidea .rnd index.txt.attr</code></pre>



<p>For simplicity comment out two lines (crlDistributionPoints and authorityInformationAccess) in the section &#8220;user&#8221; in the file /etc/privacyidea/ca/openssl.cnf</p>



<pre class="wp-block-code"><code>&#91; user ]
keyUsage = nonRepudiation, digitalSignature, keyEncipherment
basicConstraints = CA:FALSE
subjectKeyIdentifier=hash
authorityKeyIdentifier=keyid,issuer:always
#crlDistributionPoints = @crl_dp_policy
#authorityInfoAccess = caIssuers;URI:http://www.example.com/yourCA.crt</code></pre>



<p>As a last step, go to the Web UI in Config->CA and add the &#8220;Certificate template file&#8221; <code>/etc/privacyidea/ca/templates.yaml</code>.</p>



<figure class="wp-block-image size-large"><img decoding="async" width="673" height="692" src="https://www.privacyidea.org/wp-content/uploads/2020/12/ca-templates.png" alt="" class="wp-image-2240" srcset="https://www.privacyidea.org/wp-content/uploads/2020/12/ca-templates.png 673w, https://www.privacyidea.org/wp-content/uploads/2020/12/ca-templates-292x300.png 292w" sizes="(max-width: 673px) 100vw, 673px" /></figure>



<p>Now your CA is ready to go.</p>



<h2 class="wp-block-heading">Setup PIV trusted certificates</h2>



<p>The attestation certificate verifies that the private key was generated on the Yubikey. You can tell privacyIDEA, which attestation certificates should be trusted. Here we will use the Yubikey, so we need to fetch the <a href="https://developers.yubico.com/yubico-piv-tool/Attestation.html" target="_blank" rel="noreferrer noopener">Yubico PIV CA from their web site</a>.</p>



<pre class="wp-block-code"><code>mkdir /etc/privacyidea/attestation    
wget https://developers.yubico.com/PIV/Introduction/piv-attestation-ca.pem \
     -O /etc/privacyidea/attestation/yubico.pem</code></pre>



<p>The PIV Root CA has signed the attestation CA, that is contained on each Yubikey. We need to retrieve this from the Yubikey. Do do so insert a Yubikey and run the following command:</p>



<pre class="wp-block-code"><code>yubico-piv-tool --action=read-certificate \ 
      --slot=f9 >> /etc/privacyidea/attestation/yubico.pem</code></pre>



<p>The certificate we read from the Yubikey from slot f9 is the attestation CA, that was signed by the Yubico CA. The attestation CA will sign the attestation certificate, that testifies, that the CSR was created on the yubikey. The file yubico.pem now contains the certificate chain of the PIV Root CA and the Attestation CA.</p>



<p><strong>Note: With new production charges Yubico might put a new attestation CA on the yubikeys. So if you buy 100 yubikeys, they will most probably have the same attestation CA, but if you buy another 100 yubikeys several month later, they might have another attestation CA, so you need to repeat this step and put the new certificate chain in a second file.</strong></p>



<h2 class="wp-block-heading">Configure privacyIDEA policies</h2>



<p>privacyIDEA can already enroll x509 certificates. But to ensure, that it will only enroll certificates from CSRs, that are created on the Yubikey, we need to define a new policy, which is available starting with privacyIDEA 3.5.</p>



<p>We create a policy to require an attestation certificate</p>



<pre class="wp-block-code"><code>scope: enrollment
action: certificate_require_attestation=require_and_verify</code></pre>



<p>In this example we will have the administrator enroll yubikeys, so we set an admin policy, that specifies, where the trusted CA chains can be found:</p>



<pre class="wp-block-code"><code>scope: admin
action: certificate_trusted_Attestation_CA_path=/etc/privacyidea/attestation/</code></pre>



<h2 class="wp-block-heading">Enroll certificate</h2>



<p>Now the admin needs to pass the CSR and in addition an attestation certificate, if he wants to have the CSR signed and receive a certificate. The admin could do this manually with the yubico own tools and using the privacyIDEA REST API. </p>



<p>However, in this example we use the <em>privacyidea admin client</em>, which can be <a href="https://github.com/privacyidea/privacyideaadm" target="_blank" rel="noreferrer noopener">found at github</a>.</p>



<p><strong>Note: You can run the command line client on any other computer, it does not need to be your privacyIDEA server.</strong></p>



<p>In this case we are running it on an Ubuntu Linux desktop.</p>



<p>Prepare dependencies:</p>



<pre class="wp-block-code"><code>sudo apt-add-repository ppa:yubico/stable
sudo apt update
sudo apt install yubikey-manager
sudo apt install ykcs11</code></pre>



<p>Create a virtualenv:</p>



<pre class="wp-block-code"><code>virtualenv -p /usr/bin/python3 piv-test</code></pre>



<p>Enter the environment:</p>



<pre class="wp-block-code"><code>source piv-test/bin/activate</code></pre>



<p>Install the privacyidea admin client:</p>



<pre class="wp-block-code"><code>git clone https://github.com/privacyidea/privacyideaadm
cd privacyideaadm
pip install .</code></pre>



<p>Now you can use the current development branch of the admin client in your virtualenv.</p>



<p><strong>Note: You need to have enough hardware access rights, otherwise you might get errors like &#8221; Failed to transmit with protocol T1. Reader is unavailable&#8221;</strong></p>



<p>If necessary, you can reset the PIV data on your yubikey:</p>



<pre class="wp-block-code"><code>ykman piv reset</code></pre>



<p>Now you can enroll the yubikey certificate:</p>



<pre class="wp-block-code"><code>privacyidea-enroll-yubikey-piv init-cert -s cornelius -u cornelius \
     -U https://localhost -a super -p test -c myLocalCA -n -P 123456</code></pre>



<p>This will create a CSR on the Yubikey, with the subject &#8220;CN=cornelius&#8221; and access the Yubikey with the PIN &#8220;123456&#8221;. The CSR and the attestation certificate will be sent to privacyIDEA at &#8220;https://localhost&#8221;, the admin will authenticate as user &#8220;super&#8221; with the password &#8220;test&#8221; and enroll the certificate to the user &#8220;cornelius&#8221;. privacyIDEA will verify the attestation certificate, sign the CSR and the certificate will be imported to the Yubikey.</p>



<p><strong>Note: If you have problems enrolling and try to reenroll, you might need to delete temporary files _*.</strong></p>



<p>You can now use the Yubikey with the certificate on it to sign emails or login to your Desktop. As mentioned, this can be a topic for future blog posts.</p>



<h2 class="wp-block-heading">Conclusion</h2>



<p>We showed here how an administrator can enroll a Yubikey with an x509 certificate to a user. At the same time privacyIDEA ensures, that the private key is really generated on the Yubikey. This is an important aspect, when using smartcards for authentication. This ensures, that the private key is unique and can not be copied, neither during the enrollment process nor lateron, making the smartcard a unique authentication factor.</p>



<p>The same way, a user could issue a CSR that was generated on a smartcard to privacyIDEA, making the enrollment process more robust.</p>



<p>This is an important fist step for privacyIDEA to deal with smartcards. We will continue working on  smartcard functionalities, smoothening the workflow and enhancing policies.</p>



<p>In an enterprise environment managing x509 certificates and smartcards on a central location is crucial. The Yubikey could contain several certificates. It can contain Webauthn profiles or HOTP slots. If a Yubikey is lost, the service desk should be able to revoke the one hardware key and the central management should know, which certificates and which HOTP slots are affected. With privacyIDEA we are working on this, to ease the life of administrators and service desk users.</p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Choose required Security Level with privacyIDEA</title>
		<link>https://www.privacyidea.org/choose-required-security-level-with-privacyidea/</link>
					<comments>https://www.privacyidea.org/choose-required-security-level-with-privacyidea/#respond</comments>
		
		<dc:creator><![CDATA[Cornelius Kölbel]]></dc:creator>
		<pubDate>Wed, 20 Jan 2016 11:22:09 +0000</pubDate>
				<category><![CDATA[opinions]]></category>
		<category><![CDATA[Security]]></category>
		<category><![CDATA[Tips and Tricks]]></category>
		<category><![CDATA[Authentication]]></category>
		<category><![CDATA[Google Authenticator]]></category>
		<category><![CDATA[security level]]></category>
		<category><![CDATA[SMS OTP]]></category>
		<category><![CDATA[Token Types]]></category>
		<category><![CDATA[Yubikey]]></category>
		<guid isPermaLink="false">https://www.privacyidea.org/?p=852</guid>

					<description><![CDATA[With SMS OTP a one time password is sent to a mobile phone. The user is supposed to enter this one time password in addition to his static password. This way, the authenticating party thinks to verify, that the user is in the possession of the mobile phone. This is a cheap way to establish [&#8230;]]]></description>
										<content:encoded><![CDATA[<p>With SMS OTP a one time password is sent to a mobile phone. The user is supposed to enter this one time password in addition to his static password. This way, the authenticating party thinks to verify, that the user is in the possession of the mobile phone.</p>
<p>This is a cheap way to establish two-factor authentication with something you know and something you have.</p>
<h2>Several attack vectors for Two-Factor Authentication with SMS OTP</h2>
<p><figure id="attachment_856" aria-describedby="caption-attachment-856" style="width: 300px" class="wp-caption alignright"><a href="https://www.privacyidea.org/wp-content/uploads/2016/01/mobile-phone-991494_640.jpg" rel="attachment wp-att-856"><img decoding="async" class="size-medium wp-image-856" src="https://www.privacyidea.org/wp-content/uploads/2016/01/mobile-phone-991494_640-300x167.jpg" alt="Your OTP on the mobile is vulnarable." width="300" height="167" srcset="https://www.privacyidea.org/wp-content/uploads/2016/01/mobile-phone-991494_640-300x167.jpg 300w, https://www.privacyidea.org/wp-content/uploads/2016/01/mobile-phone-991494_640.jpg 640w" sizes="(max-width: 300px) 100vw, 300px" /></a><figcaption id="caption-attachment-856" class="wp-caption-text">Your OTP on the mobile is vulnarable.</figcaption></figure></p>
<p>But lateley there are again some news about the vularability of OTP values sent via SMS. There are different attack vectors. In one scenario <a href="http://mobilemarketingmagazine.com/97087-2/" target="_blank">the attacker can reroute or &#8220;steal&#8221; the SIM card by doing social engineering at the telephone provider</a>. In another scenario <a href="http://www.businessinsider.de/malware-discovered-that-defeats-two-factor-authentication-symantec-2016-1" target="_blank">a malicious software is installed on the smartphone, that can sniff the OTP value</a>.</p>
<p>Yes, privacyIDEA also supports sending OTP values via SMS and privacyIDEA is also vulnarable to these attacks &#8211; since it is the basic concept that lacks the necessary security.</p>
<h2>Security is shades of grey &#8212; or white</h2>
<p><figure id="attachment_855" aria-describedby="caption-attachment-855" style="width: 300px" class="wp-caption alignleft"><a href="https://www.privacyidea.org/wp-content/uploads/2016/01/mixing-desk-351478_640.jpg" rel="attachment wp-att-855"><img loading="lazy" decoding="async" class="size-medium wp-image-855" src="https://www.privacyidea.org/wp-content/uploads/2016/01/mixing-desk-351478_640-300x199.jpg" alt="Security is shades of grey. Some volume between 0 and 99%." width="300" height="199" srcset="https://www.privacyidea.org/wp-content/uploads/2016/01/mixing-desk-351478_640-300x199.jpg 300w, https://www.privacyidea.org/wp-content/uploads/2016/01/mixing-desk-351478_640.jpg 640w" sizes="auto, (max-width: 300px) 100vw, 300px" /></a><figcaption id="caption-attachment-855" class="wp-caption-text">Security is shades of grey. Some volume between 0 and 99%.</figcaption></figure></p>
<p>But you might have heard that &#8220;there is no 100% security&#8221;. And that &#8220;security is a process&#8221;. And now I add to these idioms &#8220;Security is Shades of Grey&#8221;.</p>
<p>You gain security by using a password on your account to lock the desktop. But are you secure? You gain further security by adding a second factor during authentication. But is your data secure, now? You gain further security by encrypting the harddisk (a.k.a. your data) of your desktop. But is it secure?</p>
<p>Yes, it is good to use a password. You should not use none.</p>
<p>And yes, it is goot to use SMS OTP. It is better than to not use it. In certain cases it might be OK to use SMS OTP being aware of the possible risks.</p>
<p>But there are further steps or other possiblities to increase security.</p>
<h2>Choice of Security Level</h2>
<p>With privacyIDEA you have the choice, which security level you are going to use. And this may even depend on the application and the client.</p>
<p>You may use <a href="https://www.privacyidea.org/about/features/">SMS OTP, Email OTP, Smartphone Apps like the Google Authenticator, hardware key fobs and seedable tokens</a> like the <a href="https://www.privacyidea.org/privacyidea-admin-client-for-yubikey-mass-enrollment/">Yubikey</a>. Using privacyIDEA&#8217;s policy definitions, <a href="https://www.privacyidea.org/enforcing-security-policies-security-levels-with-different-otp-token-types/">you can define which token type is allowed to be used for authentication at which application</a>. This way you can accept the risk of using e.g. SMS OTP for low security applications and hardware devices like the yubikey for applications requiring higher confidentiality.</p>
<p>See the <a href="http://privacyidea.readthedocs.org/en/latest/policies/index.html" target="_blank">online documentation on policies</a> for more information or come to the <a href="https://groups.google.com/forum/#!forum/privacyidea" target="_blank">Google Group mailing list</a>.</p>
<p>If you require any <a href="https://netknights.it/en" target="_blank">professional assistance you may contact the maintainer of privacyIDEA</a>.</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.privacyidea.org/choose-required-security-level-with-privacyidea/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>privacyIDEA 2.9 with Yubico Protocol and new Token Types</title>
		<link>https://www.privacyidea.org/privacyidea-2-9-with-yubico-protocol-and-new-token-types/</link>
					<comments>https://www.privacyidea.org/privacyidea-2-9-with-yubico-protocol-and-new-token-types/#respond</comments>
		
		<dc:creator><![CDATA[Cornelius Kölbel]]></dc:creator>
		<pubDate>Mon, 21 Dec 2015 16:50:38 +0000</pubDate>
				<category><![CDATA[release]]></category>
		<category><![CDATA[Whatsup]]></category>
		<category><![CDATA[Paper]]></category>
		<category><![CDATA[Questionnaire]]></category>
		<category><![CDATA[Token Types]]></category>
		<category><![CDATA[Yubikey]]></category>
		<guid isPermaLink="false">https://www.privacyidea.org/?p=820</guid>

					<description><![CDATA[We are proud to announce the availability of privacyIDEA 2.9. Features Yubico Validation Protocol Version 2.9 comes with support for the Yubico Validation Protocol. This way you can use common Yubico client like the PAM module for Mac OS. privacyIDEA&#8217;s yubico validation protocol can be reached via /ttype/yubikey. For more detailed developer information you may [&#8230;]]]></description>
										<content:encoded><![CDATA[<p>We are proud to announce the availability of privacyIDEA 2.9.</p>
<h2>Features</h2>
<h3>Yubico Validation Protocol</h3>
<p>Version 2.9 comes with support for the <a href="https://developers.yubico.com/yubikey-val/Validation_Protocol_V2.0.html" target="_blank">Yubico Validation Protocol</a>. This way you can use common Yubico client like the PAM module for Mac OS. privacyIDEA&#8217;s yubico validation protocol can be reached via <em>/ttype/yubikey</em>. For more <a href="http://privacyidea.readthedocs.org/en/latest/modules/lib/tokentypes/yubikey.html" target="_blank">detailed developer information you may read the module specification</a>.</p>
<h3>Questionnaire Token</h3>
<p><figure id="attachment_822" aria-describedby="caption-attachment-822" style="width: 300px" class="wp-caption alignright"><a href="https://www.privacyidea.org/wp-content/uploads/2015/12/questionnaire-token.png"><img loading="lazy" decoding="async" class="wp-image-822 size-medium" src="https://www.privacyidea.org/wp-content/uploads/2015/12/questionnaire-token-300x214.png" alt="questionnaire-token" width="300" height="214" srcset="https://www.privacyidea.org/wp-content/uploads/2015/12/questionnaire-token-300x214.png 300w, https://www.privacyidea.org/wp-content/uploads/2015/12/questionnaire-token.png 680w" sizes="auto, (max-width: 300px) 100vw, 300px" /></a><figcaption id="caption-attachment-822" class="wp-caption-text">Questionnaire Token: Lets you define and answer a list of questions. During authentication a challenge response is performed.</figcaption></figure></p>
<p>The <a href="http://privacyidea.readthedocs.org/en/latest/configuration/tokens/questionnaire.html?highlight=questionnaire" target="_blank">questionnaire token lets a user answer a list of questions</a>. The questionnaire token then acts as a challenge response token. After entering the password or OTP PIN, the user is asked an random question, which he needs to answer accordingly.</p>
<h3>Paper Token</h3>
<p><figure id="attachment_823" aria-describedby="caption-attachment-823" style="width: 300px" class="wp-caption alignleft"><a href="https://www.privacyidea.org/wp-content/uploads/2015/12/paper-token.png"><img loading="lazy" decoding="async" class="wp-image-823 size-medium" src="https://www.privacyidea.org/wp-content/uploads/2015/12/paper-token-300x188.png" alt="paper-token" width="300" height="188" srcset="https://www.privacyidea.org/wp-content/uploads/2015/12/paper-token-300x188.png 300w, https://www.privacyidea.org/wp-content/uploads/2015/12/paper-token.png 738w" sizes="auto, (max-width: 300px) 100vw, 300px" /></a><figcaption id="caption-attachment-823" class="wp-caption-text">Paper Token: Lets you print a list of OTP values &#8211; some kind of TAN list.</figcaption></figure></p>
<p>The <a href="http://privacyidea.readthedocs.org/en/latest/configuration/tokens/paper.html?highlight=paper" target="_blank">paper token lets a user print a list of OTP values</a>, which he can use to authenticate. Internally the paper token is an HOTP token. The printed sheet of paper can be cut and folded and carried in the users wallet.</p>
<h2>Enhancements</h2>
<p>Besides these new features privacyIDEA 2.9 comes with a list of further enhancements:</p>
<ul>
<li>Add Web UI view to display the active challenges.</li>
<li>The issuer for the Google Authenticator app can be configured.</li>
<li>The LDAP machine resolver uses an LDAP server pool.</li>
<li>The LDAP user resolver returns a list of mobile numbers.</li>
</ul>
<h2>Fixes</h2>
<p>The following issues have been fixed in privacyIDEA 2.9:</p>
<ul>
<li>The test email for the email token now has a sent date.</li>
<li>Fix problem when using encrypted encryption key.</li>
<li>Fix upper case problem when logging in to web UI with REMOTE_USER.</li>
<li>Fix allow set an empty PIN in the web UI.</li>
<li>Fix import of token file in Web UI.</li>
</ul>
<h2>Download, Install, Upgrade</h2>
<p>You can <a href="https://www.privacyidea.org/downloads/">download privacyIDEA from the usual locations</a>. Upgrade is fairly easy, since there are no changes to the database schema from 2.8 -&gt; 2.9.</p>
<p>Please read the<a href="http://privacyidea.readthedocs.org/en/latest/installation/index.html" target="_blank"> installation documentation for further information</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.privacyidea.org/privacyidea-2-9-with-yubico-protocol-and-new-token-types/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>TSA tries to get grasp on second factor &#8211; taking simple measures</title>
		<link>https://www.privacyidea.org/tsa-tries-to-get-grasp-on-second-factor-taking-simple-measures/</link>
					<comments>https://www.privacyidea.org/tsa-tries-to-get-grasp-on-second-factor-taking-simple-measures/#respond</comments>
		
		<dc:creator><![CDATA[Cornelius Kölbel]]></dc:creator>
		<pubDate>Sat, 31 Oct 2015 08:20:51 +0000</pubDate>
				<category><![CDATA[opinions]]></category>
		<category><![CDATA[Tips and Tricks]]></category>
		<category><![CDATA[TISA]]></category>
		<category><![CDATA[Yubikey]]></category>
		<guid isPermaLink="false">https://www.privacyidea.org/?p=778</guid>

					<description><![CDATA[Two factor authentication or multi factor authentication is ment to raise the bar for attackers. They ought to sniff, brute-force or social-engineer your password and in addition steal or &#8220;borrow&#8221; your hardware token for a &#8220;test&#8221;. Still, I wish to think that the Yubikey &#8211; being the product of originally a sole Swedish company &#8211; has no back doors. So [&#8230;]]]></description>
										<content:encoded><![CDATA[<p><figure id="attachment_779" aria-describedby="caption-attachment-779" style="width: 300px" class="wp-caption alignleft"><a href="https://www.privacyidea.org/wp-content/uploads/2015/10/Bildschirmfoto-vom-2015-10-31-085326.png"><img loading="lazy" decoding="async" class="wp-image-779 size-medium" src="https://www.privacyidea.org/wp-content/uploads/2015/10/Bildschirmfoto-vom-2015-10-31-085326-300x117.png" alt="Tweet by flexlibris" width="300" height="117" srcset="https://www.privacyidea.org/wp-content/uploads/2015/10/Bildschirmfoto-vom-2015-10-31-085326-300x117.png 300w, https://www.privacyidea.org/wp-content/uploads/2015/10/Bildschirmfoto-vom-2015-10-31-085326.png 551w" sizes="auto, (max-width: 300px) 100vw, 300px" /></a><figcaption id="caption-attachment-779" class="wp-caption-text">live experience with TISA on twitter by @flexlibris</figcaption></figure></p>
<p>Two factor authentication or multi factor authentication is ment to raise the bar for attackers. They ought to sniff, brute-force or social-engineer your password and in addition steal or &#8220;borrow&#8221; your hardware token for a &#8220;test&#8221;.</p>
<p>Still, I wish to think that the Yubikey &#8211; being the product of originally a sole Swedish company &#8211; has no back doors. So as long as the TISA does not know of side channel attacks or you used a static password with the Yubikey, you might be fine as long as you get the same Yubikey back &#8211; undestroyed.</p>
<p>Nevertheless there are additional measures you can take to improve your security with privacyIDEA.</p>
<p><strong>Disclaimer</strong>: This will only help, if you are using your hardware token to authenticate to remote systems. If you use your hardware token to unlock let&#8217;s say encrypted harddisk of your notebook, you are carrying, this will not help.</p>
<h2>Set up privacyIDEA</h2>
<p>When you manage your hardware token for remote access with privacyIDEA and you are crossing borders or you are in situations where you</p>
<ol>
<li>think your hardware token could be stolen or otherwise compromised and</li>
<li>you do not need the token explicitly (since you are on the plane without internet access)</li>
</ol>
<p>you might want to call your trusted privacyIDEA administrator (some call it help desk) and have your hardware token locked.</p>
<p>This way the hardware token can not be used to access restricted resources. If TISA is still insisting to get your Yubikey, you can say:</p>
<blockquote><p>&#8220;If you take it, you can keep it&#8221;</p></blockquote>
<p>(No of course you can take it back, but you may see it as compromised and you might need to reenroll it.)</p>
<p>If TISA takes the Yubikey there is not use for them, since the token is locked.</p>
<p><figure id="attachment_782" aria-describedby="caption-attachment-782" style="width: 300px" class="wp-caption aligncenter"><a href="https://www.privacyidea.org/wp-content/uploads/2015/10/Bildschirmfoto-vom-2015-10-31-091415.png"><img loading="lazy" decoding="async" class="wp-image-782 size-medium" src="https://www.privacyidea.org/wp-content/uploads/2015/10/Bildschirmfoto-vom-2015-10-31-091415-300x119.png" alt="Token detail view of a disabled token" width="300" height="119" srcset="https://www.privacyidea.org/wp-content/uploads/2015/10/Bildschirmfoto-vom-2015-10-31-091415-300x119.png 300w, https://www.privacyidea.org/wp-content/uploads/2015/10/Bildschirmfoto-vom-2015-10-31-091415-1024x406.png 1024w, https://www.privacyidea.org/wp-content/uploads/2015/10/Bildschirmfoto-vom-2015-10-31-091415.png 1212w" sizes="auto, (max-width: 300px) 100vw, 300px" /></a><figcaption id="caption-attachment-782" class="wp-caption-text">The token is disabled and can not be used for authentication.</figcaption></figure></p>
<p>If TISA did not get your Yubikey and you crossed the border, customs or control successfully, you may call your trusted privacyIDEA admin again to reactivate the hardware token.</p>
<h2>Conclusion</h2>
<p>This might sound a bit complicated but also to simple. But special events like travelling to certain rogue regimes may require special measures.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.privacyidea.org/tsa-tries-to-get-grasp-on-second-factor-taking-simple-measures/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>SSH Keys and OTP: Really strong two factor authentication</title>
		<link>https://www.privacyidea.org/ssh-keys-and-otp-really-strong-two-factor-authentication/</link>
					<comments>https://www.privacyidea.org/ssh-keys-and-otp-really-strong-two-factor-authentication/#comments</comments>
		
		<dc:creator><![CDATA[Cornelius Kölbel]]></dc:creator>
		<pubDate>Thu, 29 Oct 2015 11:00:29 +0000</pubDate>
				<category><![CDATA[documentation]]></category>
		<category><![CDATA[Howto]]></category>
		<category><![CDATA[Ubuntu]]></category>
		<category><![CDATA[Authentication]]></category>
		<category><![CDATA[Installation]]></category>
		<category><![CDATA[login]]></category>
		<category><![CDATA[ssh]]></category>
		<category><![CDATA[Yubikey]]></category>
		<guid isPermaLink="false">https://www.privacyidea.org/?p=771</guid>

					<description><![CDATA[This blog will show how you can use privacyIDEA to secure your SSH login. In this case users need to provide an SSH Key and in addition an OTP token and an optional password. Thus you have the following authentication factors: SSH Key (soft possession factor &#8211; copyable!) optional passphrase on the SSH Key, which is [&#8230;]]]></description>
										<content:encoded><![CDATA[<p>This blog will show how you can use privacyIDEA to secure your SSH login. In this case users need to provide an SSH Key and in addition an OTP token and an optional password.</p>
<p>Thus you have the following authentication factors:</p>
<ol>
<li>SSH Key (soft <strong>possession</strong> factor &#8211; copyable!)</li>
<li>optional passphrase on the SSH Key, which is not controlled by the server! (<strong>knowledge</strong>)</li>
<li>OTP token <a href="http://privacyidea.readthedocs.org/en/latest/configuration/token_config.html#supported-tokentypes" target="_blank">supported by privacyIDEA</a> like Google Authenticator or preferable a Yubikey (hard <strong>possession</strong> factor &#8211; not copyable)</li>
<li>an optional OTP PIN controlled by privacyIDEA (<strong>knowledge</strong>)</li>
</ol>
<h2>Connect SSH to privacyIDEA</h2>
<p>Connecting SSH to privacyIDEA is described in this <a href="https://www.youtube.com/watch?v=tNoHzrajtcg&amp;t=1m52s" target="_blank">video</a>. It uses the privacyIDEA PAM Module in the <a href="http://privacyidea.readthedocs.org/en/latest/application_plugins/index.html#pluggable-authentication-module">online documentation</a>.</p>
<p>In the SSH configuration you need to set</p>
<pre>UsePAM yes</pre>
<p>This way SSH will authenticate the user against the PAM stack using <em>/etc/pam.d/sshd</em>.</p>
<p>This howto will assume you are using a Ubuntu system. Other systems like CentOS use slightly different PAM configuration, but the idea is the same.</p>
<h3>Install privacyIDEA PAM</h3>
<p>To use PAM with privacyIDEA you need the privacyIDEA <a href="https://github.com/privacyidea/pam_python">PAM authentication module</a>. On a Ubuntu 14.04 you can install it like</p>
<pre>add-apt-repository ppa:privacyidea/privacyidea
apt-get update
apt-get install privacyidea-pam</pre>
<p>In other cases you can get it from github with the above mentioned link.</p>
<h3>Configure SSH PAM</h3>
<p>Now lets take a look at the PAM config for SSH. The file <em>/etc/pam.d/sshd</em> contains a line</p>
<pre>@include common-auth</pre>
<p>Change this line to</p>
<pre>@include common-auth-pi</pre>
<p>By creating such a new file it is easier for us to add two factors to every PAM enabled service.</p>
<p>Copy the file <em>/etc/pam.d/common-auth</em> to <em>/etc/pam.d/common-auth-pi</em>. The file<em> /etc/pam.d/common-auth-pi</em> will look like this:</p>
<pre>auth     [success=1 default=ignore] pam_python.so /lib/security/privacyidea_pam.py url=https://yourserver \ 
                                                  nosslverify debug
auth    requisite   pam_deny.so
auth    required    pam_permit.so
auth    optional    pam_cap.so</pre>
<p>In the file <em>common-auth-pi</em> we replace <em>pam_unix.so</em> with <em>privacyidea_pam</em>. You need to specify the URL of your privacyIDEA server. If everything is working out fine, you can remove the <em>debug</em> parameter. If you have a trusted certificate you can remove <em>nosslverify</em>.</p>
<blockquote><p>Please assure, that you are logged in to your system or that you have other mean to login like ssh keys. Modifying the PAM stack for SSH can result in not being able to login with a password via SSH anymore.</p></blockquote>
<p>Now that you have configured</p>
<ul>
<li>/etc/ssh/sshd_config</li>
<li>/etc/pam.d/common-auth-pi</li>
<li>/etc/pam.d/sshd</li>
</ul>
<p>you can restart the SSH server for the changes to take effect.</p>
<p>When you now try to login via SSH, the username and password will be sent to privacyIDEA for verification. You can not use you OTP PIN and Yubikey to login.</p>
<blockquote><p>If you experience any problems, take a look at <em>/var/log/auth.log</em>.</p></blockquote>
<p>If everything is working fine, you are now authenticating with:</p>
<ol>
<li>OTP token <a href="http://privacyidea.readthedocs.org/en/latest/configuration/token_config.html#supported-tokentypes" target="_blank">supported by privacyIDEA</a> like Google Authenticator or preferable a Yubikey (hard <strong>possession</strong> factor &#8211; not copyable)</li>
<li>an optional OTP PIN controlled by privacyIDEA (<strong>knowledge</strong>)</li>
</ol>
<h2>Add SSH Keys</h2>
<p>You may realize, that if you have an SSH key in the authorized_keys you will not be asked for the OTP. At the moment you either login with SSH key or with OTP. Let&#8217;s change this now, that you can use SSH key <strong>and</strong> OTP.</p>
<p>The current OpenSSH comes with the options <strong>AuthenticationMethods</strong>. This is used to concatenate required authentication methods. See the man page of sshd_config for more details.</p>
<p>In the file<em> /etc/ssh/sshd_config</em> we add this line:</p>
<pre>AuthenticationMethods publickey,password</pre>
<p>This means that SSH will require that you pass a trusted SSH key and after this ask you for a password (PIN+OTP), which will be verified by privacyIDEA.</p>
<p>The login will look like this:</p>
<pre>root@gawain ~ # ssh root@privacyidea
Authenticated with partial success.
root@privacyidea's password: 
Welcome to Ubuntu 14.04.3 LTS (GNU/Linux 3.13.0-66-generic x86_64)</pre>
<p>The &#8220;Authenticated with partial success&#8221; means, that the authentication with the SSH key succeeded. Now you need to specify the One Time Password to be sent to privacyIDEA.</p>
<blockquote><p>Note: If you want to login as user &#8220;root&#8221;, be sure to add &#8220;PermitRootLogin yes&#8221; to your<em> sshd_config</em>.</p></blockquote>
<p>Finally we managed to authenticate the users with:</p>
<ol>
<li>SSH Key (soft <strong>possession</strong> factor &#8211; copyable!)</li>
<li>optional passphrase on the SSH Key, which is not controlled by the server! (<strong>knowledge</strong>)</li>
<li>OTP token <a href="http://privacyidea.readthedocs.org/en/latest/configuration/token_config.html#supported-tokentypes" target="_blank">supported by privacyIDEA</a> like Google Authenticator or preferable a Yubikey (hard <strong>possession</strong> factor &#8211; not copyable)</li>
<li>an optional OTP PIN controlled by privacyIDEA (<strong>knowledge</strong>)</li>
</ol>
<h2>Manage SSH Keys with privacyIDEA</h2>
<p>Wait! Are you still there? One thing might still strike you:</p>
<p>While all OTP tokens are centrally managed by privacyIDEA, users still put their public SSH keys on all the machines and you are wondering where the SSH keys of all the users are floating around.</p>
<p>There is no easy way for you to revoke a compromized SSH key.</p>
<p>But you can also solve this with privacyIDEA. Users can upload their public SSH keys to privacyIDEA with the tokentype <a href="http://privacyidea.readthedocs.org/en/latest/configuration/tokens/sshkey.html" target="_blank">SSH Key</a>.</p>
<p>This way you can also manage all SSH keys in privacyIDEA. In sshd_config you need to use the AuthorizedKeysCommand to retrieve the SSH keys from privayyIDEA just in time. Deleting an SSH key in privacyIDEA will deny access for this user immediatly.</p>
<p>You can read <a href="https://www.howtoforge.com/tutorial/ssh-key-management-with-privacyidea/" target="_blank">SSH Key Management with privacyIDEA</a> to set this up.</p>
<p>This way you have three strong factors to secure the access to SSH.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.privacyidea.org/ssh-keys-and-otp-really-strong-two-factor-authentication/feed/</wfw:commentRss>
			<slash:comments>1</slash:comments>
		
		
			</item>
		<item>
		<title>privacyIDEA admin client for Yubikey mass enrollment</title>
		<link>https://www.privacyidea.org/privacyidea-admin-client-for-yubikey-mass-enrollment/</link>
					<comments>https://www.privacyidea.org/privacyidea-admin-client-for-yubikey-mass-enrollment/#comments</comments>
		
		<dc:creator><![CDATA[Cornelius Kölbel]]></dc:creator>
		<pubDate>Wed, 19 Aug 2015 08:44:19 +0000</pubDate>
				<category><![CDATA[Howto]]></category>
		<category><![CDATA[release]]></category>
		<category><![CDATA[mass enrollment]]></category>
		<category><![CDATA[Yubikey]]></category>
		<guid isPermaLink="false">https://www.privacyidea.org/?p=711</guid>

					<description><![CDATA[We just released privacyIDEA admin client 2.5. The admin client already provided an easy way to enroll a bunch of yubikeys by initializing them one after another. Running privacyidea -U https://your.PI.server -a admin token yubikey_mass_enroll you are able to plugin a yubikey, wait for the admin client to initilize it within a second pull it and [&#8230;]]]></description>
										<content:encoded><![CDATA[<p>We just released privacyIDEA admin client 2.5.</p>
<p>The admin client already provided an easy way to enroll a bunch of yubikeys by initializing them one after another. Running</p>
<pre>privacyidea -U https://your.PI.server -a admin token yubikey_mass_enroll</pre>
<p>you are able to plugin a yubikey, wait for the admin client to initilize it within a second pull it and plug in the next. Without even pressing a key. (Hit Ctrl-C when you are done). This would write all the otpkey material directly to the specified privacyIDEA system. This was the status quo. This way you are able to initialize hundrets of yubikeys just by plugging in and pulling out.</p>
<p>Anyway. In certain cases this would not work, since you might have no USB access on the machine, from which you are accessing the privacyIDEA server.</p>
<p>With privacyIDEA admin client 2.5 it is now possible to initilize a bunch of yubikeys without the privacyIDEA server available. The otpkeys will be written to a file which you can import to privacyIDEA later. Run</p>
<pre>privacyidea token yubikey_mass_enroll --filename secrets.csv</pre>
<p>and all the secret otp keys will be written to secrets.csv. (Please note, that this file is not encrypted and contains the new secret keys of the initilized yubikeys)</p>
<p>Now you can import the file to any privacyIDEA system.</p>
<p><a href="https://www.privacyidea.org/wp-content/uploads/2015/08/import.png"><img loading="lazy" decoding="async" class="alignnone size-medium wp-image-713" src="https://www.privacyidea.org/wp-content/uploads/2015/08/import-300x142.png" alt="import" width="300" height="142" srcset="https://www.privacyidea.org/wp-content/uploads/2015/08/import-300x142.png 300w, https://www.privacyidea.org/wp-content/uploads/2015/08/import.png 1005w" sizes="auto, (max-width: 300px) 100vw, 300px" /></a></p>
<p>&nbsp;</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.privacyidea.org/privacyidea-admin-client-for-yubikey-mass-enrollment/feed/</wfw:commentRss>
			<slash:comments>2</slash:comments>
		
		
			</item>
		<item>
		<title>OTP Workshop at TÜBIX</title>
		<link>https://www.privacyidea.org/otp-workshop-at-tubix/</link>
					<comments>https://www.privacyidea.org/otp-workshop-at-tubix/#respond</comments>
		
		<dc:creator><![CDATA[Cornelius Kölbel]]></dc:creator>
		<pubDate>Sat, 23 May 2015 06:47:54 +0000</pubDate>
				<category><![CDATA[events]]></category>
		<category><![CDATA[Ubuntu]]></category>
		<category><![CDATA[Installation]]></category>
		<category><![CDATA[Yubikey]]></category>
		<guid isPermaLink="false">https://www.privacyidea.org/?p=603</guid>

					<description><![CDATA[In Tübingen, Germany will be a new Linuxtag &#8211; called Tübix. It is the first time that this event is conducted. The location and the program seems to be very interesting. Cornelius will do a workshop there about installing privacyIDEA, enrolling tokens and authenticating at SSH. You should get an IDEA how easy it is [&#8230;]]]></description>
										<content:encoded><![CDATA[<p>In Tübingen, Germany will be a new Linuxtag &#8211; called <a href="http://tuebix.org" target="_blank">Tübix</a>. It is the first time that this event is conducted. The location and the program seems to be very interesting.</p>
<p>Cornelius will do a <a href="http://www.tuebix.org/programm/koelbel-privacyidea/" target="_blank">workshop</a> there about installing privacyIDEA, enrolling tokens and authenticating at SSH. You should get an IDEA how easy it is to protect your private data and authenticate with two factors. Especially with a second factor that is totally under your control and not issued to you by any need-to-trust-me &#8220;authority&#8221; or &#8220;vendor&#8221;.</p>
<p>Therefor each attendee will get his own Yubikey, which he can initialized so that the cryptographic key material is only know to YOU. And you only.</p>
<p>You can also hear a <a href="http://www.tuebix.org/programm/koelbel-desktop_auth/" target="_blank">lightning talk</a> about the concept of locking your desktop with your smartphone but with an additional challenge response mechanism, which is more trustworthy then just a simple bluetooth coupling.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.privacyidea.org/otp-workshop-at-tubix/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Enforcing security policies: Security Levels with different OTP token types</title>
		<link>https://www.privacyidea.org/enforcing-security-policies-security-levels-with-different-otp-token-types/</link>
					<comments>https://www.privacyidea.org/enforcing-security-policies-security-levels-with-different-otp-token-types/#respond</comments>
		
		<dc:creator><![CDATA[Cornelius Kölbel]]></dc:creator>
		<pubDate>Mon, 07 Jul 2014 16:08:28 +0000</pubDate>
				<category><![CDATA[Howto]]></category>
		<category><![CDATA[Google Authenticator]]></category>
		<category><![CDATA[mass enrollment]]></category>
		<category><![CDATA[security level]]></category>
		<category><![CDATA[server farm]]></category>
		<category><![CDATA[Yubikey]]></category>
		<guid isPermaLink="false">https://www.privacyidea.org/?p=262</guid>

					<description><![CDATA[There are some good howtos around, so that you may already have secured your SSH login to your single server using Google Authenticator as described here. Or did you set up a Yubico validation server and configured Yubikey authentication for a bunch of hosts via RADIUS? Today I will show you, how you can setup [&#8230;]]]></description>
										<content:encoded><![CDATA[<p>There are some good howtos around, so that you may already have secured your SSH login to your single server using Google Authenticator as described <a href="http://www.blackmoreops.com/2014/06/26/securing-ssh-two-factor-authentication-using-google-authenticator/" target="_blank">here.</a> Or did you set up a Yubico validation server and configured Yubikey authentication for a <a href="http://www.andybotting.com/using-the-yubikey-for-two-factor-authentication-on-linux" target="_blank">bunch of hosts</a> via RADIUS?</p>
<p>Today I will show you, how you can setup a scenario, where users can authenticate with Yubikey and/or Google Authenticator and you can define centrally, for which server the users need a Yubikey to authenticate and for which other server a Google Authenticator would be sufficient. Thus you can enforce security levels, meaning servers carrying more sensitive data can only be accessed with a hardware device like the Yubikey while others are ok to be accessed with a software token like the Google Authenticator.</p>
<h2>Unique user, two tokens, many machines</h2>
<p>You should already have read about <a href="http://www.howtoforge.com/how-to-enroll-and-use-a-yubikey-with-pivacyidea" target="_blank">enrolling yubikeys</a> and how to use privacyIDEA for  <a href="http://www.howtoforge.com/manage-two-factor-authentication-in-your-serverfarm-with-privacyidea" target="_blank">two factor authentication to your server farm</a>. So I assume, that you have a running installation.</p>
<p>You should have enrolled two tokens to the user root as depicted below:</p>
<p><figure id="attachment_264" aria-describedby="caption-attachment-264" style="width: 300px" class="wp-caption alignnone"><a href="https://www.privacyidea.org/wp-content/uploads/2014/07/two-otp-tokens.png"><img loading="lazy" decoding="async" class="wp-image-264 size-medium" src="https://www.privacyidea.org/wp-content/uploads/2014/07/two-otp-tokens-300x170.png" alt="two-otp-tokens" width="300" height="170" srcset="https://www.privacyidea.org/wp-content/uploads/2014/07/two-otp-tokens-300x170.png 300w, https://www.privacyidea.org/wp-content/uploads/2014/07/two-otp-tokens.png 923w" sizes="auto, (max-width: 300px) 100vw, 300px" /></a><figcaption id="caption-attachment-264" class="wp-caption-text">One user with two tokens of different type</figcaption></figure></p>
<p>The user root has a Google Authenticator (serial OATH&#8230;, OTP PIN &#8220;google&#8221;) and a Yubikey (serial UBOM&#8230;, OTP PIN &#8220;yubi&#8221;) token.</p>
<p>Both tokens can be used to authenticate from all configured clients. From localhost (172.16.200.41):</p>
<pre><strong>[root@centos6 ~]#</strong> echo "User-Name=root, Password=google977398" | radclient -sx localhost auth testing123
Sending Access-Request of id 167 to 127.0.0.1 port 1812
 User-Name = "root"
 Password = "google977398"
rad_recv: Access-Accept packet from host 127.0.0.1 port 1812, id=167, length=48
 Reply-Message = "privacyIDEA access granted"
Total approved auths: 1
 Total denied auths: 0
 Total lost auths: 0
</pre>
<pre>[root@centos6 ~]# echo "User-Name=root, Password=yubi899739" | radclient -sx localhost auth testing123
Sending Access-Request of id 100 to 127.0.0.1 port 1812
 User-Name = "root"
 Password = "yubi899739"
rad_recv: Access-Accept packet from host 127.0.0.1 port 1812, id=100, length=48
 Reply-Message = "privacyIDEA access granted"
Total approved auths: 1
 Total denied auths: 0
 Total lost auths: 0</pre>
<p>Or from a remote host (172.16.200.106):</p>
<pre><strong>cornelius@puckel</strong> ~ % echo "User-Name=root, Password=google308786" | radclient -sx 172.16.200.41 auth testing123
Sending Access-Request of id 11 to 172.16.200.41 port 1812
    User-Name = "root"
    Password = "google308786"
rad_recv: Access-Accept packet from host 172.16.200.41 port 1812, id=11, length=48
    Reply-Message = "privacyIDEA access granted"

       Total approved auths:  1
       Total denied auths:  0
       Total lost auths:  0</pre>
<pre>cornelius@puckel ~ % echo "User-Name=root, Password=yubi867011" | radclient -sx 172.16.200.41 auth testing123
Sending Access-Request of id 47 to 172.16.200.41 port 1812
    User-Name = "root"
    Password = "yubi867011"
rad_recv: Access-Accept packet from host 172.16.200.41 port 1812, id=47, length=48
    Reply-Message = "privacyIDEA access granted"

       Total approved auths:  1
       Total denied auths:  0
       Total lost auths:  0
</pre>
<h2>The idea</h2>
<p>The idea is to allow access on the machine 172.16.200.106 only with yubikeys. This is the machine that carries tons of sensitive data and we do not want users to authenticate with their Google Authenticator.</p>
<h2>The host with the higher security level</h2>
<p>To accomplish this privacyIDEA provides a special <a href="https://privacyidea.org/doc/1.1/policies/authorization.html#serial" target="_blank">authorization policy</a> that will only grant access, if the the authentication was performed with the correct token.</p>
<p>So lets configure a policy:</p>
<p><figure id="attachment_272" aria-describedby="caption-attachment-272" style="width: 500px" class="wp-caption alignnone"><a href="https://www.privacyidea.org/wp-content/uploads/2014/07/sensitive.png"><img loading="lazy" decoding="async" class="wp-image-272" src="https://www.privacyidea.org/wp-content/uploads/2014/07/sensitive-300x159.png" alt="sensitive" width="500" height="266" srcset="https://www.privacyidea.org/wp-content/uploads/2014/07/sensitive-300x159.png 300w, https://www.privacyidea.org/wp-content/uploads/2014/07/sensitive-1024x544.png 1024w, https://www.privacyidea.org/wp-content/uploads/2014/07/sensitive.png 1025w" sizes="auto, (max-width: 500px) 100vw, 500px" /></a><figcaption id="caption-attachment-272" class="wp-caption-text">A policy restricting the access to the system to Yubikey token types.</figcaption></figure></p>
<p><figure id="attachment_274" aria-describedby="caption-attachment-274" style="width: 284px" class="wp-caption alignright"><a href="https://www.privacyidea.org/wp-content/uploads/2014/07/system-config.png"><img loading="lazy" decoding="async" class="wp-image-274 size-medium" src="https://www.privacyidea.org/wp-content/uploads/2014/07/system-config-284x300.png" alt="system-config" width="284" height="300" srcset="https://www.privacyidea.org/wp-content/uploads/2014/07/system-config-284x300.png 284w, https://www.privacyidea.org/wp-content/uploads/2014/07/system-config.png 608w" sizes="auto, (max-width: 284px) 100vw, 284px" /></a><figcaption id="caption-attachment-274" class="wp-caption-text">Override the client interformation</figcaption></figure></p>
<p>This policy tells the system, that if the client 172.16.200.106 issues an authentication request, it should only be approved, if the serial number of the authenticating token contains the string &#8220;UBOM&#8221;.</p>
<p><strong>Note: </strong>As we are using RADIUS the client 172.16.200.106 issues a radius request to the RADIUS server 172.16.200.41 and the RADIUS server issues the request to the privacyIDEA server 172.16.200.41/127.0.01. Thus the request that arrives at the privacyIDEA server will always be issued by the RADIUS server. So we need to allow the RADIUS server to overwrite the client information &#8211; thus the RADIUS server will tell the privacyIDEA server, what the calling RADIUS client was.</p>
<p>We can set this in the <strong>system config</strong>.</p>
<p>We set the localhost and the eth0 IP of the RADIUS server in a comma seperated list: <strong>127.0.0.1, 172.16.200.41</strong>.</p>
<p>The yubikey now can successfully authenticate at the sensitive host:</p>
<pre><strong>cornelius@puckel</strong> ~ % echo "User-Name=root, Password=yubi773998" | radclient -sx 172.16.200.41 auth testing123
Sending Access-Request of id 88 to 172.16.200.41 port 1812
 User-Name = "root"
 Password = "yubi773998"
rad_recv: Access-Accept packet from host 172.16.200.41 port 1812, id=88, length=48
 Reply-Message = "privacyIDEA access granted"
<strong> Total approved auths: 1</strong>
 Total denied auths: 0
 Total lost auths: 0</pre>
<p>while the Google Authenticator fails to do so:</p>
<pre><strong>cornelius@puckel</strong> ~ % echo "User-Name=root, Password=google850707" | radclient -sx 172.16.200.41 auth testing123
Sending Access-Request of id 24 to 172.16.200.41 port 1812
 User-Name = "root"
 Password = "google850707"
rad_recv: Access-Reject packet from host 172.16.200.41 port 1812, id=24, length=55
 Reply-Message = "privacyIDEA server denied access!"
 Total approved auths: 0
<strong> Total denied auths: 1</strong>
 Total lost auths: 0</pre>
<p>We can see this in the privacyIDEA audit log:</p>
<p><figure id="attachment_277" aria-describedby="caption-attachment-277" style="width: 300px" class="wp-caption alignnone"><a href="https://www.privacyidea.org/wp-content/uploads/2014/07/audit-fail.png"><img loading="lazy" decoding="async" class="wp-image-277 size-medium" src="https://www.privacyidea.org/wp-content/uploads/2014/07/audit-fail-300x34.png" alt="Google Authenticator fails to authenticate on the server 172.16.200.106 with the sensitive data." width="300" height="34" srcset="https://www.privacyidea.org/wp-content/uploads/2014/07/audit-fail-300x34.png 300w, https://www.privacyidea.org/wp-content/uploads/2014/07/audit-fail-1024x116.png 1024w, https://www.privacyidea.org/wp-content/uploads/2014/07/audit-fail.png 1296w" sizes="auto, (max-width: 300px) 100vw, 300px" /></a><figcaption id="caption-attachment-277" class="wp-caption-text">Google Authenticator fails to authenticate on the server 172.16.200.106 with the sensitive data.</figcaption></figure></p>
<h2>Google Authenticator is still good for default servers</h2>
<p>But we can still use the Google Authenticator for the default server with lower security level:</p>
<pre>[root@centos6 ~]# echo "User-Name=root, Password=google069728" | radclient -sx 172.16.200.41 auth testing123
Sending Access-Request of id 162 to 172.16.200.41 port 1812
    User-Name = "root"
    Password = "google069728"
rad_recv: Access-Accept packet from host 172.16.200.41 port 1812, id=162, length=48
    Reply-Message = "privacyIDEA access granted"

       Total approved auths:  1
         Total denied auths:  0
           Total lost auths:  0</pre>
<p>We can check this in the audit log, again:</p>
<p><figure id="attachment_279" aria-describedby="caption-attachment-279" style="width: 300px" class="wp-caption alignnone"><a href="https://www.privacyidea.org/wp-content/uploads/2014/07/audit-success.png"><img loading="lazy" decoding="async" class="wp-image-279 size-medium" src="https://www.privacyidea.org/wp-content/uploads/2014/07/audit-success-300x31.png" alt="Successfull authenticate on low security server 172.16.200.41" width="300" height="31" srcset="https://www.privacyidea.org/wp-content/uploads/2014/07/audit-success-300x31.png 300w, https://www.privacyidea.org/wp-content/uploads/2014/07/audit-success-1024x106.png 1024w, https://www.privacyidea.org/wp-content/uploads/2014/07/audit-success.png 1154w" sizes="auto, (max-width: 300px) 100vw, 300px" /></a><figcaption id="caption-attachment-279" class="wp-caption-text">Successfull authenticate on low security server 172.16.200.41</figcaption></figure></p>
<p>&nbsp;</p>
<h2>Conclusion</h2>
<p>privacyIDEA can be used to enroll many different authenticators to your users and mange these devices centrally.</p>
<p>In a second step you can decide <strong>who</strong> authenticates <strong>where</strong> with <strong>which</strong> device without bothering to reenroll any device.</p>
<p>Thus you can enforce your security policies easily. Additionally the audit log keeps track of all events that do not comply to your security policy.</p>
<p>&nbsp;</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.privacyidea.org/enforcing-security-policies-security-levels-with-different-otp-token-types/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
	</channel>
</rss>
