Taken from Ruby 1.9’s uri/common.rb By Akira Yamada <akira@ruby-lang.org> License:
You can redistribute it and/or modify it under the same term as Ruby.