<?xml version="1.0" encoding="utf-8" ?>
<?xml-stylesheet href="/blog/templates/default/atom.css" type="text/css" ?>

<feed version="0.3" 
   xmlns="http://purl.org/atom/ns#"
   xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
   xmlns:dc="http://purl.org/dc/elements/1.1/"
   xmlns:admin="http://webns.net/mvcb/"
   xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
   xmlns:wfw="http://wellformedweb.org/CommentAPI/">
    <link href="http://pookey.co.uk/blog/rss.php?version=atom0.3" rel="service.feed" title="Ian P. Christian's personal blog" type="application/x.atom+xml" />
    <link href="http://pookey.co.uk/blog/"                        rel="alternate"    title="Ian P. Christian's personal blog" type="text/html" />
    <link href="http://pookey.co.uk/blog/rss.php?version=2.0"     rel="alternate"    title="Ian P. Christian's personal blog" type="application/rss+xml" />
    <title mode="escaped" type="text/html">Ian P. Christian's personal blog</title>
    <tagline mode="escaped" type="text/html">Random witterings from pookey </tagline>
    <id>http://pookey.co.uk/blog/</id>
    <modified>2008-05-14T09:20:37Z</modified>
    <generator url="http://www.s9y.org/" version="1.4-alpha1">Serendipity 1.4-alpha1 - http://www.s9y.org/</generator>
    <dc:language>en</dc:language>
    <info mode="xml" type="text/html">
        <div xmlns="http://www.w3.org/1999/xhtml">You are viewing an ATOM formatted XML site feed. Usually this file is inteded to be viewed in an aggregator or syndication software. If you want to know more about ATOM, please visist <a href="http://atomenabled.org/">Atomenabled.org</a></div>
    </info>

    <entry>
        <link href="http://pookey.co.uk/blog/archives/50-Symfony-security-concerns-and-other-issues.html" rel="alternate" title="Symfony security concerns and other issues" type="text/html" />
        <author>
            <name>Ian P. Christian</name>
                    </author>
    
        <issued>2008-05-13T09:31:22Z</issued>
        <created>2008-05-13T09:31:22Z</created>
        <modified>2008-05-14T09:20:37Z</modified>
        <wfw:comment>http://pookey.co.uk/blog/wfwcomment.php?cid=50</wfw:comment>
        <slash:comments>6</slash:comments>
        <wfw:commentRss>http://pookey.co.uk/blog/rss.php?version=atom0.3&amp;type=comments&amp;cid=50</wfw:commentRss>
    
        <id>http://pookey.co.uk/blog/archives/50-guid.html</id>
        <title mode="escaped" type="text/html">Symfony security concerns and other issues</title>
        <content type="application/xhtml+xml" xml:base="http://pookey.co.uk/blog/">
            <div xmlns="http://www.w3.org/1999/xhtml">
                <p>
First, I'm going to point out that I do love symfony - I'm mostly happy with it, and I'm a active member of the community. I certainly appreciate the effort put in by Fabien and everyone else who's worked on the symfony project - it's a fantastic achievement.  However, there's a couple of things which really wind me up, and I'm concerned things aren't going to change.
</p>
<p>
  One thing that's been pointed out <a href="http://groups.google.com/group/symfony-devs/browse_thread/thread/3f88104efda2867f/10a0a02d581cbcbb">several</a> <a href="http://groups.google.com/group/symfony-devs/browse_thread/thread/19268c1880978bcb/6d066b527358480d">times</a> in the past is that the symfony website is very unreliable.  I personally found the hosting so unstable I setup a <a href="http://pookey.co.uk/blog/archives/34-Symfony-SVN-mirror.html">SVN mirror</a> - and there's been requests for an <a href="http://groups.google.com/group/symfony-devs/browse_thread/thread/7844f5779521709f/baf673dbf034a456">offical symfony mirror</a>. This request however went unanswered.  Does it matter if the symfony site goes down?  Personally I think it matters, both for Sensio and for symfony. If Sensio can't keep the symfony site itself running, doesn't that set a bad image for the project?  It also sets a really  bad image for Sensio themselves - if they can't maintain a site's uptime  - would you want to use them for consultancy for your own projects?
</p>
<p>
  My other main concern is the way security is handled.  Today I noticed that <a href="http://trac.symfony-project.com/ticket/1617">Ticket #1617</a> had been closed in SVN logs.  This security issue has been open for a year!  Also, <a href="http://www.symfony-project.org/forum/index.php/m/5483/">I reported this issue</a> over 2 years ago.  There was no 'official' security advisory made about this - nor <a href="http://www.symfony-project.org/forum/index.php/m/3872/#msg_3872">other issues</a> that have occurred.
