<?xml version="1.0" encoding="utf-8"?><feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en-GB"><title>Comments on Writing Secure PHP, Part 4 - AddedBytes.com</title><link rel="alternate" type="text/html" href="http://www.addedbytes.com/article/writing-secure-php-4/" /><link rel="self" type="application/xml" href="http://www.addedbytes.com/article/writing-secure-php-4/comments/atom/" /><subtitle>Latest comments on Writing Secure PHP, Part 4 on AddedBytes.com</subtitle><author><name>Dave Child</name></author><updated>2008-09-11T13:11:14Z</updated><id>tag:addedbytes.com,2008:413</id><!-- ckey="76C662BB" --><entry><title>Comment on Writing Secure PHP, Part 4</title><link rel="alternate" type="text/html" href="http://www.addedbytes.com/article/writing-secure-php-4/comments/" /><summary type="text">Comment by Pete ( &lt;a href="http://dev-notes.com"&gt;http://dev-notes.com&lt;/a&gt; )&lt;br /&gt;&lt;br /&gt;This is a good article.  I have already deployed similar methods to combat #1 mentioned above for similar reasons, and will look into the other two.</summary><id>tag:addedbytes.com,2008:107700</id><published>2008-12-24T14:50:26+00:00</published><updated>2008-12-24T14:50:26Z</updated></entry><entry><title>Comment on Writing Secure PHP, Part 4</title><link rel="alternate" type="text/html" href="http://www.addedbytes.com/article/writing-secure-php-4/comments/" /><summary type="text">Comment by Gizmore ( &lt;a href="http://wechall.net"&gt;http://wechall.net&lt;/a&gt; )&lt;br /&gt;&lt;br /&gt;Very nice summary of secure php coding.&lt;br /&gt;
A good reading and kind_a must read for beginners.&lt;br /&gt;
&lt;br /&gt;
i follow this rule of thumb:&lt;br /&gt;
&lt;br /&gt;
- mysql_real_escape_string() or intval() before query any userdata into database.&lt;br /&gt;
&lt;br /&gt;
- htmlspecialchars() _every_ user input before output to browser&lt;br /&gt;
&lt;br /&gt;
- use one-time-tokens in forms to prevent csrf.&lt;br /&gt;
&lt;br /&gt;
Regards&lt;br /&gt;
Gizmore</summary><id>tag:addedbytes.com,2008:107653</id><published>2008-12-21T22:35:01+00:00</published><updated>2008-12-21T22:35:01Z</updated></entry><entry><title>Comment on Writing Secure PHP, Part 4</title><link rel="alternate" type="text/html" href="http://www.addedbytes.com/article/writing-secure-php-4/comments/" /><summary type="text">Comment by Ewan ( &lt;a href="http://www.ewan.org.uk"&gt;http://www.ewan.org.uk&lt;/a&gt; )&lt;br /&gt;&lt;br /&gt;Great set of articles written in plain English. Thanks for making it so easy to understand!</summary><id>tag:addedbytes.com,2008:106675</id><published>2008-11-20T13:54:44+00:00</published><updated>2008-11-20T13:54:44Z</updated></entry><entry><title>Comment on Writing Secure PHP, Part 4</title><link rel="alternate" type="text/html" href="http://www.addedbytes.com/article/writing-secure-php-4/comments/" /><summary type="text">Comment by suzanne ( &lt;a href="http://www.selectaskip.co.uk"&gt;http://www.selectaskip.co.uk&lt;/a&gt; )&lt;br /&gt;&lt;br /&gt;great article for anyone who is struggling with ASP</summary><id>tag:addedbytes.com,2008:106217</id><published>2008-11-05T14:31:22+00:00</published><updated>2008-11-05T14:31:22Z</updated></entry><entry><title>Comment on Writing Secure PHP, Part 4</title><link rel="alternate" type="text/html" href="http://www.addedbytes.com/article/writing-secure-php-4/comments/" /><summary type="text">Comment by Mike ( &lt;a href="http://kreativeearth.com"&gt;http://kreativeearth.com&lt;/a&gt; )&lt;br /&gt;&lt;br /&gt;I think this is an amazing article, for those ASP and PHP based wesbites which have loop holes for security. really informative.</summary><id>tag:addedbytes.com,2008:106074</id><published>2008-11-02T09:52:22+00:00</published><updated>2008-11-02T09:52:22Z</updated></entry><entry><title>Comment on Writing Secure PHP, Part 4</title><link rel="alternate" type="text/html" href="http://www.addedbytes.com/article/writing-secure-php-4/comments/" /><summary type="text">Comment by Security ( &lt;a href="http://www.experl.com"&gt;http://www.experl.com&lt;/a&gt; )&lt;br /&gt;&lt;br /&gt;This is a very beautiful website, I have enjoyed my visit here very much. I’m very honoured to sign in your guestbook. Thanking you for the great work that you are doing here.</summary><id>tag:addedbytes.com,2008:105939</id><published>2008-10-27T20:36:04+00:00</published><updated>2008-10-27T20:36:04Z</updated></entry><entry><title>Comment on Writing Secure PHP, Part 4</title><link rel="alternate" type="text/html" href="http://www.addedbytes.com/article/writing-secure-php-4/comments/" /><summary type="text">Comment by Jason Gaved ( &lt;a href="http://www.lexel.co.uk/"&gt;http://www.lexel.co.uk/&lt;/a&gt; )&lt;br /&gt;&lt;br /&gt;Great stuff Dave =) I wrote an similar article on security with ASP .. I read your &quot;Secure PHP&quot; and that gave me the idea, so thanks =P</summary><id>tag:addedbytes.com,2008:105920</id><published>2008-10-26T17:42:24+00:00</published><updated>2008-10-26T17:42:24Z</updated></entry><entry><title>Comment on Writing Secure PHP, Part 4</title><link rel="alternate" type="text/html" href="http://www.addedbytes.com/article/writing-secure-php-4/comments/" /><summary type="text">Comment by James Moss ( &lt;a href="http://www.jamesmoss.co.uk"&gt;http://www.jamesmoss.co.uk&lt;/a&gt; )&lt;br /&gt;&lt;br /&gt;A great (and simple) way to prevent session hijacking is to record the IP address of the user when they login in the session alongside the other data you want to store. &lt;br /&gt;
&lt;br /&gt;
Every time a user visits a page, compare their IP address to the one stored in the session.  If they dont match then destroy the session and let them know what's happened.&lt;br /&gt;
&lt;br /&gt;
This can prevent 99.9%(*) of session hijacks.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
(* 56.8% of all statistics are made up on the spot)</summary><id>tag:addedbytes.com,2008:105338</id><published>2008-10-12T12:28:00+01:00</published><updated>2008-10-12T12:28:00Z</updated></entry><entry><title>Comment on Writing Secure PHP, Part 4</title><link rel="alternate" type="text/html" href="http://www.addedbytes.com/article/writing-secure-php-4/comments/" /><summary type="text">Comment by O. Soteland ( &lt;a href=""&gt;&lt;/a&gt; )&lt;br /&gt;&lt;br /&gt;Wow. So many things I had to fix. Fortunately, I mostly just added a few lines of code to some files.&lt;br /&gt;
&lt;br /&gt;
And the idea of putting a blank index.html in all folders was nice.&lt;br /&gt;
&lt;br /&gt;
Thanks!</summary><id>tag:addedbytes.com,2008:105039</id><published>2008-09-29T22:12:11+01:00</published><updated>2008-09-29T22:12:11Z</updated></entry><entry><title>Comment on Writing Secure PHP, Part 4</title><link rel="alternate" type="text/html" href="http://www.addedbytes.com/article/writing-secure-php-4/comments/" /><summary type="text">Comment by Anonymous ( &lt;a href="http://www.highforce.com"&gt;http://www.highforce.com&lt;/a&gt; )&lt;br /&gt;&lt;br /&gt;Thank you for the insite into cross-site forgery, it is a pity we have to protect so much against people that are bored with there lives and want to disrupt others.&lt;br /&gt;
Thanks for your hard work keep it up..&lt;br /&gt;
All the best from Alan</summary><id>tag:addedbytes.com,2008:104764</id><published>2008-09-25T14:21:40+01:00</published><updated>2008-09-25T14:21:40Z</updated></entry></feed>