Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Illegal hex characters in escape (%) pattern #2264

Closed
ghost opened this issue Dec 2, 2014 · 2 comments
Closed

Illegal hex characters in escape (%) pattern #2264

ghost opened this issue Dec 2, 2014 · 2 comments
Assignees
Labels
Milestone

Comments

@ghost
Copy link

ghost commented Dec 2, 2014

Result: https://gist.github.com/johnmuhl/5158e0e4a9418bcfb53e

mkdir 'dir!'
touch 'dir!/100% fun.txt'
jruby -e 'Dir.glob("dir!/**/*")'
jruby -v
jruby 1.7.16.1 (1.9.3p392) 2014-10-28 4e93f31 on Java HotSpot(TM) 64-Bit Server VM 1.8.0_05-b13 +indy +jit [darwin-x86_64]

uname -a
Darwin sortie.local 14.0.0 Darwin Kernel Version 14.0.0: Fri Sep 19 00:26:44 PDT 2014; root:xnu-2782.1.97~2/RELEASE_X86_64 x86_64
@headius
Copy link
Member

headius commented Dec 2, 2014

The problem here is that we treat any path with ! as a URI, and then try to decode the path as a URI. If anything in the path isn't valid for a URI, like %100, we blow up.

Possible fix: https://gist.github.com/headius/2dd9f99ee30d2d7a8470

@headius headius added this to the JRuby 1.7.17 milestone Dec 2, 2014
@headius headius self-assigned this Dec 2, 2014
@headius headius added the core label Dec 2, 2014
@headius
Copy link
Member

headius commented Dec 2, 2014

Needs a spec or test added to rubyspec or MRI, but it should be working right in 1.7.17.

@headius headius closed this as completed Dec 2, 2014
enebo added a commit that referenced this issue Dec 3, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant