<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	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/"
		>
<channel>
	<title>Comments on: A better token algorithm with PHP</title>
	<atom:link href="http://www.jasny.net/articles/a-better-token-algorithm-with-php/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.jasny.net/articles/a-better-token-algorithm-with-php/</link>
	<description>Helping you out with PHP &#38; MySQL</description>
	<lastBuildDate>Wed, 25 Jan 2012 21:57:47 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
	<item>
		<title>By: Dino Zoff</title>
		<link>http://www.jasny.net/articles/a-better-token-algorithm-with-php/comment-page-1/#comment-338137</link>
		<dc:creator>Dino Zoff</dc:creator>
		<pubDate>Sat, 10 Dec 2011 23:45:17 +0000</pubDate>
		<guid isPermaLink="false">http://blog.adaniels.nl/?p=45#comment-338137</guid>
		<description>@&lt;a href=&quot;http://www.jasny.net/articles/a-better-token-algorithm-with-php/comment-page-1/#comment-226759&quot; rel=&quot;nofollow&quot;&gt;pmb&lt;/a&gt;: 

FAIL.</description>
		<content:encoded><![CDATA[<p>@<a href="http://www.jasny.net/articles/a-better-token-algorithm-with-php/comment-page-1/#comment-226759" rel="nofollow">pmb</a>: </p>
<p>FAIL.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Mike</title>
		<link>http://www.jasny.net/articles/a-better-token-algorithm-with-php/comment-page-1/#comment-338114</link>
		<dc:creator>Mike</dc:creator>
		<pubDate>Tue, 22 Nov 2011 21:41:49 +0000</pubDate>
		<guid isPermaLink="false">http://blog.adaniels.nl/?p=45#comment-338114</guid>
		<description>rand_alphanumeric is not a PHP function, it&#039;s a custom function:

&lt;code lang=&quot;php&quot;&gt;
// return random alphanumeric char
function rand_alphanumeric() {
    $subsets[0] = array(&#039;min&#039; =&gt; 48, &#039;max&#039; =&gt; 57); // ascii digits
    $subsets[1] = array(&#039;min&#039; =&gt; 65, &#039;max&#039; =&gt; 90); // ascii lowercase English letters
    $subsets[2] = array(&#039;min&#039; =&gt; 97, &#039;max&#039; =&gt; 122); // ascii uppercase English letters
   
    // random choice between lowercase, uppercase, and digits
    $s = rand(0, 2);
    $ascii_code = rand($subsets[$s][&#039;min&#039;], $subsets[$s][&#039;max&#039;]);
   
    return chr( $ascii_code );
}
&lt;/code&gt;

So if this is in a class you will probably want to call it with something like $this-&gt;rand_alphanumeric().</description>
		<content:encoded><![CDATA[<p>rand_alphanumeric is not a PHP function, it&#8217;s a custom function:</p>
<p><code lang="php"><br />
// return random alphanumeric char<br />
function rand_alphanumeric() {<br />
    $subsets[0] = array('min' =&gt; 48, 'max' =&gt; 57); // ascii digits<br />
    $subsets[1] = array('min' =&gt; 65, 'max' =&gt; 90); // ascii lowercase English letters<br />
    $subsets[2] = array('min' =&gt; 97, 'max' =&gt; 122); // ascii uppercase English letters</p>
<p>    // random choice between lowercase, uppercase, and digits<br />
    $s = rand(0, 2);<br />
    $ascii_code = rand($subsets[$s]['min'], $subsets[$s]['max']);</p>
<p>    return chr( $ascii_code );<br />
}<br />
</code></p>
<p>So if this is in a class you will probably want to call it with something like $this-&gt;rand_alphanumeric().</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Johan</title>
		<link>http://www.jasny.net/articles/a-better-token-algorithm-with-php/comment-page-1/#comment-249150</link>
		<dc:creator>Johan</dc:creator>
		<pubDate>Thu, 22 Jul 2010 07:41:11 +0000</pubDate>
		<guid isPermaLink="false">http://blog.adaniels.nl/?p=45#comment-249150</guid>
		<description>pmb - &quot;PHP Fatal error: Call to undefined function rand_alphanumeric()

FAIL.&quot;

its from maxims example.</description>
		<content:encoded><![CDATA[<p>pmb &#8211; &#8220;PHP Fatal error: Call to undefined function rand_alphanumeric()</p>
<p>FAIL.&#8221;</p>
<p>its from maxims example.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Arnold Daniels</title>
		<link>http://www.jasny.net/articles/a-better-token-algorithm-with-php/comment-page-1/#comment-226908</link>
		<dc:creator>Arnold Daniels</dc:creator>
		<pubDate>Sat, 01 May 2010 11:39:14 +0000</pubDate>
		<guid isPermaLink="false">http://blog.adaniels.nl/?p=45#comment-226908</guid>
		<description>Pmb: You didn&#039;t copy the code from Maxim Chernyak.</description>
		<content:encoded><![CDATA[<p>Pmb: You didn&#8217;t copy the code from Maxim Chernyak.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: pmb</title>
		<link>http://www.jasny.net/articles/a-better-token-algorithm-with-php/comment-page-1/#comment-226759</link>
		<dc:creator>pmb</dc:creator>
		<pubDate>Sat, 01 May 2010 02:44:56 +0000</pubDate>
		<guid isPermaLink="false">http://blog.adaniels.nl/?p=45#comment-226759</guid>
		<description>PHP Fatal error:  Call to undefined function rand_alphanumeric() 

FAIL.</description>
		<content:encoded><![CDATA[<p>PHP Fatal error:  Call to undefined function rand_alphanumeric() </p>
<p>FAIL.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: André Liechti</title>
		<link>http://www.jasny.net/articles/a-better-token-algorithm-with-php/comment-page-1/#comment-24435</link>
		<dc:creator>André Liechti</dc:creator>
		<pubDate>Sat, 26 Apr 2008 14:19:03 +0000</pubDate>
		<guid isPermaLink="false">http://blog.adaniels.nl/?p=45#comment-24435</guid>
		<description>A secure token grid authentication PHP class

Hello,

I finally decided to clean and distribute to the community a &lt;a href=&quot;http://syscoal.users.phpclasses.org/browse/package/4518.html&quot; rel=&quot;nofollow&quot;&gt;token grid class in PHP&lt;/a&gt;. You can have a look on it on the &lt;a href=&quot;http://syscoal.users.phpclasses.org/browse/package/4518.html&quot; rel=&quot;nofollow&quot;&gt;PHPclasses.org repository&lt;/a&gt;, licensed in LGPL.

You can produce a credit card sized printed token grid for each customer, and then each time they want to log in, we ask (in addition to the username and the password) the token at a specific position.

Each token (by default 10x10 on one card) are calculated using an application id, a user id and the position in the grid. The token generation is based on a md5 of the parameters (you can have a look in the source code)

Best regards, have a nice week-end.

Any feedback welcome!

André</description>
		<content:encoded><![CDATA[<p>A secure token grid authentication PHP class</p>
<p>Hello,</p>
<p>I finally decided to clean and distribute to the community a <a href="http://syscoal.users.phpclasses.org/browse/package/4518.html" rel="nofollow">token grid class in PHP</a>. You can have a look on it on the <a href="http://syscoal.users.phpclasses.org/browse/package/4518.html" rel="nofollow">PHPclasses.org repository</a>, licensed in LGPL.</p>
<p>You can produce a credit card sized printed token grid for each customer, and then each time they want to log in, we ask (in addition to the username and the password) the token at a specific position.</p>
<p>Each token (by default 10&#215;10 on one card) are calculated using an application id, a user id and the position in the grid. The token generation is based on a md5 of the parameters (you can have a look in the source code)</p>
<p>Best regards, have a nice week-end.</p>
<p>Any feedback welcome!</p>
<p>André</p>
]]></content:encoded>
	</item>
</channel>
</rss>
<!-- WP Super Cache is installed but broken. The path to wp-cache-phase1.php in wp-content/advanced-cache.php must be fixed! -->
