<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://msinfluentials.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Hey, Mozilla: Quotes Are Not Legal in a URL</title><link>http://msinfluentials.com/blogs/jesper/archive/2007/07/20/hey-mozilla-quotes-are-not-legal-in-a-url.aspx</link><description>When I was a child, I learned a saying that I still find important to keep in mind: Those who are sitting in a glass house shall not throw stones The good folks at Mozilla may want to look up what that really means. Two days ago, Mozilla published Firefox</description><dc:language>en</dc:language><generator>CommunityServer 2008.5 SP2 (Build: 40407.4157)</generator><item><title>re: Hey, Mozilla: Quotes Are Not Legal in a URL</title><link>http://msinfluentials.com/blogs/jesper/archive/2007/07/20/hey-mozilla-quotes-are-not-legal-in-a-url.aspx#9801</link><pubDate>Sat, 01 Nov 2008 20:18:55 GMT</pubDate><guid isPermaLink="false">91db4bc3-5a69-4a9f-94bf-eedb569902ab:9801</guid><dc:creator>ortankal</dc:creator><description>&lt;p&gt;I would like to see some cooperation between the different software companies, to think about solutions that benefits for everybody.&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msinfluentials.com/aggbug.aspx?PostID=9801" width="1" height="1"&gt;</description></item><item><title>re: Hey, Mozilla: Quotes Are Not Legal in a URL</title><link>http://msinfluentials.com/blogs/jesper/archive/2007/07/20/hey-mozilla-quotes-are-not-legal-in-a-url.aspx#6756</link><pubDate>Wed, 01 Aug 2007 13:34:20 GMT</pubDate><guid isPermaLink="false">91db4bc3-5a69-4a9f-94bf-eedb569902ab:6756</guid><dc:creator>Reverend JAxON</dc:creator><description>&lt;p&gt;you can pick exploder which is just about as exciting as the Taco Bell menu. Or - pick Firefx which is the mexican putting your Nachos Bell Grande together. At least homeboy can mix it up!&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msinfluentials.com/aggbug.aspx?PostID=6756" width="1" height="1"&gt;</description></item><item><title>re: Hey, Mozilla: Quotes Are Not Legal in a URL</title><link>http://msinfluentials.com/blogs/jesper/archive/2007/07/20/hey-mozilla-quotes-are-not-legal-in-a-url.aspx#6741</link><pubDate>Tue, 31 Jul 2007 03:06:22 GMT</pubDate><guid isPermaLink="false">91db4bc3-5a69-4a9f-94bf-eedb569902ab:6741</guid><dc:creator>Pentiux</dc:creator><description>&lt;p&gt;Outsmating each other.&lt;/p&gt;
&lt;p&gt;Both have flaws, I think.&lt;/p&gt;
&lt;p&gt;Let&amp;#39;s see who fixes thier flaws first.&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msinfluentials.com/aggbug.aspx?PostID=6741" width="1" height="1"&gt;</description></item><item><title>re: Hey, Mozilla: Quotes Are Not Legal in a URL</title><link>http://msinfluentials.com/blogs/jesper/archive/2007/07/20/hey-mozilla-quotes-are-not-legal-in-a-url.aspx#6733</link><pubDate>Mon, 30 Jul 2007 06:55:34 GMT</pubDate><guid isPermaLink="false">91db4bc3-5a69-4a9f-94bf-eedb569902ab:6733</guid><dc:creator>Toma Bussarov</dc:creator><description>&lt;p&gt;Did anybody read the picture from Firefox?&lt;/p&gt;
&lt;p&gt;Just below the scary url that is presented to the user is written:&lt;/p&gt;
&lt;p&gt;...it may be an attempt to exloit a weekness in that other program ...&lt;/p&gt;
&lt;p&gt;In the case of IE &amp;quot;that other program&amp;quot; is Firefox. No more searching whose fault it is. Mozilla confesses.&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msinfluentials.com/aggbug.aspx?PostID=6733" width="1" height="1"&gt;</description></item><item><title>re: Hey, Mozilla: Quotes Are Not Legal in a URL</title><link>http://msinfluentials.com/blogs/jesper/archive/2007/07/20/hey-mozilla-quotes-are-not-legal-in-a-url.aspx#6714</link><pubDate>Fri, 27 Jul 2007 17:11:31 GMT</pubDate><guid isPermaLink="false">91db4bc3-5a69-4a9f-94bf-eedb569902ab:6714</guid><dc:creator>Sean</dc:creator><description>&lt;p&gt;My feeling on the whole thing? A pox on both their houses for not looking out for the security interests of the end user. Both Microsoft and Mozilla failed in an extremely important concept, ALL INPUT FROM REMOTE SOURCES MUST BE SANITIZED BEFORE IT IS ACCEPTED FOR INPUT! Microsoft is vile for passing on unsantized data, and Firefox is vile for not sanitizing its input.&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msinfluentials.com/aggbug.aspx?PostID=6714" width="1" height="1"&gt;</description></item><item><title>re: Hey, Mozilla: Quotes Are Not Legal in a URL</title><link>http://msinfluentials.com/blogs/jesper/archive/2007/07/20/hey-mozilla-quotes-are-not-legal-in-a-url.aspx#6707</link><pubDate>Fri, 27 Jul 2007 09:24:50 GMT</pubDate><guid isPermaLink="false">91db4bc3-5a69-4a9f-94bf-eedb569902ab:6707</guid><dc:creator>dabur</dc:creator><description>&lt;p&gt;I&amp;#39;m responsible for security in my company. For me it doesn&amp;#39;t matter if it&amp;#39;s FF or IE or AOL or &amp;quot;WTF&amp;quot; with a vulnerability.... The only thing that matters is having a fix so I can start the system engineers doing the dsitribution of it on all our client and server systems.&lt;/p&gt;
&lt;p&gt;I would like to see some cooperation between the different software companies, to think about solutions that benefits for everybody.&lt;/p&gt;
&lt;p&gt;Maybe looking in RFC3986 again and optimize it?&lt;/p&gt;
&lt;p&gt;Fact: Nobody is perfect. All software have vumnerabilities. It&amp;#39;s a matter of when they are discovered.&lt;/p&gt;
&lt;p&gt;Greetings.&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msinfluentials.com/aggbug.aspx?PostID=6707" width="1" height="1"&gt;</description></item><item><title>re: Hey, Mozilla: Quotes Are Not Legal in a URL</title><link>http://msinfluentials.com/blogs/jesper/archive/2007/07/20/hey-mozilla-quotes-are-not-legal-in-a-url.aspx#6703</link><pubDate>Fri, 27 Jul 2007 05:24:52 GMT</pubDate><guid isPermaLink="false">91db4bc3-5a69-4a9f-94bf-eedb569902ab:6703</guid><dc:creator>paperino</dc:creator><description>&lt;p&gt;@Muffin&lt;/p&gt;
&lt;p&gt;I&amp;#39;ve never seen MS blame Turing for their bugs as Window Snyder just did.&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msinfluentials.com/aggbug.aspx?PostID=6703" width="1" height="1"&gt;</description></item><item><title>re: Hey, Mozilla: Quotes Are Not Legal in a URL</title><link>http://msinfluentials.com/blogs/jesper/archive/2007/07/20/hey-mozilla-quotes-are-not-legal-in-a-url.aspx#6700</link><pubDate>Fri, 27 Jul 2007 03:50:37 GMT</pubDate><guid isPermaLink="false">91db4bc3-5a69-4a9f-94bf-eedb569902ab:6700</guid><dc:creator>aaaaa0</dc:creator><description>&lt;p&gt;punissuer:&lt;/p&gt;
&lt;p&gt;In which case, firefox should define a new command line switch and register its protocol handler like this:&lt;/p&gt;
&lt;p&gt;firefox -untrustedurl &amp;quot;%1&amp;quot;&lt;/p&gt;
&lt;p&gt;Then regular users using -url would be free to combine it with other switches, while the URL protocol handler would only use the safe switch (which would do all of what Jesper suggests.&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msinfluentials.com/aggbug.aspx?PostID=6700" width="1" height="1"&gt;</description></item><item><title>re: Hey, Mozilla: Quotes Are Not Legal in a URL</title><link>http://msinfluentials.com/blogs/jesper/archive/2007/07/20/hey-mozilla-quotes-are-not-legal-in-a-url.aspx#6694</link><pubDate>Thu, 26 Jul 2007 20:58:59 GMT</pubDate><guid isPermaLink="false">91db4bc3-5a69-4a9f-94bf-eedb569902ab:6694</guid><dc:creator>punissuer</dc:creator><description>&lt;p&gt;How is the protocol handler more able than &amp;lt;i&amp;gt;whatever&amp;lt;/i&amp;gt; populated argv and argc even to determine where a maliciously malformed URL begins and ends if the calling app has not relayed this information with quotes, and escaped quotes in the malformed URL? &amp;nbsp;Skimming your blog, I found this statement which seems relevant:&lt;/p&gt;
&lt;p&gt;&amp;lt;blockquote&amp;gt;It&amp;#39;s vital for the protocol handler to see the &amp;quot;-url&amp;quot; argument as indication that everything following it is suspect. The first double-quote should not be taken as a sign that &amp;quot;%1&amp;quot; is over - the last double-quote before the end of the command line is that indicator.&amp;lt;/blockquote&amp;gt;&lt;/p&gt;
&lt;p&gt;I would agree with this statement completely if the -url argument were used only by programs calling Firefox as a protocol handler, so the command could have only the form &amp;#39;firefox -url &amp;quot;%1&amp;quot;&amp;#39;. &amp;nbsp;But users can type the -url arg into CMD.EXE by hand, and follow it with other args, so the assumption that it must be the last double quote that ends the URL is not valid.&lt;/p&gt;
&lt;p&gt;Also, the calling browser could use the &amp;quot;known good&amp;quot; principle you mention on your blog while escaping the URL. &amp;nbsp;Only characters which are not valid in URLs (like whitespace and double quotes) would be escaped, so a well formed URL would be unchanged. &amp;nbsp;Who cares if a maliciously malformed URL gets mangled? &amp;nbsp;The protocol handler should throw some kind of exception upon such input, anyway.&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msinfluentials.com/aggbug.aspx?PostID=6694" width="1" height="1"&gt;</description></item><item><title>re: Hey, Mozilla: Quotes Are Not Legal in a URL</title><link>http://msinfluentials.com/blogs/jesper/archive/2007/07/20/hey-mozilla-quotes-are-not-legal-in-a-url.aspx#6693</link><pubDate>Thu, 26 Jul 2007 19:48:50 GMT</pubDate><guid isPermaLink="false">91db4bc3-5a69-4a9f-94bf-eedb569902ab:6693</guid><dc:creator>Alun Jones</dc:creator><description>&lt;p&gt;You&amp;#39;re right - details of how to parse the protocol are only available to code that knows something about the protocol, and clearly the protocol handler would have no more knowledge about the protocol than the C Run-time library (it&amp;#39;s not the command line interpreter, which people typically use to mean CMD.EXE)&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msinfluentials.com/aggbug.aspx?PostID=6693" width="1" height="1"&gt;</description></item><item><title>re: Hey, Mozilla: Quotes Are Not Legal in a URL</title><link>http://msinfluentials.com/blogs/jesper/archive/2007/07/20/hey-mozilla-quotes-are-not-legal-in-a-url.aspx#6692</link><pubDate>Thu, 26 Jul 2007 19:21:46 GMT</pubDate><guid isPermaLink="false">91db4bc3-5a69-4a9f-94bf-eedb569902ab:6692</guid><dc:creator>punissuer</dc:creator><description>&lt;p&gt;Alun, I disagree with your characterization of the situation. &amp;nbsp;The first browser (whether IE or Firefox) is indeed acting as a browser. &amp;nbsp;It downloads, parses, and renders an HTML page. &amp;nbsp;It identifies anchor tags and href attributes, whose values should be URLs. &amp;nbsp;It&amp;#39;s irrelevant whether the protocol handler is even aware of the network (file URLs, anyone?) since the problem occurs while it&amp;#39;s validating its command-line input. &amp;nbsp;As for validating the command line as a single string, how is the protocol handler in any better position than the command-line interpreter that populated argv and argc? &amp;nbsp;Information about the original intent is lost when the calling browser fails to quote or escape the arguments.&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msinfluentials.com/aggbug.aspx?PostID=6692" width="1" height="1"&gt;</description></item><item><title>re: Hey, Mozilla: Quotes Are Not Legal in a URL</title><link>http://msinfluentials.com/blogs/jesper/archive/2007/07/20/hey-mozilla-quotes-are-not-legal-in-a-url.aspx#6691</link><pubDate>Thu, 26 Jul 2007 18:07:04 GMT</pubDate><guid isPermaLink="false">91db4bc3-5a69-4a9f-94bf-eedb569902ab:6691</guid><dc:creator>multi_io</dc:creator><description>&lt;p&gt;@Aaron Margosis&lt;/p&gt;
&lt;p&gt;Yes it is issuing the command if you click on a link named something like &amp;lt;a href=&amp;#39;firefoxurl://foo.com&amp;quot;%20-chrome%20&amp;quot;BLOCKED SCRIPTsomething()&amp;quot;&amp;#39;&amp;gt;, &amp;nbsp;which is the whole point of the discussion!&lt;/p&gt;
&lt;p&gt;(let&amp;#39;s see how much of that text is left intact by the broken blog software on this server -- btw: is it any indication for MS&amp;#39;s state of confusion when it comes to quoting issues that the server software here replaces every occurrence of &amp;quot;j a v a s c r i p t:something()&amp;quot; with &amp;quot;BLOCKED SCRIPT:something()&amp;quot;? :-P)&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msinfluentials.com/aggbug.aspx?PostID=6691" width="1" height="1"&gt;</description></item><item><title>re: Hey, Mozilla: Quotes Are Not Legal in a URL</title><link>http://msinfluentials.com/blogs/jesper/archive/2007/07/20/hey-mozilla-quotes-are-not-legal-in-a-url.aspx#6690</link><pubDate>Thu, 26 Jul 2007 15:47:38 GMT</pubDate><guid isPermaLink="false">91db4bc3-5a69-4a9f-94bf-eedb569902ab:6690</guid><dc:creator>Alun Jones</dc:creator><description>&lt;p&gt;@punissuer: If it&amp;#39;s too difficult for you to spot malicious input using argc and argv, then you should stop using argc and argv. As Aaron pointed out, at any stage you can call GetCommandLine to get the command line as a single string and do your own parsing; you can also write your code as a Win32 app, rather than a console-mode app, and it will receive a single string containing the entire command line.&lt;/p&gt;
&lt;p&gt;In this case, Internet Explorer is acting as a proxy, not a browser, and should behave that way; the protocol handler is acting as an Internet-facing client, and should behave that way. Asking that the proxy encode or decode stuff for you is not appropriate, because you will lose information about what the original intent was.&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msinfluentials.com/aggbug.aspx?PostID=6690" width="1" height="1"&gt;</description></item><item><title>re: Hey, Mozilla: Quotes Are Not Legal in a URL</title><link>http://msinfluentials.com/blogs/jesper/archive/2007/07/20/hey-mozilla-quotes-are-not-legal-in-a-url.aspx#6689</link><pubDate>Thu, 26 Jul 2007 09:49:04 GMT</pubDate><guid isPermaLink="false">91db4bc3-5a69-4a9f-94bf-eedb569902ab:6689</guid><dc:creator>Ivan Magrini</dc:creator><description>&lt;p&gt;To linuxuser: shame on you! I&amp;#39;m actually sick of this &amp;quot;MS is bad&amp;quot; &amp;quot;Linux/OSS is good&amp;quot; ... this is a technical discussion and Jesper&amp;#39;s arguments are totaly OK.&lt;/p&gt;
&lt;p&gt;As a software developer (no, I do not use MS development tools) I know, that you can never trust input passed to your app ... and therefore you should allways validate what your app is getting from the outside .... otherwise you are just a fool.&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msinfluentials.com/aggbug.aspx?PostID=6689" width="1" height="1"&gt;</description></item><item><title>re: Hey, Mozilla: Quotes Are Not Legal in a URL</title><link>http://msinfluentials.com/blogs/jesper/archive/2007/07/20/hey-mozilla-quotes-are-not-legal-in-a-url.aspx#6686</link><pubDate>Thu, 26 Jul 2007 07:00:19 GMT</pubDate><guid isPermaLink="false">91db4bc3-5a69-4a9f-94bf-eedb569902ab:6686</guid><dc:creator>punissuer</dc:creator><description>&lt;p&gt;As an argument for why web browsers should not perform any validation on arguments they pass to apps they call, I find David LeBlanc&amp;#39;s insights far from convincing. &amp;nbsp;If my &amp;quot;CriticalBusinessApp [needed] quotes coming in&amp;quot; when it was being called as an URL handler, I&amp;#39;d ask my programmers what they were smoking. &amp;nbsp;Also, detecting malicious input is more difficult after it&amp;#39;s been split into multiple arguments by the command line interpreter. &amp;nbsp;For example, validating an arg that&amp;#39;s supposed to be an URL will not detect that the following -chrome arg was supposed to be part of that URL.&lt;/p&gt;
&lt;p&gt;If we were talking about general applications, I might agree more with LeBlanc, but we&amp;#39;re talking about web browsers. &amp;nbsp;There are rules that all web browsers are supposed to follow (like the spec for what is an URL), and so a browser has more context to determine what would obviously be invalid input for an external app. &amp;nbsp;If what incoming HTML said was an URL does not look like an URL, then it would obviously be poison for any program that expected an URL, so it should be escaped, and quoted to prevent splitting or other misinterpretation by the command line interpreter.&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://msinfluentials.com/aggbug.aspx?PostID=6686" width="1" height="1"&gt;</description></item></channel></rss>