Questions tagged [rfc3986]

A RFC entitled "Uniform Resource Identifier (URI): Generic Syntax"

See for more details on RFC

RFC 3986 was released in January 2005.

It supersedes RFC 2732, RFC 2396 and RFC 1808.

Note however the current URL Standard at https://url.spec.whatwg.org/ has among its goals:

Align RFC 3986 and RFC 3987 with contemporary implementations and obsolete them in the process. (E.g., spaces, other "illegal" code points, query encoding, equality, canonicalization, are all concepts not entirely shared, or defined.)

Resources:

46 questions
4568
votes
31 answers

What is the difference between a URI, a URL and a URN?

People talk about URLs, URIs, and URNs as if they're different things, but they look the same to the naked eye. What are the distinguishable differences between them?
Sean McMains
  • 53,635
  • 12
  • 43
  • 52
555
votes
10 answers

Which characters make a URL invalid?

Which characters make a URL invalid? Are these valid URLs? example.com/file[/].html http://example.com/file[/].html
good
  • 5,581
  • 3
  • 14
  • 5
49
votes
1 answer

Is a URL with // in the path-section valid?

I have a question regarding URLs: I've read the RFC 3986 and still have a question about one URL: If a URI contains an authority component, then the path component must either be empty or begin with a slash ("/") character. If a URI does not…
Christian Kuetbach
  • 15,171
  • 4
  • 37
  • 74
34
votes
6 answers

What is the semicolon reserved for in URLs?

The RFC 3986 URI: Generic Syntax specification lists a semicolon as a reserved (sub-delim) character: reserved = gen-delims / sub-delims gen-delims = ":" / "/" / "?" / "#" / "[" / "]" / "@" sub-delims = "!" / "$" / "&" / "'" / "(" / ")" …
Nicole
  • 30,999
  • 11
  • 69
  • 94
32
votes
3 answers

'+' (plus sign) not encoded with RestTemplate using String url, but interpreted as ' ' (space)

We are moving from Java 8 to Java 11, and thus, from Spring Boot 1.5.6 to 2.1.2. We noticed, that when using RestTemplate, the '+' sign is not encoded to '%2B' anymore (changes by SPR-14828). This would be okay, because RFC3986 doesn't list '+' as a…
Gregor Eesmaa
  • 986
  • 11
  • 20
19
votes
6 answers

Can HTTP URIs have non-ASCII characters?

I tried to find this in the relevant RFC, IETF RFC 3986, but couldn't figure it. Do URIs for HTTP allow Unicode, or non-ASCII of any kind? Can you please cite the section and the RFC that supports your answer. NB: For those who might think this…
Cheeso
  • 180,104
  • 92
  • 446
  • 681
18
votes
5 answers

Java and RFC 3986 URI encoding

is there a class to encode a generic String following the RFC 3986 specification? That is: "hello world" => "hello%20world" Not (RFC 1738): "hello+world" Thanks
Mark
  • 57,724
  • 41
  • 114
  • 149
18
votes
2 answers

Official name for URL "scheme plus authority"

Assume an absolute http or https URL. I'm looking for an "official" or generally accepted name for the part of the URL that comes before the path. http://foo:bar@example.com:8042/over/there?name=ferret#nose \_____________________________/ …
Søren Løvborg
  • 7,354
  • 2
  • 40
  • 37
13
votes
3 answers

Is Java's URI.resolve incompatible with RFC 3986 when the relative URI contains an empty path?

I believe the definition and implementation of Java's URI.resolve method is incompatible with RFC 3986 section 5.2.2. I understand that the Java API defines how that method works, and if it were changed now it would break existing apps, but my…
Martin Pain
  • 653
  • 3
  • 17
12
votes
1 answer

When, if ever, should characters like { and } (curly braces) be percent-encoded in URLs?

According to RFC 3986 the following characters are reserved and need to be percent-encoded in order to be used in a URI other than as their reserved uses: :/?#[]@!$&'()*+,;= Furthermore it specifies some characters that are specifically unreserved:…
jacobq
  • 9,812
  • 4
  • 34
  • 64
11
votes
2 answers

RFC3986 - which pchars need to be percent-encoded?

I need to generate a href to a URI. All easy with the exception when it comes to reserved characters which need percent-encoding, e.g. link to /some/path;element should appear as (I know that path;element represents a…
mindas
  • 25,644
  • 13
  • 93
  • 149
8
votes
3 answers

.Net Uri Encoding RFC 2396 vs RFC 3986

First, some quick background... As part of an integration with a third party vendor, I have a C# .Net web application that receives a URL with a bunch of information in the query string. That URL is signed with an MD5 hash and a shared secret key.…
Colin
  • 113
  • 2
  • 6
7
votes
1 answer

What does 'case insensitive' mean in RFC 3986 with respect to non-English characters?

RFC 3986 specifies that the host component of a URI is 'case insensitive'. However, it doesn't specify what 'case insensitive' means in terms of UCS or UTF-8 characters. Examples given in the RFC (e.g. " is equivalent to…
Mark Slater
  • 811
  • 7
  • 15
7
votes
3 answers

What does "abempty" mean in the term "path-abempty" in the context of RFC3986?

See: https://tools.ietf.org/html/rfc3986#section-3 And: https://tools.ietf.org/html/rfc3986#section-3.3 The origin of "abempty" is mysterious to me, and a quick search didn't turn up any definitions of it.
James Shapiro
  • 2,796
  • 1
  • 22
  • 26
7
votes
1 answer

Is question mark in URL part of query string?

TL;TR: Is (first) question mark in URL part of query or is is just a separator followed by query? The RFC 1738, section 3.3, suggests that the "?" (question mark) is not part of the query string, but just separates it from the…
mloskot
  • 33,165
  • 10
  • 97
  • 122
1
2 3 4