Advisory Database
  • Advisories
  • Dependency Scanning
  1. gem
  2. ›
  3. activerecord
  4. ›
  5. CVE-2015-7577

CVE-2015-7577: Nested attributes rejection proc bypass

February 15, 2016 (updated August 8, 2019)

When using the nested attributes feature in Active Record you can prevent the destruction of associated records by passing the allow_destroy: false option to the accepts_nested_attributes_for method. The allow_destroy flag prevents the :reject_if proc from being called because it assumes that the record will be destroyed anyway. However, this is not true if :allow_destroy is false so this leads to changes that would have been rejected being applied to the record. Attackers could set attributes to invalid values or clear all the attributes.

References

  • groups.google.com/forum/

Code Behaviors & Features

Detect and mitigate CVE-2015-7577 with GitLab Dependency Scanning

Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Learn more about Dependency Scanning →

Affected versions

All versions starting from 5.0.0.alpha before 5.0.0.beta1.1, all versions starting from 4.2.0.alpha before 4.2.5.1, all versions starting from 4.0.0.alpha before 4.1.14.1, all versions starting from 3.1.0.alpha before 3.2.22.1

Fixed versions

  • 3.2.22.1
  • 4.1.14.1
  • 4.2.5.1
  • 5.0.0.beta1.1

Solution

Upgrade to latest, apply patches or use workaround. See provided link.

Impact 5.3 MEDIUM

CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N

Learn more about CVSS

Weakness

  • CWE-284: Improper Access Control

Source file

gem/activerecord/CVE-2015-7577.yml

Spotted a mistake? Edit the file on GitLab.

  • Site Repo
  • About GitLab
  • Terms
  • Privacy Statement
  • Contact

Page generated Wed, 14 May 2025 12:15:40 +0000.