</p>
<p>
  In my opinion, mentioning these security issues just in the revision log, or the blog is not enough. There should be mails to the dev/user list - and a security procedure in place to handle issues.  In the past someone has come onto IRC and was concerned that a security issue they reported about bypassing validation using different HTTP verbs via email to Fabien personally was being ignored.  I'm sure Fabien is a busy man, but the symfony website needs to have how these things are handled documented.  I can't remember the outcome of this issue, and google didn't tell me much - maybe it was a non-issue, but if it wasn't - no security advisory was released.
</p>
<p>
  Other security issues have been discussed, such as <a href="http://groups.google.com/group/symfony-devs/browse_thread/thread/b5d6d2cf4b3a9def">the security of _dev.php files</a>, and <a href="http://groups.google.com/group/symfony-devs/browse_thread/thread/afeee2a065ca5910">the default permissions</a>. These issues haven't really been addressed in my opinion - and both are what I would consider critical issues.
</p>
<p>
  I accept that symfony is an open source project, and that we could fix these issues amongst the community - but I feel Sensio have an important role to place in this.  Sensio understandably keep a very tight grip on the project, but in doing so they take on certain responsibilities.  I would like to see more active discussion of security related issues on the dev list - with more involved responses from Sensio.  I'd like to see an announce mailing list where security and release information is published. I'd like to see current security issues highlighted and made VERY clear  on the main website.</p>
<p>
 I'd like a security reporting system documented and clearly linked from the ticketing system, so there's a clear channel to report security concerns, knowing they will be dealt with.
</p> 
            </div>
        </content>

        
    </entry>
    <entry>
        <link href="http://pookey.co.uk/blog/archives/49-Outputting-from-Postgres-to-CSV.html" rel="alternate" title="Outputting from Postgres to CSV" type="text/html" />
        <author>
            <name>Ian P. Christian</name>
                    </author>
    
        <issued>2008-05-06T09:53:53Z</issued>
        <created>2008-05-06T09:53:53Z</created>
        <modified>2008-05-06T09:53:53Z</modified>
        <wfw:comment>http://pookey.co.uk/blog/wfwcomment.php?cid=49</wfw:comment>
        <slash:comments>0</slash:comments>
        <wfw:commentRss>http://pookey.co.uk/blog/rss.php?version=atom0.3&amp;type=comments&amp;cid=49</wfw:commentRss>
    
        <id>http://pookey.co.uk/blog/archives/49-guid.html</id>
        <title mode="escaped" type="text/html">Outputting from Postgres to CSV</title>
        <content type="application/xhtml+xml" xml:base="http://pookey.co.uk/blog/">
            <div xmlns="http://www.w3.org/1999/xhtml">
                <p>
  I can never remember how to output to a CSV file from postgres, and end up having to google it time and time again - so I'm making a note of it here mostly for my own use <img src="http://pookey.co.uk/blog/templates/default/img/emoticons/smile.png" alt=":-)" style="display: inline; vertical-align: bottom;" class="emoticon" />
</p>
<pre>
\f ','
\a
\t
\o /tmp/moocow.csv
SELECT foo,bar FROM whatever;
\o
\q
</pre>
<p>
  If a field has newlines, this will break. You can do something like this instead.....
</p>
<pre>
 SELECT foo, bar, '"' || REPLACE(REPLACE(field_with_newilne, '\n', '\\n'), '"', '""') || '"' FROM whatever;
</pre> 
            </div>
        </content>

        
    </entry>
    <entry>
        <link href="http://pookey.co.uk/blog/archives/48-Monitoring-Dell-SAS-5iR-RAID-with-nagios.html" rel="alternate" title="Monitoring Dell SAS 5/iR RAID with nagios" type="text/html" />
        <author>
            <name>Ian P. Christian</name>
                    </author>
    
        <issued>2008-04-16T09:39:35Z</issued>
        <created>2008-04-16T09:39:35Z</created>
        <modified>2008-04-16T09:39:35Z</modified>
        <wfw:comment>http://pookey.co.uk/blog/wfwcomment.php?cid=48</wfw:comment>
        <slash:comments>0</slash:comments>
        <wfw:commentRss>http://pookey.co.uk/blog/rss.php?version=atom0.3&amp;type=comments&amp;cid=48</wfw:commentRss>
    
        <id>http://pookey.co.uk/blog/archives/48-guid.html</id>
        <title mode="escaped" type="text/html">Monitoring Dell SAS 5/iR RAID with nagios</title>
        <content type="application/xhtml+xml" xml:base="http://pookey.co.uk/blog/">
            <div xmlns="http://www.w3.org/1999/xhtml">
                <p>
  The Dell PERC/5 shows like this under 'lspci'
