<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	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/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>No One Is Perfect &#187; Reminders</title>
	<atom:link href="http://watchitlater.com/blog/category/rem/feed/" rel="self" type="application/rss+xml" />
	<link>http://watchitlater.com/blog</link>
	<description>A reluctant foray into the world of blogging.</description>
	<lastBuildDate>Tue, 08 Nov 2011 12:32:55 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>How to use rsync on OSX</title>
		<link>http://watchitlater.com/blog/2011/11/how-to-use-rsync-on-osx/</link>
		<comments>http://watchitlater.com/blog/2011/11/how-to-use-rsync-on-osx/#comments</comments>
		<pubDate>Tue, 08 Nov 2011 12:27:51 +0000</pubDate>
		<dc:creator>Tom</dc:creator>
				<category><![CDATA[Reminders]]></category>
		<category><![CDATA[dot]]></category>
		<category><![CDATA[Mac]]></category>
		<category><![CDATA[osx]]></category>
		<category><![CDATA[rsync]]></category>

		<guid isPermaLink="false">http://watchitlater.com/blog/?p=391</guid>
		<description><![CDATA[I don&#8217;t really want to copy dot files (eg. .DS_Store), and I want to avoid the bug that rsync exhibits with time-capsule where it loops creating multiple ..DS_Store.xxxx files. rsync -vrW --ignore-existing --exclude ".*" --progress ~/Movies/ /Volumes/Backup/Movies/]]></description>
			<content:encoded><![CDATA[<p>I don&#8217;t really want to copy dot files (eg. .DS_Store), and I want to avoid the bug that rsync exhibits with time-capsule where it loops creating multiple ..DS_Store.xxxx files.</p>
<p><code>rsync -vrW --ignore-existing --exclude ".*" --progress ~/Movies/ /Volumes/Backup/Movies/</code></p>
]]></content:encoded>
			<wfw:commentRss>http://watchitlater.com/blog/2011/11/how-to-use-rsync-on-osx/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to delete all zero length files in a directory tree</title>
		<link>http://watchitlater.com/blog/2011/11/how-to-delete-all-zero-length-files-in-a-directory-tree/</link>
		<comments>http://watchitlater.com/blog/2011/11/how-to-delete-all-zero-length-files-in-a-directory-tree/#comments</comments>
		<pubDate>Tue, 08 Nov 2011 12:22:25 +0000</pubDate>
		<dc:creator>Tom</dc:creator>
				<category><![CDATA[Reminders]]></category>
		<category><![CDATA[delete]]></category>
		<category><![CDATA[files]]></category>
		<category><![CDATA[find]]></category>
		<category><![CDATA[length]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[zero]]></category>

		<guid isPermaLink="false">http://watchitlater.com/blog/?p=389</guid>
		<description><![CDATA[find . -type f -size 0 -print0 &#124; xargs -0 rm -f]]></description>
			<content:encoded><![CDATA[<p><code>find . -type f -size 0 -print0 | xargs -0 rm -f</code></p>
]]></content:encoded>
			<wfw:commentRss>http://watchitlater.com/blog/2011/11/how-to-delete-all-zero-length-files-in-a-directory-tree/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Cross-Site Scripting vulnerability with JavaScript and JQuery</title>
		<link>http://watchitlater.com/blog/2011/10/cross-site-scripting-vulnerability-with-javascript-and-jquery/</link>
		<comments>http://watchitlater.com/blog/2011/10/cross-site-scripting-vulnerability-with-javascript-and-jquery/#comments</comments>
		<pubDate>Mon, 17 Oct 2011 09:30:13 +0000</pubDate>
		<dc:creator>Tom</dc:creator>
				<category><![CDATA[Reminders]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[jquery]]></category>
		<category><![CDATA[xss]]></category>

		<guid isPermaLink="false">http://watchitlater.com/blog/?p=371</guid>
		<description><![CDATA[Think you&#8217;ve protected your site against Cross-Site scripting attacks by escaping all the content that you&#8217;ve rendered? Thought about your javascript? Here&#8217;s a neat bug that got us today. This example is contrived to show a point. &#60;!DOCTYPE html&#62; &#60;html&#62; &#60;head&#62; &#60;meta charset=&#34;utf-8&#34;&#62; &#60;title&#62;XSS Example&#60;/title&#62; &#60;script src=&#34;http://ajax.googleapis.com/ajax/libs/jquery/1.6.4/jquery.min.js&#34;&#62;&#60;/script&#62; &#60;script&#62; $(function() { $(&#x27;#users&#x27;).each(function() { var select = [...]]]></description>
			<content:encoded><![CDATA[<p>Think you&#8217;ve protected your site against <a href="http://en.wikipedia.org/wiki/Cross-site_scripting">Cross-Site scripting</a> attacks by escaping all the content that you&#8217;ve rendered? Thought about your javascript?</p>
<p>Here&#8217;s a neat bug that got us today. This example is contrived to show a point.</p>
<pre name="code" class="html:nogutter">
&lt;!DOCTYPE html&gt;
&lt;html&gt;
&lt;head&gt;
  &lt;meta charset=&quot;utf-8&quot;&gt;
  &lt;title&gt;XSS Example&lt;/title&gt;
  &lt;script src=&quot;http://ajax.googleapis.com/ajax/libs/jquery/1.6.4/jquery.min.js&quot;&gt;&lt;/script&gt;
  &lt;script&gt;
    $(function() {
      $(&#x27;#users&#x27;).each(function() {
        var select = $(this);
        var option = select.children(&#x27;option&#x27;).first();
        select.after(option.text());
        select.hide();
      });
    });
  &lt;/script&gt;
&lt;/head&gt;
&lt;body&gt;
  &lt;form method=&quot;post&quot;&gt;
    &lt;p&gt;
      &lt;select id=&quot;users&quot; name=&quot;users&quot;&gt;
        &lt;option value=&quot;bad&quot;&gt;&amp;lt;script&amp;gt;alert(&amp;#x27;xss&amp;#x27;);&amp;lt;/script&amp;gt;&lt;/option&gt;
      &lt;/select&gt;
    &lt;/p&gt;
  &lt;/form&gt;
&lt;/body&gt;
&lt;/html&gt;
</pre>
<p>See the problem? Don&#8217;t worry, neither did the pair that worked on the javascript. But our QA showed us a neat little alert box!</p>
<p>It looks like the JQuery text() method returns the unescaped payload of the option, and the after() method then creates a nice little script tag. Nasty stuff.</p>
<p>How did we deal with the problem? This was our immediate fix:</p>
<pre name="code" class="javascript:nogutter">
  // after() accepts a DOM element so lets create a text node
  select.after(document.createTextNode(option.text()));
</pre>
<p>Longer term fix &#8211; still open to suggestions.</p>
]]></content:encoded>
			<wfw:commentRss>http://watchitlater.com/blog/2011/10/cross-site-scripting-vulnerability-with-javascript-and-jquery/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>

