<?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: Cross Site Scripting: what it is, and how to prevent it</title>
	<atom:link href="http://buildingbrowsergames.com/2008/04/28/cross-site-scripting-what-it-is-and-how-to-prevent-it/feed/" rel="self" type="application/rss+xml" />
	<link>http://buildingbrowsergames.com/2008/04/28/cross-site-scripting-what-it-is-and-how-to-prevent-it/</link>
	<description>Ever wanted to build a browsergame?</description>
	<lastBuildDate>Wed, 10 Mar 2010 20:26:23 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.5</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: me</title>
		<link>http://buildingbrowsergames.com/2008/04/28/cross-site-scripting-what-it-is-and-how-to-prevent-it/comment-page-1/#comment-684</link>
		<dc:creator>me</dc:creator>
		<pubDate>Thu, 07 Jan 2010 03:07:59 +0000</pubDate>
		<guid isPermaLink="false">http://buildingbrowsergames.com/?p=19#comment-684</guid>
		<description>I&#039;d say that if someone has accessed your database and hand entered the data you have bigger problems than XSS attacks. Escaping before inputting into the database means you only need to escape once which makes things more efficient. Also use htmlspecialchars not htmlentities it does the same job but uses less resources.</description>
		<content:encoded><![CDATA[<p>I&#39;d say that if someone has accessed your database and hand entered the data you have bigger problems than XSS attacks. Escaping before inputting into the database means you only need to escape once which makes things more efficient. Also use htmlspecialchars not htmlentities it does the same job but uses less resources.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: ABDUKRAHMAN</title>
		<link>http://buildingbrowsergames.com/2008/04/28/cross-site-scripting-what-it-is-and-how-to-prevent-it/comment-page-1/#comment-508</link>
		<dc:creator>ABDUKRAHMAN</dc:creator>
		<pubDate>Wed, 14 Oct 2009 08:01:33 +0000</pubDate>
		<guid isPermaLink="false">http://buildingbrowsergames.com/?p=19#comment-508</guid>
		<description>Woo this is a nice blog, i would love to read more.&lt;br&gt;&lt;br&gt;Thanks&lt;br&gt;oemal&lt;br&gt;______________________________________________&lt;br&gt;&lt;a href=&quot;http://www.videogame911.com&quot; target=&quot;_blank&quot; rel=&quot;nofollow&quot;&gt;xbox repair services&lt;/a&gt; &#124; &lt;a href=&quot;http://www.insuranceraters.com&quot; target=&quot;_blank&quot; rel=&quot;nofollow&quot;&gt;best auto insurance rates&lt;/a&gt; &#124; &lt;a href=&quot;http://www.coatesdolan.com/&quot; target=&quot;_blank&quot; rel=&quot;nofollow&quot;&gt;san miguel de allende real estate&lt;/a&gt;</description>
		<content:encoded><![CDATA[<p>Woo this is a nice blog, i would love to read more.</p>
<p>Thanks<br />oemal<br />______________________________________________<br /><a href="http://www.videogame911.com" target="_blank" rel="nofollow">xbox repair services</a> | <a href="http://www.insuranceraters.com" target="_blank" rel="nofollow">best auto insurance rates</a> | <a href="http://www.coatesdolan.com/" target="_blank" rel="nofollow">san miguel de allende real estate</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Luke</title>
		<link>http://buildingbrowsergames.com/2008/04/28/cross-site-scripting-what-it-is-and-how-to-prevent-it/comment-page-1/#comment-216</link>
		<dc:creator>Luke</dc:creator>
		<pubDate>Mon, 29 Dec 2008 17:56:31 +0000</pubDate>
		<guid isPermaLink="false">http://buildingbrowsergames.com/?p=19#comment-216</guid>
		<description>Roy,&lt;br&gt;You could definitely do both - how much you allow or disallow is entirely up&lt;br&gt;to you.</description>
		<content:encoded><![CDATA[<p>Roy,<br />You could definitely do both &#8211; how much you allow or disallow is entirely up<br />to you.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Roy</title>
		<link>http://buildingbrowsergames.com/2008/04/28/cross-site-scripting-what-it-is-and-how-to-prevent-it/comment-page-1/#comment-215</link>
		<dc:creator>Roy</dc:creator>
		<pubDate>Sun, 28 Dec 2008 14:46:45 +0000</pubDate>
		<guid isPermaLink="false">http://buildingbrowsergames.com/?p=19#comment-215</guid>
		<description>So why not simply do both? Make Account names viable if they are only Numbers and letters( ex A-Z, a-z, 0-9), no other char allowed, as well as escaping the repeating  information?</description>
		<content:encoded><![CDATA[<p>So why not simply do both? Make Account names viable if they are only Numbers and letters( ex A-Z, a-z, 0-9), no other char allowed, as well as escaping the repeating  information?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Luke</title>
		<link>http://buildingbrowsergames.com/2008/04/28/cross-site-scripting-what-it-is-and-how-to-prevent-it/comment-page-1/#comment-168</link>
		<dc:creator>Luke</dc:creator>
		<pubDate>Fri, 07 Nov 2008 00:36:43 +0000</pubDate>
		<guid isPermaLink="false">http://buildingbrowsergames.com/?p=19#comment-168</guid>
		<description>While it would make sense to escape the username before it enters the&lt;br&gt;database, escaping it afterwards helps protect you against XSS attacks that&lt;br&gt;originate *from* your database - for example, if an attacker gained access&lt;br&gt;to your database and hand-entered the data.&lt;br&gt;Rejecting usernames that have special characters in them isn&#039;t a bad idea,&lt;br&gt;but it tends to confuse the user - which characters are invalid? Which&lt;br&gt;aren&#039;t? It would be more useful if you could tell them which characters were&lt;br&gt;not allowed.</description>
		<content:encoded><![CDATA[<p>While it would make sense to escape the username before it enters the<br />database, escaping it afterwards helps protect you against XSS attacks that<br />originate *from* your database &#8211; for example, if an attacker gained access<br />to your database and hand-entered the data.<br />Rejecting usernames that have special characters in them isn&#39;t a bad idea,<br />but it tends to confuse the user &#8211; which characters are invalid? Which<br />aren&#39;t? It would be more useful if you could tell them which characters were<br />not allowed.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Abraxas</title>
		<link>http://buildingbrowsergames.com/2008/04/28/cross-site-scripting-what-it-is-and-how-to-prevent-it/comment-page-1/#comment-167</link>
		<dc:creator>Abraxas</dc:creator>
		<pubDate>Thu, 06 Nov 2008 04:39:04 +0000</pubDate>
		<guid isPermaLink="false">http://buildingbrowsergames.com/?p=19#comment-167</guid>
		<description>I agree that as a general rule this is excellent practice but for something like the user name wouldn&#039;t it make for sense to escape it before adding it to the database instead of every time it is displayed? In fact as part of my registration validation I compare the user name with the return from the escape function and if they&#039;re not equal I reject the name:&lt;br&gt;&lt;br&gt;if ($username != htmlspecialchars($username)) {&lt;br&gt;   $err = &quot;name contains invalid characters&quot;;&lt;br&gt;}</description>
		<content:encoded><![CDATA[<p>I agree that as a general rule this is excellent practice but for something like the user name wouldn&#39;t it make for sense to escape it before adding it to the database instead of every time it is displayed? In fact as part of my registration validation I compare the user name with the return from the escape function and if they&#39;re not equal I reject the name:</p>
<p>if ($username != htmlspecialchars($username)) {<br />   $err = &#8220;name contains invalid characters&#8221;;<br />}</p>
]]></content:encoded>
	</item>
</channel>
</rss>