</p>
<pre>
07:08.0 SCSI storage controller: LSI Logic / Symbios Logic SAS1068 PCI-X Fusion-MPT SAS (rev 01)
        Subsystem: Dell SAS 5/iR Adapter RAID Controller
</pre>
<p>
  The status of this RAID card can be read using mpt-status, in Gentoo this package is available as sys-block/mpt-status.  Here's an example of the output:
</p>
<pre>
# mpt-status
ioc0 vol_id 0 type IM, 2 phy, 148 GB, state OPTIMAL, flags ENABLED
ioc0 phy 1 scsi_id 32 ATA      WDC WD1600JS-75N 2E04, 149 GB, state ONLINE, flags NONE
ioc0 phy 0 scsi_id 1 ATA      WDC WD1600JS-75N 2E04, 149 GB, state ONLINE, flags NONE
</pre>
<p>
  The latest 'check_mpt' script can be found on <a href="http://www.nagiosexchange.org/cgi-bin/page.cgi?g=2236.html;d=1">Nagios Exchange</a>.  Download it and put it in your libexec folder, for me on gentoo its '/usr/nagios/libexec/'.  Open the file, and make sure the 'use lib' line points to the correct place.
</p>
<p>
  The script uses sudo to run mpt-status, so you'll need to modify your /etc/sudoers - adding a line like this:
</p>
<pre>
%nagios ALL=(ALL) NOPASSWD:/usr/sbin/mpt-status
</pre>
<p>
Next, you need to configure nagios, your filenames might be different from the names I use below.
</p>
<p><b>/etc/nagios/commands.cfg</b> : Note, the -c param refers to the number of disks you expect to be active.</p>
<pre>

define command{
  command_name  check_mpt
  command_line  $USER1$/check_mpt -c 2
}
</pre>
<p><b>/etc/nagios/localhost.cfg</b></p>
<pre>
define service{
  use                  local-service
  host_name            localhost
  service_description  mpt - Dell Raid
  check_command        check_mpt
}
</pre>
<p>
  Reload nagios, on gentoo, it's /etc/init.d/nagios reload
</p> 
            </div>
        </content>

        
    </entry>
    <entry>
        <link href="http://pookey.co.uk/blog/archives/47-skinning-nagios-nagios-doenst-have-to-be-ugly!.html" rel="alternate" title="skinning nagios - nagios doens't have to be ugly!" type="text/html" />
        <author>
            <name>Ian P. Christian</name>
                    </author>
    
        <issued>2008-04-15T18:30:02Z</issued>
        <created>2008-04-15T18:30:02Z</created>
        <modified>2008-04-15T18:30:02Z</modified>
        <wfw:comment>http://pookey.co.uk/blog/wfwcomment.php?cid=47</wfw:comment>
        <slash:comments>0</slash:comments>
        <wfw:commentRss>http://pookey.co.uk/blog/rss.php?version=atom0.3&amp;type=comments&amp;cid=47</wfw:commentRss>
    
        <id>http://pookey.co.uk/blog/archives/47-guid.html</id>
        <title mode="escaped" type="text/html">skinning nagios - nagios doens't have to be ugly!</title>
        <content type="application/xhtml+xml" xml:base="http://pookey.co.uk/blog/">
            <div xmlns="http://www.w3.org/1999/xhtml">
                <p>
  Nagios can be pretty, and several people I've told this too seemed surprised, so I thought I'd put a quick note here. Here is a nice theme for nagios....
</p>
<p>
  <a href="http://new.nagiosexchange.org/cgi-bin/page.cgi?g=Detailed%2F1723.html;d=1">http://new.nagiosexchange.org/cgi-bin/page.cgi?g=Detailed%2F1723.html;d=1
</a>
</p>

<p>
  Unfortunately, the underlying UI is still the same horrible interface, but.... this does make a big difference to the aesthetics <img src="http://pookey.co.uk/blog/templates/default/img/emoticons/smile.png" alt=":-)" style="display: inline; vertical-align: bottom;" class="emoticon" />
