Randy Stauner
da49bee04b
[ruby/uri] Restrict constant checks to current namespace to avoid conflicts with globals
...
7a64e0245f
2024-07-21 16:57:32 +00:00
Hiroshi SHIBATA
8db2325a11
[ruby/uri] Also support URI::PATTERN with switch-back
...
823697edb4
2024-07-19 00:50:38 +00:00
Hiroshi SHIBATA
082335494b
[ruby/uri] Added test for constant definition and remove URI::REGEXP when using RFC3986_PARSER
...
6f616d97fc
2024-07-19 00:50:37 +00:00
Hiroshi SHIBATA
2a56c1841d
[ruby/uri] URI.extract needs to pass block
...
If given block to URI.extract, it returns nil.
984145c407
2024-07-19 00:50:37 +00:00
Hiroshi SHIBATA
6452cf5cb5
[ruby/uri] Added compatibility methods for RFC2396 parser
...
bbb8a40eae
2024-07-19 00:50:36 +00:00
Hiroshi SHIBATA
08e449d89b
[ruby/uri] Added URI.parser= method for switch back to RFC2396_Parser
...
d7dc19ad3f
2024-07-19 00:50:35 +00:00
Hiroshi SHIBATA
7630a89a4b
Use www.rfc-editor.org for RFC text.
...
We use the following site for that now:
* https://tools.ietf.org/ or http
* https://datatracker.ietf.org or http
Today, IETF said the official site of RFC is www.rfc-editor.org.
FYI: https://authors.ietf.org/en/references-in-rfcxml
I replaced them to www.rfc-editor.org.
2024-03-28 11:44:45 +09:00
Hiroshi SHIBATA
fa3d6aafb7
[ruby/uri] Use https instead of http
...
ad2591f0d1
2024-02-20 10:13:30 +00:00
Hiroshi SHIBATA
94af1e5b81
[ruby/uri] Removed commented-out code
...
feb8e0dd73
2024-01-22 00:19:51 +00:00
Jeremy Evans
37657c79b6
[ruby/uri] Make URI#to_s prepend relative path with / if there is a host or port
...
Otherwise, the path could be considered part of the host or port.
This is better than modifying the path to make it absolute when
a host or port is set. We could also raise for invalid paths
when a host or port is set using check_path, but that results
in weird errors, and won't catch issues (such as ftp allowing a
relative path).
Fixes [Bug #19916 ]
ac32aa005b
2024-01-05 16:07:55 +00:00
Hiroshi SHIBATA
460c7b2293
[ruby/uri] Bump up 0.13.0
...
b50d37f7a1
2023-11-06 10:08:41 +00:00
Michael Chui
0164ce893f
add #to_str to URI::Generic
2023-10-26 10:12:49 +09:00
Hiroshi SHIBATA
ab5421547c
[ruby/uri] Bump up v0.12.2
...
e18e657ea8
2023-06-29 01:07:52 +00:00
Nobuyoshi Nakada
995ce947be
[ruby/uri] Fix quadratic backtracking on invalid port number
...
https://hackerone.com/reports/1958260
9d7bcef1e6
2023-06-29 01:07:52 +00:00
Nobuyoshi Nakada
1eff362492
[ruby/uri] Fix quadratic backtracking on invalid relative URI
...
https://hackerone.com/reports/1958260
9010ee2536
2023-06-29 01:07:51 +00:00
Nobuyoshi Nakada
8307627245
[ruby/uri] String literals are frozen now
...
0b6ad60af6
2023-06-25 15:45:32 +00:00
Nobuyoshi Nakada
c21436cb35
[ruby/uri] Fix host part in relative referece #83
...
In relative referece, host part can be ommitted but can not be empty.
2980f0ba02
2023-06-25 15:24:05 +00:00
Nobuyoshi Nakada
6d734a8975
[ruby/uri] Fix RFC3986 regexps
...
8e38592241
2023-06-13 05:57:17 +00:00
Nobuyoshi Nakada
57c5b0a980
[ruby/uri] Refactor RFC3986 regexps to make more readable
...
3dfa19e920
2023-06-13 03:25:45 +00:00
Nobuyoshi Nakada
729b92ea46
[ruby/uri] Drop support for 2.4
...
21baf2ba16
2023-06-02 05:27:06 +00:00
Nobuyoshi Nakada
cfa6a892d0
Redirect to IO::NULL
for the portability
2023-05-05 18:52:36 +09:00
Hiroshi SHIBATA
120d8d0ae2
[ruby/uri] Bump version to 0.12.1
...
5c4f7d04bf
2023-03-28 02:12:22 +00:00
Nobuyoshi Nakada
23f4904f4e
[ruby/uri] Fix quadratic backtracking on invalid URI
...
https://hackerone.com/reports/1444501
2f9585de17
2023-03-28 02:12:22 +00:00
Alexander Popov
35457ebb8f
[ruby/uri] Replace RubyDoc.info links with Ruby.GitHub.io
...
As requested.
c272f205f9
2023-03-01 23:42:50 +00:00
Alexander Popov
bc668d75f6
[ruby/uri] Take out GitHub link for gemspec metadata
...
ca4638a4b3
2023-03-01 23:42:49 +00:00
Alexander Popov
8a5110b664
[ruby/uri] Populate gemspec metadata object
...
31748915d0
2023-03-01 23:42:48 +00:00
Alexander Popov
93a54a3c30
[ruby/uri] Sort gemspec metadata
object alphabetical
...
1e9420b57c
2023-03-01 23:42:47 +00:00
Alexander Popov
932c0e77ee
[ruby/uri] Remake metadata
object in gemspec
into one assignment
...
19a19ccde6
2023-03-01 23:42:47 +00:00
Alexander Popov
57e6d66450
[ruby/uri] Add documentation link into gemspec
...
19ced145f4
2023-03-01 23:42:46 +00:00
Burdette Lamar
41a947e72a
[ruby/uri] [DOC] Enhanced RDoc for URI
...
(https://github.com/ruby/uri/pull/55 )
89ab4f1407
2023-01-08 23:14:50 +00:00
Burdette Lamar
20b691d664
[ruby/uri] [DOC] Enhanced RDoc for URI.decode_www_form
...
(https://github.com/ruby/uri/pull/53 )
ce379e6125
2023-01-08 17:11:12 +00:00
Burdette Lamar
fd98169e00
[ruby/uri] [DOC] Common rdoc ( https://github.com/ruby/uri/pull/52 )
...
be8047028f
2023-01-07 19:22:36 +00:00
Burdette Lamar
ddbf7be94d
[ruby/uri] [DOC] Enhanced RDoc for common methods
...
(https://github.com/ruby/uri/pull/50 )
7ff4fb372b
2023-01-06 14:20:38 +00:00
Burdette Lamar
f7243d1afb
[ruby/uri] [DOC] Common methods rdoc
...
(https://github.com/ruby/uri/pull/49 )
02dfc79366
2023-01-04 19:59:05 +00:00
Burdette Lamar
59cf9ebf4d
[ruby/uri] [DOC] Enhanced RDoc for common methods
...
(https://github.com/ruby/uri/pull/48 )
2bfd848c26
2023-01-03 15:33:45 +00:00
Hiroshi SHIBATA
b62b7dc705
[ruby/uri] Bump version to 0.12.0
...
72f22716f8
2022-12-05 08:20:24 +00:00
Nobuyoshi Nakada
4b1504ae0a
[ruby/uri] Fix splitting relative URI
...
ffbab83de6
2022-10-13 16:24:53 +09:00
NARUSE, Yui
dd5118f852
URI.parse should set empty string in host instead of nil
2022-10-13 11:04:06 +09:00
Benoit Daloze
40ca208a6d
[ruby/uri] Improve URI.register_scheme tests and automatically upcase the given scheme
...
* Also add docs and mention current limitations.
* For reference, https://stackoverflow.com/a/3641782/388803 mentions the
valid characters in schemes.
4346daac75
2022-05-12 18:19:17 +09:00
Jeremy Evans
fbebfe1697
[ruby/uri] Add URI::Generic#decoded_#{user,password}
...
URI::Generic#{user,password} return the encoded values, which are
not that useful if you want to do authentication with them.
Automatic decoding by default would break backwards compatibility.
Optional automatic decoding via a keyword to URI.parse would
require threading the option through at least 3 other methods, and
would make semantics confusing (user= takes encoded or unencoded
password?) or require more work. Thus, adding this as a separate
method seemed the simplest approach.
Unfortunately, URI lacks a method for correct decoding. Unlike in
www form components, + in earlier parts of the URI such as the
userinfo section is treated verbatim and not as an encoded space.
Add URI.#{en,de}code_uri_component methods, which are almost the
same as URI.#{en,de}code_www_form_component, but without the
special SP => + handling.
Implements [Feature #9045 ]
16cfc4e92f
2022-05-12 14:54:37 +09:00
Frank Schmitt
054ae999dc
[ruby/uri] Update file.rb
...
The module here is called `URI`, so it's probably reasonable to expect a requirement for the path to be RFC3986-compliant, but on the other hand, the class is called `File`, so it might be reasonable to expect that a path produced by e.g. the `File` class would be consumable by its `build` method (this fails if the filename contains e.g. a space).
ef79789b83
2022-05-12 10:06:57 +09:00
Peter Zhu
eab354e17b
[ruby/uri] Include RFC2396_REGEXP module directly
...
REGEXP is defined as RFC2396_REGEXP in lib/uri/common.rb. If we include
REGEXP then a broken URL is generated in rdoc for URI and URI::MailTo.
ed6ded9c80
2022-04-22 12:00:14 +09:00
Tiago
553f234a07
[ruby/uri] URI#HTTP#origin and URI#HTTP#authority ( https://github.com/ruby/uri/pull/30 )
...
bf13946c32
Co-authored-by: Samuel Williams <samuel.williams@oriontransfer.co.nz>
2021-10-22 19:48:36 +09:00
Hiroshi SHIBATA
8ef125c838
[ruby/uri] Bump up uri version to 0.11.0
...
1619f713e6
2021-10-21 21:00:04 +09:00
Benoit Daloze
59a65f2d24
Update to latest uri
...
* bc47bf71df
* To include the fix from https://github.com/ruby/uri/pull/27
2021-07-28 12:26:31 +02:00
Hiroshi SHIBATA
6656309fe2
Fix test failure for parallel testing
2021-07-27 17:34:13 +09:00
Benoit Daloze
1cf111774f
[ruby/uri] Add proper Ractor support to URI
...
* Using a module to map scheme name to scheme class, which also works with Ractor.
* No constant redefinition, no ObjectSpace, still fast lookup for initial schemes.
883567fd81
2021-07-27 16:54:27 +09:00
Benoit Daloze
090d799c24
[ruby/uri] Revert "Fix to support Ruby 3.0 Ractor"
...
* This reverts commit 1faa4fdc161d7aeebdb5de0c407b923beaecf898.
* It has too many problems, see https://github.com/ruby/uri/pull/22 for discussion.
b959da2dc9
2021-07-27 16:54:26 +09:00
kvokka
a288c21a5d
[ruby/uri] Fix to support Ruby 3.0 Ractor
...
1faa4fdc16
2021-07-27 16:54:26 +09:00
Steven Harman
bbee6968f8
[ruby/uri] Use Regexp#match? to avoid extra allocations
...
`#=~` builds `MatchData`, requiring extra allocations as compared to
`#match?`, which returns a boolean w/o having to build the `MatchData`.
158f58a9cc
2021-04-22 14:55:44 +09:00