diff options
| author | akr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2005-02-12 05:12:56 +0000 |
|---|---|---|
| committer | akr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2005-02-12 05:12:56 +0000 |
| commit | b7679281855ca4fa87fc88e98d4d3167ebb3ea35 (patch) | |
| tree | 52cdca0d19bad1378c0b577051c812a63378a452 /lib | |
| parent | d6b8c0464455c43cc109327adc80c179d5c5cb22 (diff) | |
| download | ruby-b7679281855ca4fa87fc88e98d4d3167ebb3ea35.tar.gz ruby-b7679281855ca4fa87fc88e98d4d3167ebb3ea35.tar.xz ruby-b7679281855ca4fa87fc88e98d4d3167ebb3ea35.zip | |
* lib/open-uri.rb (OpenURI.open_http): reject userinfo explicitly.
git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@7948 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/open-uri.rb | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/open-uri.rb b/lib/open-uri.rb index f29be17a4..344edc5e8 100644 --- a/lib/open-uri.rb +++ b/lib/open-uri.rb @@ -200,6 +200,10 @@ module OpenURI raise "Non-HTTP proxy URI: #{proxy}" if proxy.class != URI::HTTP end + if target.userinfo + raise "userinfo not supported. [RFC3986]" + end + require 'net/http' klass = Net::HTTP if URI::HTTP === target |