</p> 
            </div>
        </content>

        
    </entry>
    <entry>
        <link href="http://pookey.co.uk/blog/archives/46-Review-of-the-N95-and-the-Forerunner-305.html" rel="alternate" title="Review of the N95 and the Forerunner 305" type="text/html" />
        <author>
            <name>Ian P. Christian</name>
                    </author>
    
        <issued>2008-03-28T21:02:00Z</issued>
        <created>2008-03-28T21:02:00Z</created>
        <modified>2008-03-28T22:02:14Z</modified>
        <wfw:comment>http://pookey.co.uk/blog/wfwcomment.php?cid=46</wfw:comment>
        <slash:comments>0</slash:comments>
        <wfw:commentRss>http://pookey.co.uk/blog/rss.php?version=atom0.3&amp;type=comments&amp;cid=46</wfw:commentRss>
    
        <id>http://pookey.co.uk/blog/archives/46-guid.html</id>
        <title mode="escaped" type="text/html">Review of the N95 and the Forerunner 305</title>
        <content type="application/xhtml+xml" xml:base="http://pookey.co.uk/blog/">
            <div xmlns="http://www.w3.org/1999/xhtml">
                <p>
  I've had a Forerunner 305 for a while now.  On  the rare occasion I go running, I find it really useful.  At first, I thought t would be a great geeky toy that I'd get bored of - I honestly expected it would find its way into a draw and never be used again after the first couple of uses.
</p>
<p>
  However, it's actually a great running accessory, and I advise this kinda hardware to all by the most casual of joggers.  It's far too easy to run too fast when you're out running - you can set the forerunner up to beep at you when you go too fast or too slow - obviously you configure these speeds yourself.  Recently I ran a half marathon, I did virtually no training for it, and without the forerunner on my wrist making sure I didn't run too fast or too slow, I'm not sure I'd have finished!
</p> <br /><a href="http://pookey.co.uk/blog/archives/46-Review-of-the-N95-and-the-Forerunner-305.html#extended">Continue reading "Review of the N95 and the Forerunner 305"</a>
            </div>
        </content>

        
    </entry>
    <entry>
        <link href="http://pookey.co.uk/blog/archives/45-Dell-PERC-6i-and-RAID-monitoring.html" rel="alternate" title="Dell PERC 6/i and RAID monitoring" type="text/html" />
        <author>
            <name>Ian P. Christian</name>
                    </author>
    
        <issued>2008-03-16T22:17:50Z</issued>
        <created>2008-03-16T22:17:50Z</created>
        <modified>2008-03-16T22:17:50Z</modified>
        <wfw:comment>http://pookey.co.uk/blog/wfwcomment.php?cid=45</wfw:comment>
        <slash:comments>0</slash:comments>
        <wfw:commentRss>http://pookey.co.uk/blog/rss.php?version=atom0.3&amp;type=comments&amp;cid=45</wfw:commentRss>
    
        <id>http://pookey.co.uk/blog/archives/45-guid.html</id>
        <title mode="escaped" type="text/html">Dell PERC 6/i and RAID monitoring</title>
        <content type="application/xhtml+xml" xml:base="http://pookey.co.uk/blog/">
            <div xmlns="http://www.w3.org/1999/xhtml">
                <p>
  A few pointers for people trying to get Dell's PERC 6/i RAID monitoring working under Ubuntu, and any other linux for that matter.  It also applies to PERC 5/i too, and... other stuff <img src="http://pookey.co.uk/blog/templates/default/img/emoticons/smile.png" alt=":-)" style="display: inline; vertical-align: bottom;" class="emoticon" />
</p>
<p>
  First, visit <a href="http://linux.dell.com/">Dells Linux site</a>.  Have a poke about, see what's there. 
</p>

<p>
 Next, we need to download a tool to get information from your array.  <a href="http://www.lsil.com/storage_home/products_home/internal_raid/megaraid_sas/megaraid_sas_8480e/index.html?remote=1&locale">Download LSI's MegaRAID CLI tool for linux</a>. It comes as a .RPM, so if you're an ubuntu user, you can convert it to a .deb using alien, or convert it to a .tar.gz.
</p>

<code>
# alien --to-tgz MegaCli-1.01.39-0.i386.rpm
</code>

<p>
  You then have a CLI tool you can use to get all your data now!  For example:
</p>

<code>
# ./opt/MegaRAID/MegaCli/MegaCli64  -LDInfo -Lall -aALL | grep State
State: Optimal
</code>

