Re: [PATCH spice-common 3/3] docs: add spice URI scheme

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Jan 15, 2019 at 06:00:09PM +0400, Marc-André Lureau wrote:
> Hi
> 
> On Tue, Jan 15, 2019 at 4:53 PM Christophe Fergeau <cfergeau@xxxxxxxxxx> wrote:
> >
> > Hey,
> >
> > On Fri, Jan 11, 2019 at 11:07:14PM +0400, marcandre.lureau@xxxxxxxxxx wrote:
> > > @@ -0,0 +1,131 @@
> > > +The "spice" URI scheme
> > > +======================
> > > +
> > > +This document is inspired by 'The "vnc" URI Scheme' (rfc7869) and
> > > +attempts to document a standard Spice URI scheme.
> > > +
> > > +The normative syntax of the Spice URI is defined in the <spice-uri>
> > > +rule in the following syntax specification.  This specification
> > > +uses the Augmented Backus-Naur Form (ABNF) as described in
> > > +[RFC5234].  The Spice URI conforms to the generic URI syntax
> > > +specified in [RFC3986].  The <userinfo>, <host>, <port>,
> > > +<unreserved>, and <pct-encoded> rules are defined in [RFC3986].
> > > +
> > > + spice-uri = spice-scheme "://" [ userinfo "@" ] [ host [ ":" port ] ]
> > > +              [ "?" [ spice-params ] ]
> > > +
> > > + spice-scheme = "spice" / "spice+unix" / "spice+tls"
> > > +
> > > + spice-params = param "=" value *("&" param "=" value) ["&"]
> > > +
> > > + param = 1*( param-char )
> > > +
> > > + value = *( param-char )
> > > +
> > > + param-char = unreserved / pct-encoded / unreserved-symbols
> > > +
> > > + unreserved-symbols = ":" / "/" / "@" / "!" / "$" / "'"
> > > +                       / "(" / ")" / "*" / "," / ";"
> > > +
> > > +The "?", "=", and "&" characters are used to delimit Spice parameters
> > > +and must be percent-encoded when representing a data octet as
> > > +specified in [RFC3986].  Within the <spice-params> portion of a Spice
> > > +URI, the <unreserved-symbols> do not have special meaning and need not
> > > +be percent-encoded when representing a data octet.
> > > +
> > > +A Spice URI has the general form:
> > > +
> > > + spice-scheme://host:port?param1=value1&param2=value2...
> >
> > I'd mention 'userinfo' in that URI.
> 
> The point of this is to show a general form, not a form that has all
> the details.
> 
> Given that it is discouraged to use userinfo (unless it is done
> carefully), I don't think we need to mention it here.
> 
> However, there could be more details about it, a line such as:
> 
>  userinfo = <as specified in [RFC3986]>

Ok.
> 
> 
> >
> > > +The <host> value in the "spice+unix://" URI specify the UNIX domain
> > > +socket path of the Spice server on the local host:
> > > +
> > > +[options="header"]
> > > +|=======================================================================
> > > +| Name       | Type       | Description                     | Default
> > > +| host       | string     | UNIX domain socket path         | none
> > > +|=======================================================================
> >
> > RFC3986 has a definition for a 'path-absolute', but this is something which is
> > concatenated to the 'host'. A 'host' for RFC3986 cannot contain a '/':
> >
> >    host          = IP-literal / IPv4address / reg-name
> > with
> >    reg-name      = *( unreserved / pct-encoded / sub-delims )
> >    unreserved    = ALPHA / DIGIT / "-" / "." / "_" / "~"
> >    sub-delims    = "!" / "$" / "&" / "'" / "(" / ")"
> >                    / "*" / "+" / "," / ";" / "="
> >
> > I guess you could rework the current definition with something like:
> >
> > URI = URI-unix / URI-net
> > URI-net = spice-scheme-net://host:port?param1=value1&param2=value2...
> > URI-unix = spice+unix://path-absolute
> >
> > Or decide that for now, the current definition is good enough ;)
> 
> I agree it could be improved, but for a v1, I would rather have
> external contributions for this kind of refinements :)

Ok.

Christophe

Attachment: signature.asc
Description: PGP signature

_______________________________________________
Spice-devel mailing list
Spice-devel@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/spice-devel

[Index of Archives]     [Linux Virtualization]     [Linux Virtualization]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]     [Monitors]