Multiple vulnerabilities found in Rack
groups.google.com
Multiple vulnerabilities found in Rack
1–8 of 8 posts
Re: Multiple vulnerabilities found in Rack
#2Are there details about the file-traversal one?
Re: Multiple vulnerabilities found in Rack
#3Re: Multiple vulnerabilities found in Rack
#4If my site is SSL only, is it still vulnerable to the cookie timing attack? Are there details about the file-traversal one?
The relevant commit [2] and an explanations of equivalent vulnerabilities [3][4]
[1] http://www.youtube.com/watch?v=ehxjAq59xEw
[2] https://github.com/rack/rack/commit/0cd7e9aa397f8ebb3b8481d6...
[3] http://rdist.root.org/2009/05/28/timing-attack-in-google-key...
Re: Multiple vulnerabilities found in Rack
#5How many people use rack? Is it almost always used when deploying rails apps?
Re: Multiple vulnerabilities found in Rack
#6How many people use rack? Is it almost always used when deploying rails apps?
Re: Multiple vulnerabilities found in Rack
#7How many people use rack? Is it almost always used when deploying rails apps?
Any other frameworks/libs that use Rack's session cookies should upgrade though, afaik.
Re: Multiple vulnerabilities found in Rack
#8If my site is SSL only, is it still vulnerable to the cookie timing attack? Are there details about the file-traversal one?
For example:
Symlink: public/foo -> /secret/path/not_very_secret
An attacker could request /foo/../really_secret, which the OS would interpret as /secret/path/really_secret and happily serve up.
The attacker is limited in the number of ".." components they can add to the path by the number of real path components that precede it, i.e. they still cannot do /foo/../../../etc/passwd
The fixed version of rack correctly removes ".." path components before passing the resulting path to the OS, i.e. "/foo/../really_secret" is translated to "/really_secret", and results in a 404 error instead of a security breach.
This vulnerability is particularly concerning for Rails apps deployed using Capistrano (unless config.serve_static_assets = false). This is because there are typically symlinks from public/assets and public/system to the corresponding directories under the Capistrano deploy's "shared" directory, and also under "shared" are typically things like logs, configuration, and a copy of the application code!
Fortunately, Rails ships by default with a production configuration that sets serve_static_assets to false, relying on the frontend web server to serve up all static content (so the attacker will just get a 404). This directory traversal bug is not present in current versions of Apache or nginx.