URI scheme
From Wikipedia, the free encyclopedia
In the field of computer networking, a URI scheme is the top level of the Uniform Resource Identifier (URI) naming structure. All URIs and absolute URI references are formed with a scheme name, followed by a colon character (":"), and the remainder of the URI called (in the outdated RFCs 1738 and 2396, but not the current STD 66/RFC 3986) the scheme-specific part. The syntax and semantics of the scheme-specific part are left largely to the specifications governing individual schemes, subject to certain constraints such as reserved characters and how to "escape" them.
URI schemes are sometimes erroneously referred to as "protocols", or specifically as URI protocols or URL protocols, since most were originally designed to be used with a particular protocol, and often have the same name. The http
scheme, for instance, is generally used for interacting with Web resources using HyperText Transfer Protocol. Today, URIs with that scheme are also used for other purposes, such as RDF resource identifiers and XML namespaces, that are not related to the protocol. Furthermore, some URI schemes are not associated with any specific protocol (e.g. "file
") and many others do not use the name of a protocol as their prefix (e.g. "news
").
URI schemes should be registered with IANA, although non-registered schemes are used in practice. RFC 4395 describes the procedures for registering new URI schemes.
Contents |
[edit] Generic syntax
Internet standard STD 66 (also RFC 3986) defines the generic syntax to be used in all URI schemes. Every URI is defined as consisting of four parts, as follows:
<scheme name> : <hierarchical part> [ ? <query> ] [ # <fragment> ]
The scheme name consist of a letter followed by any combination of letters, digits, and the plus ("+"), period ("."), or hyphen ("-") characters; and is terminated by a colon (":").
The hierarchical part of the URI is intended to hold identification information hierarchical in nature. Usually this part begins with a double forward slash ("//"), followed by an authority part and an optional path. The authority part holds an optional user information part terminated with "@" (e.g. username:password@
), a hostname (i.e. domain name or IP address), and an optional port number preceded by a colon ":". The path part is a sequence of segments (conceptually similar to directories, though not necessarily representing them) separated by a forward slash ("/"). Each segment can contain parameters separated from it using a semicolon (";"), though this is rarely used in practice.
The query is an optional part separated with a question mark, which contains additional identification information which is not hierarchical in nature. The query string syntax is not generically defined, but is commonly organized as a sequence of <key>=<value>
pairs separated by an ampersand, e. g. key1=value1&key2=value2&key3=value3
.
The fragment is an optional part separated from the front parts by a hash ("#"). It holds additional identifying information that provides direction to a secondary resource, e.g. a section heading in an article identified by the remainder of the URI. When the primary resource is an HTML document, the fragment is often a named anchor tag.
[edit] Examples
The following are two example URIs and their component parts (taken loosely from RFC 3986 — STD 66):
foo://username:password@example.com:8042/over/there/index.dtb;type=animal?name=ferret#nose \ / \________________/\_________/ \__/\_________/ \___/ \_/ \_________/ \_________/ \__/ | | | | | | | | | | scheme userinfo hostname port path filename extension parameter(s) query fragment | \_______________________________/ | authority | ________________________ / \ / \ urn:example:animal:ferret:nose
[edit] Official IANA-registered schemes
The official URI schemes registered with the IANA follow.
Scheme | Purpose | Defined by | General format | Notes |
---|---|---|---|---|
aaa | Diameter Protocol | RFC 3588 | aaa://<host>[:<port>][;transport=<transport>][;protocol=<protocol>]
example: |
|
aaas | Secure equivalent of aaa | RFC 3588 | aaas://<host>[:<port>][;transport=<transport>][;protocol=<protocol>] |
|
acap | Application Configuration Access Protocol | RFC 2244 | acap://[<user>[;AUTH=<type>]@]<host>[:<port>]/<entry> |
URL scheme used within the ACAP protocol for the "subdataset" attribute, referrals and inheritance |
cap | Calendar access protocol | RFC 4324 | generic syntax | URL scheme used to designate both calendar stores and calendars accessible using the CAP protocol |
cid | Referencing individual parts of an SMTP/MIME message | RFC 2392 | cid:<content-id> |
e.g. referencing an attached image within a formatted e-mail. (See also mid:) |
crid | TV-Anytime Content Reference Identifier | RFC 4078 | crid://<host>/<data> |
Allow references to scheduled publications of broadcast media content. |
data | Inclusion of small data items inline | RFC 2397 | data:<mediatype>[;base64],<data> |
|
dav | HTTP Extensions for Distributed Authoring (WebDAV) | RFC 2518 | dav: |
Used for internal identifiers only; WebDAV itself addresses resources using the http: and https: schemes. [1] |
dict | Dictionary service protocol | RFC 2229 | dict://<user>;<auth>@<host>:<port>/d:<word>:<database>:<n>
|
refer to definitions or word lists available using the DICT protocol |
dns | Domain Name System | RFC 4501 | dns:[//<host>[:<port>]/]<dnsname>[?<dnsquery>]
examples: |
designates a DNS resource record set, referenced by domain name, class, type, and, optionally, the authority |
fax | Used for telefacsimile numbers | RFC 2806 | fax:<phonenumber> |
Seems to be deprecated in RFC 3966 in favour of tel: |
file | Addressing files on local or network file systems | RFC 1738 | generic syntax (often appears as file:///path , the 3rd '/' is the final delimiter when no host (authority) is specified between) |
Unusual in not being bound to any network protocol, and not usable in an Internet context. |
ftp | FTP resources | RFC 1738 | generic syntax | |
go | Common Name Resolution Protocol | RFC 3368 | go://[<host>]?[<common-name>]*[;<attribute>=[<type>,]<value>] orgo:<common-name>*[;<attribute>=[<type>,]<value>] |
|
gopher | Used with Gopher protocol | RFC 4266 | gopher://<host>:<port>/<item type>/<path> |
|
h323 | Used with H.323 multimedia communications | RFC 3508 | h323:[<user>@]<host>[:<port>][;<parameters>] |
|
http | HTTP resources | RFC 2616 | generic syntax | |
https | HTTP connections secured using SSL/TLS | RFC 2817 | generic syntax | |
icap | Internet Content Adaptation Protocol | RFC 3507 | ||
im | Instant messaging protocol | RFC 3860 RFC 4622 | im:<username>[@<host>] |
Works as xmpp: URI for single user chat sessions. |
imap | Accessing e-mail resources through IMAP | RFC 2192 | imap://[<user>[;AUTH=<type>]@]<host>[:<port>]/<command> |
|
info | Information Assets with Identifiers in Public Namespaces | RFC 4452 | ||
ipp | Internet Printing Protocol | RFC 3510 | ||
iris iris.beep iris.xpc iris.xpcs iris.lws |
Internet Registry Information Service | RFC 3981 RFC 3983 RFC 4992 RFC 4992 RFC 4993 | ||
ldap | LDAP directory request | RFC 2255 RFC 4516 |
ldap://[<host>[:<port>]][/<dn> [?[<attributes>][?[<scope>][?[<filter>][?<extensions>]]]]]
example: |
|
mailto | SMTP e-mail addresses and default content | RFC 2368 | mailto:<address>[?<header1>=<value1>[&<header2>=<value2>]]
example: |
Headers are optional, but often include subject= ; body= can be used to pre-fill the body of the message. |
mid | Referencing SMTP/MIME messages, or parts of messages. | RFC 2392 | mid:<message-id>[/<content-id>] |
(See also cid:) |
modem | modem | RFC 3966 | ||
msrp msrps |
Message Session Relay Protocol | RFC 4975 | ||
mtqp | Message Tracking Query Protocol | RFC 3887 | ||
mupdate | Mailbox Update Protocol | RFC 3656 | ||
news | (Usenet) newsgroups and postings | RFC 1738 | news:<newsgroupname> ornews:<message-id> |
References a particular resource, regardless of location. |
nfs | Network File System resources | RFC 2224 | generic syntax | |
nntp | Usenet NNTP | RFC 1738 | nntp://<host>:<port>/<newsgroup-name>/<article-number> |
Referencing a specific host is often less useful than referencing the resource generically, as NNTP servers are not always publicly accessible |
opaquelocktoken | opaquelocktoken | RFC 4918 | ||
pop | Accessing mailbox through POP3 | RFC 2384 | pop://[<user>[;AUTH=<auth>]@]<host>[:<port>] |
|
pres | Used in Common Profile for Presence (CPP) to identify presence | RFC 3859 | pres:<address>[?<header1>=<value1>[&<header2>=<value2>]] |
Similar to "mailto:" |
prospero | Prospero Directory Service | RFC 4157 | Listed as "Historical" by IANA. | |
rtsp | Real Time Streaming Protocol | RFC 2326 | ||
service | RFC 2609 | |||
shttp | Secure HTTP | RFC 2660 | Largely superseded by HTTPS. | |
sip | Used with Session Initiation Protocol (SIP) | RFC 3969 RFC 3261 |
sip:<user>[:<password>]@<host>[:<port>][;<uri-parameters>][?<headers>]
examples: |
|
sips | Secure equivalent of sip | RFC 3969 RFC 3261 |
sips:<user>[:<password>]@<host>[:<port>][;<uri-parameters>][?<headers>] |
|
snmp | Simple Network Management Protocol | RFC 4088 | snmp://[user@]host[:port][/[<context>[;<contextEngineID>]][/<oid>]]
examples: |
|
soap.beep soap.beeps |
RFC 3288 | |||
tag | RFC 4151 | |||
tel | Used for telephone numbers | RFC 3966 RFC 2806 |
tel:<phonenumber> |
|
telnet | Used with telnet | RFC 4248 | telnet://<user>:<password>@<host>[:<port>/] |
|
tftp | Trivial File Transfer Protocol | RFC 3617 | ||
thismessage | multipart/related relative reference resolution | RFC 2557 | ||
tip | Transaction Internet Protocol | RFC 2371 | ||
tv | TV Broadcasts | RFC 2838 | ||
urn | Uniform Resource Names | RFC 2141 | urn:<namespace>:<specificpart> |
|
vemmi | Versatile Multimedia Interface | RFC 2122 | ||
wais | Used with Wide area information server (WAIS) | RFC 4156 | wais://<host>:<port>/<database>[?<search>] or wais://<host>:<port>/<database>/<wtype>/<wpath> |
Listed as "Historical" by IANA. |
xmlrpc.beep xmlrpc.beep |
RFC 3529 | |||
xmpp | XMPP (Jabber) | RFC 5122 | xmpp:<user>@<host>[:<port>]/[<resource>][?<query>] |
|
z39.50r | Z39.50 retrieval | RFC 2056 | z39.50r://<host>[:<port>]/<database>?<docid>[;esn=<elementset>][;rs=<recordsyntax>] |
|
z39.50s | Z39.50 session | RFC 2056 | z39.50s://<host>[:<port>]/[<database>][?<docid>][;esn=<elementset>][;rs=<recordsyntax>] |
[edit] Unofficial but common URI schemes
Scheme | Purpose | Defined by | General format | Notes |
---|---|---|---|---|
about | Displaying product information and internal information | Un-standardised about:blank is commonly used to display a blank page. |
Widely used by web browsers, sometimes even providing interactive resources. The Opera web browser uses opera: instead. |
|
aim | Controlling AOL Instant Messenger. | AOL | aim:<function>?<parameters> |
Functions include goim , addbuddy , and buddyicon . |
callto | Launching Skype call (+And in Hungary the KLIP Software call too) (unofficial; see also skype:) | Skype | callto:<screenname> orcallto:<phonenumber> [2] |
Introduced with Microsoft NetMeeting. Works with current version of Skype with Firefox, Internet Explorer and Safari |
chrome | Specifies user interfaces built using XUL in Mozilla-based browsers. | Mozilla | chrome://<package>/<section>/<path> (Where <section> is either "content ", "skin " or "locale ") |
Works only in Mozilla-based browsers such as Firefox, SeaMonkey and Netscape. |
cvs | Provides a link to a Concurrent Versions System (CVS) Repository | Concurrent Versions System | cvs://<method:logindetails>@<repository>/<modulepath>;[date=date to retrieve | tag=tag to retrieve] |
|
ed2k | Resources available using the eDonkey2000 network | eDonkey2000 | ed2k://|file|<filename>|<size of file>|<hash of file>|/ ored2k://|server|<host>|<port>|/ |
Links to servers are also possible, as are additional parameters. Official documentation from eDonkey2000 website at the Internet Archive Wayback Machine |
feed | web feed subscription | feed:<absolute_uri> orfeed://<hierarchical part>
examples: |
See Feed URI scheme for a detailed overview of common implementations, supported software, and critics. | |
fish | Accessing another computer's files using the SSH protocol | fish KDE kioslave | fish://[<username>[:<password>]@]<hostname>[:<port>] |
See Files transferred over shell protocol for details about the protocol. |
gg | Starting chat with Gadu-Gadu user | Gadu-Gadu | gg:<userid> |
|
gizmoproject | Gizmo Project calling link. | gizmoproject://call?id=<gizmo_id> |
May use sip:// instead of gizmoproject:// in recent versions of Gizmo. | |
iax2 | Inter-Asterisk eXchange protocol version 2 | IETF Draft | iax2:[<username>@]<host>[:<port>][/<number>[?<context>]]
examples: |
|
irc | Connecting to a server to join a channel. | IETF Draft Old IETF Draft |
irc://<host>[:<port>]/[<channel>[?<password>]] |
Assuming the client knows a server associated with the name, "host" may optionally be an IRC network name. |
ircs | Secure equivalent of irc | IETF Draft | ircs://<host>[:<port>]/[<channel>[?<password>]] |
See irc |
jar | Compressed archive member | Java API | jar:<url>!/[<entry>] |
Works for any ZIP based file. |
keyparc | Keyparc encrypt/decrypt resource. | keyparc://encrypt/<username>/<uri> or
|
||
lastfm | Connecting to a radio stream from Last.fm. | Last.fm | lastfm://<radio_stream> or lastfm://globaltags/<genre> orlastfm://user/<username>/<stuff> |
|
ldaps | Secure equivalent of ldap | ldaps://[<host>[:<port>]][/<dn> [?[<attributes>][?[<scope>][?[<filter>][?<extensions>]]]]] |
Not an IETF standard, but commonly used in applications. | |
magnet | "magnet links" | Magnet-URI Project | magnet:?xt=urn:sha1:<hash of file>&dn=<display name> (other parameters are also possible) |
Used by various peer-to-peer clients, usually providing the hash of a file to be located on the network. |
mms: | Windows streaming media | mms://<host>:<port>/<path> |
Used by Windows Media Player to stream audio and/or video. | |
msnim | Adding a contact, or starting a conversation in Windows Live Messenger | Windows Live Messenger | Add a contact to the buddy list
|
Can be invoked from a web page or via a run command or an ie browser URL (won't work with firefox 2.0.0.8). For web pages use this HTML: <a href="chat?contact=nada@nowhere.com">Click to chat!</a> |
mvn | Access Apache Maven repository artifacts | OPS4J | mvn:org.ops4j.pax.web.bundles/service/0.2.0-SNAPSHOT mvn:http://user:password@repository.ops4j.org/maven2!org.ops4j.pax.web.bundles/service/0.2.0 |
|
notes | Open a Lotus Notes document or database | Lotus Notes | notes://<address> |
Used by IBM Lotus Notes to refer to documents and databases stored within the Lotus Notes system. When clicked in a browser on a computer with Lotus Notes client installed, Notes will open the document link as if a Notes DocLink were clicked within Notes. |
nsfw | Not Safe For Work | N/A[citation needed] | nsfw://<address> |
NSFW is not an official URI and is not known to be in use by any programs. Using an "NSFW" address will result in a browser error. However, "nsfw://" indicates that the address which follows may be objectionable in nature, containing explicit material unsuitable for work or school environments. To view the address, the "nsfw://" tag must be replaced by the user with "http://". |
psyc | Used to identify or locate a person, group, place or a service and specify its ability to communicate | PSYC | psyc:[//<host>[:[<port>][<transport>]]/[<object-name>][#<channel-name>] |
Official documentation from PSYC website |
rsync | Rsync | rsync://<host>[:<port>]/<path> |
||
secondlife | Open the Map floater in Second Life application to teleport the resident to the location. | Linden Lab | secondlife://<region name>/<x position>/<y position>/<z position> |
Used by SLurl.com. Knowledge base article. |
skype | Launching Skype call (official; see also callto:) | Skype | skype:<username|phonenumber>[?[add|call|chat|sendfile|userinfo]] |
Official documentation from Skype website. |
ssh | SSH connections (like telnet:) and | IETF Draft | ssh://[<user>[;fingerprint=<host-key fingerprint>]@]<host>[:<port>] |
|
sftp | SFTP file transfers (not be to confused with FTPS (FTP/SSL)) | IETF Draft | sftp://[<user>[;fingerprint=<host-key fingerprint>]@]<host>[:<port>]/<path>/<file> |
|
smb | Accessing SMB/CIFS shares | IETF Draft | smb://[<user>@]<host>[:<port>][/[<path>]][?<param1>=<value1>[;<param2>=<value2>]] orsmb://[<user>@]<workgroup>[:<port>][/] |
|
sms | Interact with SMS capable devices for composing and sending messages. | IETF draft | sms:<phone number>?<action> |
Should be used as a subset to the tel: schema.[citation needed] |
soldat | Joining servers | Soldat | soldat://<host>:<port>/
example: |
Official note in Manual |
steam | Interact with Steam: install apps, purchase games, run games, etc. | Steam, Valve Corporation | steam:<command line arguments> orsteam://<action>/<id, addon, IP, hostname, etc.> |
Official documentation from Valve Developer Community website |
teamspeak | Joining a server. | TeamSpeak | teamspeak://<server>[:<port>]/[?<parameter1>=<value1>[&<parameter2>=<value2>]] |
Official documentation from TeamSpeak Website |
unreal | Joining servers | Unreal | unreal://<server>[:<port>]/ |
Unreal legacy "protocol" |
ut2004 | Joining servers | Unreal Tournament 2004 | ut2004://<server>[:<port>][/<map>?<options>] |
Documentation from Unreal Developer Network |
ventrilo | Joining a server. | Ventrilo | ventrilo://<server>[:<port>]/[?<parameter1>=<value1>[&<parameter2>=<value2>]] |
Official documentation from Ventrilo Website |
view-source | Shows a web page as code 'in the raw'. | Mozilla | view-source:<URI>
example: |
See ??? for details. |
webcal | Subscribing to calendars in iCalendar format | iCalendar | webcal://<hierarchical part>
example: |
HTTP as a transport protocol is assumed. See Webcal for details. |
wyciwyg | What You Cache Is What You Get WYCIWYG | Mozilla | wyciwyg://<URI> |
See WYCIWYG for details. |
xfire | Adding friends and servers, joining servers, changing status text. | Xfire | xfire:<function>[?<parameter1>=<value1>[&<parameter2>=<value2>]] |
Official documentation from Xfire website |
xri | eXtensible Resource Identifier (XRI) | OASIS XRI Technical Committee | xri://<authority>[/[<path>]][?<query>][#fragment] |
Official documentation from OASIS XRI Technical Committee |
ymsgr | Sending an instant message to a Yahoo! Contact. | Yahoo! Messenger | ymsgr:sendIM?<screenname> |
[edit] External links
|