<p>
One thing I spent a while figuring out was how to get the rebuild progress, so here's how:
</p>

<code>
# ./opt/MegaRAID/MegaCli/MegaCli64  -PDRbld -ShowProg  -PhysDrv \[32:1\]  -aALL
</code>

<p>
  There's also a really <a href="http://tools.rapidsoft.de/perc/perc-cheat-sheet.pdf">useful cheat sheet for common tasks</a>
</p>

<p>
  Don't forget to actually monitor this output with nagios, or  your favorite monitoring tool!
</p> 
            </div>
        </content>

        
    </entry>
    <entry>
        <link href="http://pookey.co.uk/blog/archives/44-My-non-conclusion-about-MVC.html" rel="alternate" title="My non-conclusion about MVC" type="text/html" />
        <author>
            <name>Ian P. Christian</name>
                    </author>
    
        <issued>2008-03-05T10:28:14Z</issued>
        <created>2008-03-05T10:28:14Z</created>
        <modified>2008-03-08T14:29:56Z</modified>
        <wfw:comment>http://pookey.co.uk/blog/wfwcomment.php?cid=44</wfw:comment>
        <slash:comments>3</slash:comments>
        <wfw:commentRss>http://pookey.co.uk/blog/rss.php?version=atom0.3&amp;type=comments&amp;cid=44</wfw:commentRss>
    
        <id>http://pookey.co.uk/blog/archives/44-guid.html</id>
        <title mode="escaped" type="text/html">My non-conclusion about MVC</title>
        <content type="application/xhtml+xml" xml:base="http://pookey.co.uk/blog/">
            <div xmlns="http://www.w3.org/1999/xhtml">
                <p>
  A you might has been in <a href="http://pookey.co.uk/blog/archives/43-phplondon08-the-crazy-guy-mail.html">my previous post</a> there's quite a discussion about how a lot of PHP frameworks break MVC.
</p>
<p>
  I stayed clear of commenting, as I didn't want to get drawn in, however one comment did ask what I thought, so here it is!
</p> <br /><a href="http://pookey.co.uk/blog/archives/44-My-non-conclusion-about-MVC.html#extended">Continue reading "My non-conclusion about MVC"</a>
            </div>
        </content>

        
    </entry>
    <entry>
        <link href="http://pookey.co.uk/blog/archives/43-phplondon08-the-crazy-guy-mail.html" rel="alternate" title="phplondon08 - the 'crazy guy' mail" type="text/html" />
        <author>
            <name>Ian P. Christian</name>
                    </author>
    
        <issued>2008-03-04T09:09:37Z</issued>
        <created>2008-03-04T09:09:37Z</created>
        <modified>2008-03-10T22:57:37Z</modified>
        <wfw:comment>http://pookey.co.uk/blog/wfwcomment.php?cid=43</wfw:comment>
        <slash:comments>52</slash:comments>
        <wfw:commentRss>http://pookey.co.uk/blog/rss.php?version=atom0.3&amp;type=comments&amp;cid=43</wfw:commentRss>
    
        <id>http://pookey.co.uk/blog/archives/43-guid.html</id>
        <title mode="escaped" type="text/html">phplondon08 - the 'crazy guy' mail</title>
        <content type="application/xhtml+xml" xml:base="http://pookey.co.uk/blog/">
            <div xmlns="http://www.w3.org/1999/xhtml">
                <p>
  As you'll know from my previous post, I was 'heckled' during the Q&A of the framework talk I did.  This wasn't aimed at me, but rather at all 3 of us on the panel, and more importantly, at 'MVC' frameworks as we commonly see them today.  <a href="http://marcus.bointon.com/archives/54-PHPLondon08-follow-up.html">Marcus Boniton</a> also mentions this incident on his blog.
</p>
<p>
  Personally, I don't think he's a crazy guy, I just like the title and find it quite amusing <img src="http://pookey.co.uk/blog/templates/default/img/emoticons/wink.png" alt=";-)" style="display: inline; vertical-align: bottom;" class="emoticon" />
</p>
<p>
  I pointed the 'crazy guy' to my previous blog entry, where he replied to an author of one of the comments, and CCed me in.  I thought it was a very interesting mail, so it's included below.  I put this here with full permissions from Mike.
