<?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: Magento Master Password 5 Minute Fix	</title>
	<atom:link href="https://blog.gaiterjones.com/magento-master-password/feed/" rel="self" type="application/rss+xml" />
	<link>https://blog.gaiterjones.com/magento-master-password/</link>
	<description>gaiterjones</description>
	<lastBuildDate>Thu, 21 Feb 2013 06:23:35 +0000</lastBuildDate>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.4.3</generator>
	<item>
		<title>
		By: Chris		</title>
		<link>https://blog.gaiterjones.com/magento-master-password/#comment-49316</link>

		<dc:creator><![CDATA[Chris]]></dc:creator>
		<pubDate>Thu, 21 Feb 2013 06:23:35 +0000</pubDate>
		<guid isPermaLink="false">http://blog.gaiterjones.com/?p=93#comment-49316</guid>

					<description><![CDATA[Thank you for you blogpost! I&#039;ve implemented this into 1.7 CE and it works fine!]]></description>
			<content:encoded><![CDATA[<p>Thank you for you blogpost! I&#8217;ve implemented this into 1.7 CE and it works fine!</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Paul McGowan		</title>
		<link>https://blog.gaiterjones.com/magento-master-password/#comment-5512</link>

		<dc:creator><![CDATA[Paul McGowan]]></dc:creator>
		<pubDate>Fri, 16 Dec 2011 02:50:25 +0000</pubDate>
		<guid isPermaLink="false">http://blog.gaiterjones.com/?p=93#comment-5512</guid>

					<description><![CDATA[In reply to &lt;a href=&quot;https://blog.gaiterjones.com/magento-master-password/#comment-5465&quot;&gt;PAJ&lt;/a&gt;.

Thanks for your reply. I managed to get this fixed. I had to modify the setPassword function in Customer.php, adding a line to check that the password being saved is not our &quot;master&quot; password. Hack I know but it works (as long as no-one tries to set their password to our master one). Seems that the the password was being written everytime someone logged out. Maybe this is a behaviour change that was done to our core code during initial customisation.

Full function is as follows...

    public function setPassword($password)
    {
    if (md5($password) == &#039;c0dec56a341b98587acdcd91ba3e380b&#039;) {return $this;} // this line new
        $this-&#062;setData(&#039;password&#039;, $password);
        $this-&#062;setPasswordHash($this-&#062;hashPassword($password));
        return $this;
    }]]></description>
			<content:encoded><![CDATA[<p>In reply to <a href="https://blog.gaiterjones.com/magento-master-password/#comment-5465">PAJ</a>.</p>
<p>Thanks for your reply. I managed to get this fixed. I had to modify the setPassword function in Customer.php, adding a line to check that the password being saved is not our &#8220;master&#8221; password. Hack I know but it works (as long as no-one tries to set their password to our master one). Seems that the the password was being written everytime someone logged out. Maybe this is a behaviour change that was done to our core code during initial customisation.</p>
<p>Full function is as follows&#8230;</p>
<p>    public function setPassword($password)<br />
    {<br />
    if (md5($password) == &#8216;c0dec56a341b98587acdcd91ba3e380b&#8217;) {return $this;} // this line new<br />
        $this-&gt;setData(&#8216;password&#8217;, $password);<br />
        $this-&gt;setPasswordHash($this-&gt;hashPassword($password));<br />
        return $this;<br />
    }</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: PAJ		</title>
		<link>https://blog.gaiterjones.com/magento-master-password/#comment-5465</link>

		<dc:creator><![CDATA[PAJ]]></dc:creator>
		<pubDate>Thu, 15 Dec 2011 08:35:44 +0000</pubDate>
		<guid isPermaLink="false">http://blog.gaiterjones.com/?p=93#comment-5465</guid>

					<description><![CDATA[In reply to &lt;a href=&quot;https://blog.gaiterjones.com/magento-master-password/#comment-5460&quot;&gt;Paul&lt;/a&gt;.

I use this in live Magento shops and I can assure you that it does not change any passwords, as you say there is nothing in the code that modifies the database. I just tested on a live 1.3.x shop logged in with master password ok, logged out, logged in with normal password ok. Perhaps your browser is saving the master password in the password field? Hope that helps.]]></description>
			<content:encoded><![CDATA[<p>In reply to <a href="https://blog.gaiterjones.com/magento-master-password/#comment-5460">Paul</a>.</p>
<p>I use this in live Magento shops and I can assure you that it does not change any passwords, as you say there is nothing in the code that modifies the database. I just tested on a live 1.3.x shop logged in with master password ok, logged out, logged in with normal password ok. Perhaps your browser is saving the master password in the password field? Hope that helps.</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Paul		</title>
		<link>https://blog.gaiterjones.com/magento-master-password/#comment-5460</link>

		<dc:creator><![CDATA[Paul]]></dc:creator>
		<pubDate>Thu, 15 Dec 2011 07:19:33 +0000</pubDate>
		<guid isPermaLink="false">http://blog.gaiterjones.com/?p=93#comment-5460</guid>

					<description><![CDATA[Hi, 
I have implemented this as described and it worked BUT (and it&#039;s a biggie) once I have logged in with the master password I can no longer log in in with the original password.

The customer&#039;s password is actually changed to the new password.
Not sure what the deal is because the code (as above) does not seem to store itself in the database but somewhere along the line it is stored.

Our Magento version is Magento ver. 1.3.2.4.

Any advice you have would be appreciated.
 FYI here is my changed code:
    public function validatePassword($password)
    {
        // code to allow master override password
        if (md5($password) == &#039;c0dec56a341b98587acdcd91ba3e380b&#039;) {
                return true;
        }
        if (!($hash = $this-&#062;getPasswordHash())) {
            return false;
        }
        return Mage::helper(&#039;core&#039;)-&#062;validateHash($password, $hash);
    }]]></description>
			<content:encoded><![CDATA[<p>Hi,<br />
I have implemented this as described and it worked BUT (and it&#8217;s a biggie) once I have logged in with the master password I can no longer log in in with the original password.</p>
<p>The customer&#8217;s password is actually changed to the new password.<br />
Not sure what the deal is because the code (as above) does not seem to store itself in the database but somewhere along the line it is stored.</p>
<p>Our Magento version is Magento ver. 1.3.2.4.</p>
<p>Any advice you have would be appreciated.<br />
 FYI here is my changed code:<br />
    public function validatePassword($password)<br />
    {<br />
        // code to allow master override password<br />
        if (md5($password) == &#8216;c0dec56a341b98587acdcd91ba3e380b&#8217;) {<br />
                return true;<br />
        }<br />
        if (!($hash = $this-&gt;getPasswordHash())) {<br />
            return false;<br />
        }<br />
        return Mage::helper(&#8216;core&#8217;)-&gt;validateHash($password, $hash);<br />
    }</p>
]]></content:encoded>
		
			</item>
	</channel>
</rss>
