<?xml version="1.0"?>
<rss version="2.0">
	<channel>
		<title>Forum posts to 'Extending and hacking'</title>
		<link>http://www.silverstripe.com/extending-hacking-silverstripe-forum/</link>
		

		
		<item>
			<title>Re: Setting Security it use sha1 but no salt.</title>
			<link>http://www.silverstripe.com/extending-hacking-silverstripe-forum/show/63803?showPost=68702</link>
			<description>Thanks for pointing that out Sam, my problem is now solved!&lt;br&gt;&lt;br&gt;Posted to: Setting Security it use sha1 but no salt.</description>
			<pubDate>Fri, 09 May 2008 11:06:02 +1200</pubDate>
			<author>Josh Kosmala</author>
			<guid>http://www.silverstripe.com/extending-hacking-silverstripe-forum/show/63803?showPost=68702</guid>
		</item>
		
		<item>
			<title>Re: Setting Security it use sha1 but no salt.</title>
			<link>http://www.silverstripe.com/extending-hacking-silverstripe-forum/show/63803?showPost=68644</link>
			<description>The encrypted password is then packed into a base 36 number (0-9 then A-Z).  I wouldn't have necessary built it this way, but it's difficult to change now without breaking everyone's sites.  &lt;br /&gt;&lt;br /&gt;// Convert the base of the hexadecimal password to 36 to make it shorter&lt;br /&gt;// In that way we can store also a SHA256 encrypted password in just 64&lt;br /&gt;// letters.&lt;br /&gt;$password = substr(base_convert($password, 16, 36), 0, 64);&lt;br /&gt;&lt;br /&gt;Perhaps we could add additional encryption types to the Password encryption column, like sha1-unpacked, which would skip this procedure?  Using a string-suffix like this would require fewer API changes than adding a 3rd encryption parameter.&lt;br&gt;&lt;br&gt;Posted to: Setting Security it use sha1 but no salt.</description>
			<pubDate>Fri, 09 May 2008 09:24:11 +1200</pubDate>
			<author>Sam Minnee</author>
			<guid>http://www.silverstripe.com/extending-hacking-silverstripe-forum/show/63803?showPost=68644</guid>
		</item>
		
		<item>
			<title>Setting Security it use sha1 but no salt.</title>
			<link>http://www.silverstripe.com/extending-hacking-silverstripe-forum/show/63803</link>
			<description>Hey,&lt;br /&gt;&lt;br /&gt;I'm trying to migrate a site from a CMS that uses straight SHA1 encryption - but can't get my SS site to encrypt in SHA1 only.&lt;br /&gt;&lt;br /&gt;I have set the following lines in sapphire/_config.php&lt;br /&gt;&lt;br /&gt;Security::encrypt_passwords(true);&lt;br /&gt;Security::set_password_encryption_algorithm('sha1', false);&lt;br /&gt;&lt;br /&gt;and also set the current values in Security.php&lt;br /&gt;&lt;br /&gt;protected static $encryptPasswords = true;&lt;br /&gt;protected static $encryptionAlgorithm = 'sha1';&lt;br /&gt;protected static $useSalt = false;&lt;br /&gt;&lt;br /&gt;however the site is not using straight SHA1. The salt column in the db is now NULL but it's still a strange encryption that won't match the old user passwords which are all sha1.&lt;br /&gt;&lt;br /&gt;SS 2.2.1&lt;br /&gt;&lt;br /&gt;Any ideas where i'm going wrong?&lt;br /&gt;&lt;br /&gt;Cheers,&lt;br /&gt;Josh&lt;br&gt;&lt;br&gt;Posted to: Setting Security it use sha1 but no salt.</description>
			<pubDate>Wed, 30 Apr 2008 16:34:13 +1200</pubDate>
			<author>Josh Kosmala</author>
			<guid>http://www.silverstripe.com/extending-hacking-silverstripe-forum/show/63803</guid>
		</item>
		

	</channel>
</rss>
