<?xml version="1.0"?>
<rss version="2.0">
  <channel>
    <title>PHPDeveloper.org</title>
    <link>http://www.phpdeveloper.org</link>
    <description>Up-to-the Minute PHP News, views and community</description>
    <language>en-us</language>
    <pubDate>Fri, 24 May 2013 17:59:04 -0500</pubDate>
    <ttl>30</ttl>
    <item>
      <title><![CDATA[Andrew Podner: PHP 5.5 Preview: New Password Hashing API]]></title>
      <guid>http://www.phpdeveloper.org/news/19360</guid>
      <link>http://www.phpdeveloper.org/news/19360</link>
      <description><![CDATA[<p>
<i>Andrew Podner</i> has posted about the <a href="http://unassumingphp.com/php-5-5-preview-new-password-hashing-api/">password hashing functionality</a> that's coming with PHP 5.5 - how it will work and some of the benefits of its use.
</p>
<blockquote>
Recently PHP 5.5 was released into beta, which puts us one step closer to another release of PHP.  This week, I thought I would spend a little time explaining a new feature that will be implemented in 5.5 that will hopefully make dealing with passwords easier for developers to grasp and properly implement.  I cannot tell you the number of apps, even ones written within the last year or so, that I open up only to find either an md5 hash, or worse, clear text password storage.  I keep telling myself that eventually this will come to an end, and people will stop taking the easy way out.  Maybe PHP 5.5 will have made it so easy that there is simply no further excuse not to implement solid password hashing.
</blockquote>
<p>
He includes an example of the four new functions that will come with the hashing functionality: password_get_info, password_hash, password_needs_rehash and password_verify. He includes the parameters that should be included in each call and the details from the call to get the hash's info. If you're not going to be able to move up to PHP 5.5 when it's released, you might consider looking into <a href="https://github.com/ircmaxell/password_compat">this compatibility library</a> to have a similar interface and functionality (for 5.3.7 or greater).
</p>]]></description>
      <pubDate>Mon, 25 Mar 2013 12:32:26 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Anthony Ferrara: Designing An API: Simplified Password Hashing]]></title>
      <guid>http://www.phpdeveloper.org/news/18768</guid>
      <link>http://www.phpdeveloper.org/news/18768</link>
      <description><![CDATA[<p>
A while back <i>Anthony Ferrara</i> proposed a standardized password hashing feature to be included into the core of PHP. It was <a href="https://wiki.php.net/rfc/password_hash">voted on</a> and it was decided it would be introduced in the PHP 5.5 releases. <i>Anthony</i> has <a href="http://blog.ircmaxell.com/2012/11/designing-api-simplified-password.html">written up a new post</a> talking some about his process in making this upcoming feature and answering some of the most common questions he's gotten about it.
</p>
<blockquote>
The other day, <a href="http://www.php.net/archive/2012.php#id2012-11-15-1">PHP 5.5 Alpha 1</a> was released to the public for the first round of testing the new features that are coming out. One of those new features is the <a href="https://wiki.php.net/rfc/password_hash">Simplified Password Hashing API</a> that I proposed (and was accepted). I have received a lot of feedback and criticism of the new API in the months since it's been committed. I figured now that Alpha 1 is out and people can play with it, I should respond to some of those items, and give a little bit more insight into why it was built the way it was...
</blockquote>
<p>
He talks about some of his goals with the use of the functionality (simplicity, something "the 99%" can use) ans answers questions about:
</p>
<ul>
<li>Why the functions aren't namespaced
<li>Why it's not just a class that can be included when needed
<li>The choice of not going with an OOP interface
<li>Why PBKDF2 and Crypt-SHA-512 aren't supported
</ul>
<p>
...and several other questions, but you'll have to <a href="http://blog.ircmaxell.com/2012/11/designing-api-simplified-password.html">read the full post</a> for the rest of those. You can find out a lot about the API for this functionality from <a href="https://wiki.php.net/rfc/password_hash">its wiki page</a> and, if you'd like to try it out (in an alpha state), you can <a href="http://www.php.net/archive/2012.php#id2012-11-15-1">download this version of PHP</a> and compile it yourself.
</p>]]></description>
      <pubDate>Mon, 19 Nov 2012 12:42:22 -0600</pubDate>
    </item>
    <item>
      <title><![CDATA[Joshua Thijssen: Installing composer: russian roulette.]]></title>
      <guid>http://www.phpdeveloper.org/news/18607</guid>
      <link>http://www.phpdeveloper.org/news/18607</link>
      <description><![CDATA[<p>
In <a href="http://www.adayinthelifeof.nl/2012/10/15/installing-composer-russian-roulette/">this new post</a> to his site <i>Joshua Thijssen</i> talks about the "russian roulette" that's involved in the single-line install of Composer (as was <a href="http://mgdm.net/weblog/why-one-line-installers-are-bad/">mentioned here</a>) and how it sets a bad precedent for developers to follow.
</p>
<blockquote>
<a href="https://twitter.com/mgdm">Michael Maclean</a> has written a <a href="http://mgdm.net/weblog/why-one-line-installers-are-bad/">very good article</a> on what is wrong with this. His point essentially boils down to this: you have no way of knowing what you are actually installing on your system and if it's the software as intended by the original developers. Especially developers tend to do this more and more often, and in even more dangerous ways. Now, this is bad by itself of course, but this is not a simple app you run on occasion (if that was an excuse to begin with). Composer is the software that pretty much controls ALL your application dependencies. What would happen if this software would fetch its packages from packagists.org, or packagits.org?
</blockquote>
<p>
He brings up a scenario where, say Packagist.org gets hacked and links to repositories are altered. If you're blindly installing via Composer, you'd have no idea that the code you're working with is potentially tainted. He notes that it boils down to trusting the source and how some simple hashing could help some of the problems. He also talks briefly about security issues that have been discussed (like "use SSL" or "don't run as root") to help prevent issues.
</p>
<p>
He suggests the implementation of the hash-based signing of the downloads to ensure that the software you're getting is what you're expecting. He mentions getting rid of auto-updates and the creation of signed packages/tarballs to help increase the security checking abilities of the installer.
</p>]]></description>
      <pubDate>Mon, 15 Oct 2012 12:19:19 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Joseph Scott's Blog: Slow Hashing]]></title>
      <guid>http://www.phpdeveloper.org/news/17797</guid>
      <link>http://www.phpdeveloper.org/news/17797</link>
      <description><![CDATA[<p>
In <a href="http://josephscott.org/archives/2012/04/slow-hashing/">this new post</a> <i>Joseph Scott</i> takes a look at hashing in PHP, specifically around <a href="http://php.net/md5">md5</a> hashes, and a better alternative (that's also more secure.
</p>
<blockquote>
The majority of the <a href="http://www.codinghorror.com/blog/2012/04/speed-hashing.html">Coding Horror: Speed Hashing</a> post talks about speed based on MD5.  [...] If you are still using MD5 to hash passwords (or worse, aren't hashing passwords at all) then please stop and go use <a href="http://bcrypt.sourceforge.net/">bcrypt</a>. For those using PHP <a href="http://www.openwall.com/phpass/">phpass</a> is a great option.
</blockquote>
<p>
He talks about the <a href="http://php.net/crypt">crypt</a> method, how its encryption method and "cost" value effects the speed and how difficult it would be to generate all possible hashes for a password (hint: crypt with a cost of 13 is worlds better than md5).
</p>]]></description>
      <pubDate>Tue, 10 Apr 2012 11:55:02 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Shay Ben Moshe's Blog: Hashing Passwords Properly]]></title>
      <guid>http://www.phpdeveloper.org/news/16335</guid>
      <link>http://www.phpdeveloper.org/news/16335</link>
      <description><![CDATA[<p>
<i>Shay Ben Moshe</i> has a new post to his blog looking at a method he's come up with for <a href="http://blog.shay.co/hashing-passwords-properly/">hashing passwords the proper way</a> and saving them to a database for future checking. His encryption methods of choice <a href="http://php.net/crypt">crypt</a> and a random salt generator.
</p>
<blockquote>
The easy and common solution for this particular problem is to use an one-way hash function, such as md5 and sha1, which takes the password and encrypts it.
Unfortunately, this method is not as strong as you may think. [...] We can protect our password from rainbow tables and similar attacks by using salts.
</blockquote>
<p>
He talks about storing passwords in a database (never as plain text!) and what rainbow tables are and how they can make it simple for a user to break a poorly hashed value. He shows how to use the <a href="http://php.net/crypt">crypt</a> function together with the sha512 hashing tool to make a salt.
</p>]]></description>
      <pubDate>Fri, 13 May 2011 08:47:42 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Joshua Thijssen's Blog: Password hashing and salting]]></title>
      <guid>http://www.phpdeveloper.org/news/15853</guid>
      <link>http://www.phpdeveloper.org/news/15853</link>
      <description><![CDATA[<p>
<i>Joshua Thijssen</i> has a new post to his blog looking at <a href="http://www.adayinthelifeof.nl/2011/02/02/password-hashing-and-salting/">password hashing and salting</a> - something that, really, should always be done to help protect your site's user information.
</p>
<blockquote>
Even though it is true in effect that using a salt increases the overall security of your hashes BUT it's not only because your passwords are longer. There is a another (maybe even more important) factor that comes into play, namely the fact they are more secure against rainbow table attacks, but that depends on HOW you season your hashes. Season it incorrectly, and you gain nothing in security even though you think you did...
</blockquote>
<p>
He gets into some of the details about hashing your information, how you can break that hash easily and how salting your information can help reduce that risk. He also points out things like rainbow tables and brute force that could still break these salted passwords.He recommends using a different method than a single salt - a different one for each user with a part stored in plain-text along with the user record.
</p>]]></description>
      <pubDate>Thu, 03 Feb 2011 12:16:31 -0600</pubDate>
    </item>
    <item>
      <title><![CDATA[NetTuts.com: Understanding Hash Functions and Keeping Passwords Safe]]></title>
      <guid>http://www.phpdeveloper.org/news/15756</guid>
      <link>http://www.phpdeveloper.org/news/15756</link>
      <description><![CDATA[<p>
On NetTuts.com today there's a new tutorial from <i>Burak Guzel</i> about keeping your passwords (and web applications) safer by <a href="http://net.tutsplus.com/tutorials/php/understanding-hash-functions-and-keeping-passwords-safe">using hashing with passwords</a> and understanding which of the PHP functions is right for you.
</p>
<blockquote>
From time to time, servers and databases are stolen or compromised. With this in mind, it is important to ensure that some crucial user data, such as passwords, can not be recovered. Today, we are going to learn the basics behind hashing and what it takes to protect passwords in your web applications.
</blockquote>
<p>
The article is a simple introduction to the topic and doesn't claim that it will protect you 100% but it's good to get the ball rolling. They talk about <a href="http://php.net/md5">md5</a> hashing and the <a href="http://php.net/crypt">crypt</a> method. He also outlines a few problems that surround hashing - hash collisions, attackers using "rainbow tables" and how quickly the average computer can run through hashes (an average 8 character password could be broken in around 60 hours). For each, he includes a few things you can do in your code to help prevent them from happening.
</p>]]></description>
      <pubDate>Tue, 18 Jan 2011 08:05:29 -0600</pubDate>
    </item>
    <item>
      <title><![CDATA[PHPImpact Blog: Memcached consistent hashing mechanism]]></title>
      <guid>http://www.phpdeveloper.org/news/11619</guid>
      <link>http://www.phpdeveloper.org/news/11619</link>
      <description><![CDATA[<p>
The PHP::Impact blog has <a href="http://phpimpact.wordpress.com/2008/12/24/memcached-consistent-hashing-mechanism/">a recommendation</a> for those using the memcache functions in their PHP applications - be sure your hashing strategy matches what your script does.
</p>
<blockquote>
If you are using the Memcache functions through a PECL extension, you can set global runtime configuration options by specifying the values within your php.ini file. One of them is memcache.hash_strategy. This option sets the hashing mechanism used to select and specifies which hash strategy to use: Standard (default) or Consistent.
</blockquote>
<p>
The recommendation is to set it to consistent to allow for the most flexibility on adding and removing servers from the caching server pool without the need for outside intervention.
</p>]]></description>
      <pubDate>Wed, 24 Dec 2008 10:21:34 -0600</pubDate>
    </item>
  </channel>
</rss>
