[webkit-qt] Adding a "view source" API for WebView [feedback needed!]

Jocelyn Turcotte jocelyn.turcotte at nokia.com
Thu May 10 05:59:39 PDT 2012


On Thu, 10 May 2012 09:43:23 -0300
ext Jesus Sanchez-Palencia <jesus at webkit.org> wrote:

> Hi there!
> 
> On Thu, May 10, 2012 at 9:32 AM, Jocelyn Turcotte <
> jocelyn.turcotte at nokia.com> wrote:
> 
> >
> > I don't think we need to sanitize view-source URLs, they will be generated
> > from the current URL most of the time and if the user really want to enter
> > it manually then he just has to do it properly. Independently if we do it
> > in the web or UI process.
> >
> 
> So you don't think we should support "view-source:www.foo.com", right?
> (Note the absence of a second - http - scheme). Not sanitizing them will
> make us only support well-formed URLs (view-source:http://www.foo.com).

Humm looks like Chrome supports this pretty well, so I'm not against it either.
In any case I think that it's possible to do the sanitization in Utils::urlFromUserInput like you did, whether or not the flag is passed as the view-source URL scheme or as a separate message.


More information about the webkit-qt mailing list