</p>
 <br /><a href="http://pookey.co.uk/blog/archives/43-phplondon08-the-crazy-guy-mail.html#extended">Continue reading "phplondon08 - the 'crazy guy' mail"</a>
            </div>
        </content>

        
    </entry>
    <entry>
        <link href="http://pookey.co.uk/blog/archives/42-phplondon08-My-symfony-talk.html" rel="alternate" title="phplondon08 - My symfony talk" type="text/html" />
        <author>
            <name>Ian P. Christian</name>
                    </author>
    
        <issued>2008-03-01T17:32:36Z</issued>
        <created>2008-03-01T17:32:36Z</created>
        <modified>2008-03-04T23:01:17Z</modified>
        <wfw:comment>http://pookey.co.uk/blog/wfwcomment.php?cid=42</wfw:comment>
        <slash:comments>9</slash:comments>
        <wfw:commentRss>http://pookey.co.uk/blog/rss.php?version=atom0.3&amp;type=comments&amp;cid=42</wfw:commentRss>
    
        <id>http://pookey.co.uk/blog/archives/42-guid.html</id>
        <title mode="escaped" type="text/html">phplondon08 - My symfony talk</title>
        <content type="application/xhtml+xml" xml:base="http://pookey.co.uk/blog/">
            <div xmlns="http://www.w3.org/1999/xhtml">
                <p>
  I talked at <a href="http://www.phpconference.co.uk/">PHPLondon Conference 08</a> yesterday.  I'm putting my slides online, here they are!
</p>

<p>
  <a href="/files/symfony.pdf">My phplondon08 symfony Presentation</a>
</p>

<p>
  I got slightly heckled, and was amazingly nervous because it was my first time talking, but I think it went well!  Apparently the audio recordings will be available at some point, I'll update this post when they are.
</p>
 
            </div>
        </content>

        
    </entry>
    <entry>
        <link href="http://pookey.co.uk/blog/archives/41-Nokia-Liveblog-Image-Uploading-Part-1.html" rel="alternate" title="Nokia Liveblog Image Uploading - Part 1" type="text/html" />
        <author>
            <name>Ian P. Christian</name>
                    </author>
    
        <issued>2008-02-27T10:15:45Z</issued>
        <created>2008-02-27T10:15:45Z</created>
        <modified>2008-03-01T17:54:32Z</modified>
        <wfw:comment>http://pookey.co.uk/blog/wfwcomment.php?cid=41</wfw:comment>
        <slash:comments>0</slash:comments>
        <wfw:commentRss>http://pookey.co.uk/blog/rss.php?version=atom0.3&amp;type=comments&amp;cid=41</wfw:commentRss>
    
        <id>http://pookey.co.uk/blog/archives/41-guid.html</id>
        <title mode="escaped" type="text/html">Nokia Liveblog Image Uploading - Part 1</title>
        <content type="application/xhtml+xml" xml:base="http://pookey.co.uk/blog/">
            <div xmlns="http://www.w3.org/1999/xhtml">
                <p>
  I'm calling this part 1, because I hope to follow it up at some point, although... who knows!
</p>

<p>
  I wanted to be able to upload my photos from my N95 directly to my website, and notice that S60 phones appear to have an option to upload to Flickr and Vox using the 'online services' system, so I figured adding my own shouldn't be too hard.  After a bit of googling, I found this:
</p>

<p>
  <a href="http://pookey.co.uk/files/lifeblog_posting_protocol_specification_1.0.pdf">lifeblog_posting_protocol_specification_1.0.pdf</a>
</p>

 <br /><a href="http://pookey.co.uk/blog/archives/41-Nokia-Liveblog-Image-Uploading-Part-1.html#extended">Continue reading "Nokia Liveblog Image Uploading - Part 1"</a>
            </div>
        </content>

        
    </entry>
    <entry>
        <link href="http://pookey.co.uk/blog/archives/40-Stateless-password-reset-system.html" rel="alternate" title="Stateless password reset system" type="text/html" />
        <author>
            <name>Ian P. Christian</name>
                    </author>
    
        <issued>2008-02-05T15:46:33Z</issued>
        <created>2008-02-05T15:46:33Z</created>
        <modified>2008-03-01T17:54:46Z</modified>
        <wfw:comment>http://pookey.co.uk/blog/wfwcomment.php?cid=40</wfw:comment>
        <slash:comments>0</slash:comments>
        <wfw:commentRss>http://pookey.co.uk/blog/rss.php?version=atom0.3&amp;type=comments&amp;cid=40</wfw:commentRss>
    
        <id>http://pookey.co.uk/blog/archives/40-guid.html</id>
        <title mode="escaped" type="text/html">Stateless password reset system</title>
        <content type="application/xhtml+xml" xml:base="http://pookey.co.uk/blog/">
            <div xmlns="http://www.w3.org/1999/xhtml">
                <p>
