Timing Attack Affecting actionpack package, versions < 5.0.0.beta1.1, >= 4.3 < 4.2.5.1, >= 4.2 < 4.1.14.1, >= 3.2.23 < 3.2.22.1


0.0
low

Snyk CVSS

    Attack Complexity High

    Threat Intelligence

    EPSS 1.89% (89th percentile)
Expand this section
NVD
3.7 low
Expand this section
Red Hat
4.3 medium

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications
  • Snyk ID SNYK-RUBY-ACTIONPACK-20258
  • published 24 Jan 2016
  • disclosed 24 Jan 2016
  • credit Daniel Waterworth

Overview

actionpack is a web app builder and tester on Rails.

Affected versions of this Gem are vulnerable to a Timing Attack, via the basic authentication support in Action Controller. This can allow an attacker to determine basic authentication usernames and passwords.

Details

Due to the way that Action Controller compares user names and passwords in basic authentication authorization code, it is possible for an attacker to analyze the time taken by a response and guess the password.

For example, the string comparison "foo" == "far" is possibly faster than the comparison "foo" == "for", as "far" has fewer characters in common with "foo". Attackers can use this information to attempt to guess the username and password used in the basic authentication system, one character at a time.

You can tell your application is vulnerable to this attack by looking for http_basic_authenticate_with method calls in your application.

You can read more about timing attacks (using Node.js as an example) on the Snyk blog: https://snyk.io/blog/node-js-timing-attack-ccc-ctf/