I am currently writing a URI parser whilst reading the official documentation and noticed that it should be legal to conceal another/multiple schemes within the URI syntax. I would like to be able to specify multiple schemes within a valid URI, like so:
vfs:zip///home/user/test.zip
vfs:zip:file///home/user/test.zip#data/text.log
vfs:zip:file//user:encrypted-password@localhost:127/home/user/test.zip#data/text.log
According to the Generic Syntax (RFC 3986), specifically sections 3 - 3.3 (not all text is listed here):
URI = scheme ":" hier-part [ "?" query ] [ "#" fragment ]
hier-part = "//" authority path-abempty
/ path-absolute
/ path-rootless
/ path-empty
This means that any characters between the first ':' and the first '/' (specifying either authority or path) should be skipped by parsers and still validate the URI, enabling me to provide zero or more schemes (zip, file, http, etc.) after the primary scheme (vfs, in this case), as far as I can tell.
Any thoughts as to whether or not this is correctly understood?
Otherwise, I think I have to provide the additional schemes via the path part or as a query or fragment, although I would prefer to provide them up-front, like the above, in order to preserve the rest of URI from preliminary preprocessing (other than normalization and percent-decoding).

Find content
Male