It's pretty common for sites to have a password reset system on websites, which allow you to enter your email address, and have the site email you a link you can use to reset your password.
</p>

<p>
I had a specification that demanded this kind of system, however it needed to be stateless - in that I could not store any extra information.  Also, the hash could only be used once, and it was required that it needed to time out after a configurable time period.  Also, the URL must be short enough such that it can be easily copied and pasted into the address bar from an email, and doesn't wrap in the email.
</p>
 <br /><a href="http://pookey.co.uk/blog/archives/40-Stateless-password-reset-system.html#extended">Continue reading "Stateless password reset system"</a>
            </div>
        </content>

        
    </entry>
    <entry>
        <link href="http://pookey.co.uk/blog/archives/38-Getting-PHP4-to-work-along-side-PHP5-in-Ubuntu-Gutsy.html" rel="alternate" title="Getting PHP4 to work along side PHP5 in Ubuntu Gutsy " type="text/html" />
        <author>
            <name>Ian P. Christian</name>
                    </author>
    
        <issued>2007-11-21T18:32:53Z</issued>
        <created>2007-11-21T18:32:53Z</created>
        <modified>2008-03-01T17:55:01Z</modified>
        <wfw:comment>http://pookey.co.uk/blog/wfwcomment.php?cid=38</wfw:comment>
        <slash:comments>3</slash:comments>
        <wfw:commentRss>http://pookey.co.uk/blog/rss.php?version=atom0.3&amp;type=comments&amp;cid=38</wfw:commentRss>
    
        <id>http://pookey.co.uk/blog/archives/38-guid.html</id>
        <title mode="escaped" type="text/html">Getting PHP4 to work along side PHP5 in Ubuntu Gutsy </title>
        <content type="application/xhtml+xml" xml:base="http://pookey.co.uk/blog/">
            <div xmlns="http://www.w3.org/1999/xhtml">
                <p>I got PHP4, compiled it as CGI.. here's how.</p>

<p>Install required packages</p>
<pre>
  apt-get install make libmysqlclient15-dev libmcrypt-dev libxpm-dev libpng12-dev \
libjpeg62-dev libcurl4-openssl-dev apache2-dev  gcc bison flex
</pre>
<p>configured as follows.</p>

<pre>
./configure --enable-force-cgi-redirect --disable-cli --enable-discard-path  \
 '--prefix=/home/pookey/php/' '--with-xml'  '--enable-bcmath' '--enable-calendar' \
 '--with-curl' '--enable-ftp' '--with-gd' '--with-jpeg-dir=/usr' '--with-png-dir=/usr' \
  '--with-xpm-dir=/usr/X11R6' '--with-mcrypt' '--enable-magic-quotes' \
 '--with-mysqli' '--with-mysql=/usr' '--with-openssl' \
  '--enable-discard-path' '--with-pear' '--enable-sockets' \
 '--enable-track-vars' '--enable-versioning' '--with-zlib'
</pre>
<p>
This installed it into /home/pookey/php
</p>
<p>
Enabled per vhost using the following syntax
</p>
<pre>
  SetEnv PHPRC /home/pookey/php/lib/stage
  ScriptAlias /php4-cgi /home/pookey/php/bin/php

  &lt;Location /&gt;
    Action php4-script /php4-cgi
    AddHandler php4-script .php
  &lt;/Location&gt;
</pre>

<p>
For some stupid reason I failed to figure out, doc_root needs to be set to the document root for each vhost, and can only be done in php.ini (setting PHP_DOCUMENTATION_ROOT with SetEnv failed).  This means each vhost needs it's own php.ini, which is placed wherever you set PHPRC to.</p>
<p>Using this system, you can have PHP4 and PHP5 mixed even on the same vhost</p> 
            </div>
        </content>

        
    </entry>
    <entry>
        <link href="http://pookey.co.uk/blog/archives/37-Trac-and-googlebot,-a-crafty-trick!.html" rel="alternate" title="Trac and googlebot, a crafty trick!" type="text/html" />
        <author>
            <name>Ian P. Christian</name>
                    </author>
    
        <issued>2007-10-29T22:58:59Z</issued>
        <created>2007-10-29T22:58:59Z</created>
        <modified>2008-03-01T17:55:12Z</modified>
        <wfw:comment>http://pookey.co.uk/blog/wfwcomment.php?cid=37</wfw:comment>
        <slash:comments>0</slash:comments>
        <wfw:commentRss>http://pookey.co.uk/blog/rss.php?version=atom0.3&amp;type=comments&amp;cid=37</wfw:commentRss>
    
        <id>http://pookey.co.uk/blog/archives/37-guid.html</id>
        <title mode="escaped" type="text/html">Trac and googlebot, a crafty trick!</title>
        <content type="application/xhtml+xml" xml:base="http://pookey.co.uk/blog/">
            <div xmlns="http://www.w3.org/1999/xhtml">
                <p>
  I noticed that google was going crazy indexing <a href="http://doctrine.pengus.net/trac">trac for doctrine</a>.  Today it downloaded over 90000 pages, transfering 3 gig of data!  It was causing quite a bit of load on the server (not huge amounts, but enough to show in my graphs!)
