[Spice-devel] [spice-gtk 2/5] session: Lookup URI query part before path part
David Jaša
djasa at redhat.com
Wed Jun 5 05:48:54 PDT 2013
Just for the record: path is part of hierarchical part of the uri that
begins with double slash "//". Query part of the URI starts with
question mark "?" and it is followed by Fragment part that starts with
hash "#". So this is perfectly legal URI:
spice://fqdn?param=value
that contain just scheme ("spice"), hostname ("fqdn") and query
("param=value") sections.
BTW the password could be conveyed via uri in the more
standards-following way:
spice://:password@fqdn[port][path][query][fragment]
IIRC there used to be a generic parser for URIs in glib that was removed
at some point of time, didn't you think about making this code more
generic so that each and every URI-parsing glib app doesn't have to go
through these hoops over and over again?
David
Christophe Fergeau píše v St 05. 06. 2013 v 14:21 +0200:
> On Wed, Jun 05, 2013 at 01:07:16PM +0300, Uri Lublin wrote:
> > In your example, query is "my_param=/some/path" and path points
> > to "/some/path" within query. Some may find it confusing, and it does not
> > follow URI syntax where path comes before query (IIUC).
>
> This is not meant to move the 'path' part of the URI in the params, but to
> allow the params to contain '/' without confusing SPICE URI parser.
> You can change the example to
> scheme://foo.example.com?mimetype=text/plain
> if that makes things less confusing.
>
> Christophe
> _______________________________________________
> Spice-devel mailing list
> Spice-devel at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/spice-devel
--
David Jaša, RHCE
SPICE QE based in Brno
GPG Key: 22C33E24
Fingerprint: 513A 060B D1B4 2A72 7F0D 0278 B125 CD00 22C3 3E24
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/x-pkcs7-signature
Size: 5727 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/spice-devel/attachments/20130605/932a709b/attachment-0001.bin>
More information about the Spice-devel
mailing list