</p>

<p>
  Eventaully , I came up with a nice little trick for reducing the number of hits google will make against a trac install.  Google have extended robots.txt to allow some slightly improved pattern matching.  Here's my snippet, if you don't understand it, please don't use it.
</p>

<pre>
User-Agent: Googlebot
Disallow: /*?rev*
</pre> 
            </div>
        </content>

        
    </entry>
    <entry>
        <link href="http://pookey.co.uk/blog/archives/36-resizing-a-ext3-disk-image.html" rel="alternate" title="resizing a ext3 disk image" type="text/html" />
        <author>
            <name>Ian P. Christian</name>
                    </author>
    
        <issued>2007-10-23T10:27:12Z</issued>
        <created>2007-10-23T10:27:12Z</created>
        <modified>2008-03-01T17:55:27Z</modified>
        <wfw:comment>http://pookey.co.uk/blog/wfwcomment.php?cid=36</wfw:comment>
        <slash:comments>0</slash:comments>
        <wfw:commentRss>http://pookey.co.uk/blog/rss.php?version=atom0.3&amp;type=comments&amp;cid=36</wfw:commentRss>
    
        <id>http://pookey.co.uk/blog/archives/36-guid.html</id>
        <title mode="escaped" type="text/html">resizing a ext3 disk image</title>
        <content type="application/xhtml+xml" xml:base="http://pookey.co.uk/blog/">
            <div xmlns="http://www.w3.org/1999/xhtml">
                <p>
Took me a while to figure this out, so thought I'd put it here for others. This is useful for Xen setups, where you use a file for the disk image.  AFAIK, you can only  grow an image, not shrink it.
</p>

<pre>
# dd if=/dev/zero bs=1M count=1024 >> disk.img
# e2fsck -f disk.img
# resize2fs disk.img
# e2fsck -f disk.img
</pre>

<p>
  This makes the disk image bigger, checks the image, resizes the file system, and then checks it again
</p> 
            </div>
        </content>

        
    </entry>
    <entry>
        <link href="http://pookey.co.uk/blog/archives/35-Finally,-Namespaces-in-PHP.html" rel="alternate" title="Finally, Namespaces in PHP?" type="text/html" />
        <author>
            <name>Ian P. Christian</name>
                    </author>
    
        <issued>2007-10-02T09:15:33Z</issued>
        <created>2007-10-02T09:15:33Z</created>
        <modified>2007-10-02T09:15:33Z</modified>
        <wfw:comment>http://pookey.co.uk/blog/wfwcomment.php?cid=35</wfw:comment>
        <slash:comments>0</slash:comments>
        <wfw:commentRss>http://pookey.co.uk/blog/rss.php?version=atom0.3&amp;type=comments&amp;cid=35</wfw:commentRss>
    
        <id>http://pookey.co.uk/blog/archives/35-guid.html</id>
        <title mode="escaped" type="text/html">Finally, Namespaces in PHP?</title>
        <content type="application/xhtml+xml" xml:base="http://pookey.co.uk/blog/">
            <div xmlns="http://www.w3.org/1999/xhtml">
                <p>
  <a href="http://blog.agoraproduction.com/index.php?/archives/51-Namespaces-has-PHP-5.3-Or-the-other-way-around.html">Check out this blog post</a>.  Looks promising, PHP might finally get name spaces, and somehow, they have managed to use the '::' separator!  Great news, but I'm not going to believe it till I see it released, even though it's been checked into SVN already <img src="http://pookey.co.uk/blog/templates/default/img/emoticons/smile.png" alt=":-)" style="display: inline; vertical-align: bottom;" class="emoticon" />
</p> 
            </div>
        </content>

        
    </entry>
</feed>