# Active Record component in Ruby on Rails has a data-type injection vulnerability

Advisory record · `GHSA-f57c-hx33-hvh8`

- **Identifiers:** `GHSA-f57c-hx33-hvh8` · `CVE-2013-3221`
- **State:** Confirmed
- **Severity:** CVSS 4.0, no score published
- **Critical:** No
- **Weakness (CWE):** [CWE-20](https://cwe.mitre.org/data/definitions/20.html) · [CWE-89](https://cwe.mitre.org/data/definitions/89.html)
- **Tags:** [SQL injection](https://agentprime.io/advisories/tag/sql-injection.md) · [CWE-20](https://agentprime.io/advisories/tag/cwe-20.md)
- **Published:** 14 May 2022
- **Updated:** 3 Feb 2026
- **Reviewed by a person:** No

Published by the GitHub Advisory Database at 14 May 2022, 00:54 UTC. agentprime has not analysed this yet, so whether it affects any app is not known.

## Affected packages

- `activerecord` (RubyGems): affected `<4.2.0`; fixed in `4.2.0`

## Not analysed yet

We haven’t published our analysis of this Advisory yet. Once a person has reviewed it, this page will say what’s vulnerable, what has to be true for your app to be affected, and how to check.

## Severity and exploitation

- Score not published, CVSS 4.0: `CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:N/SC:N/SI:N/SA:N`, from GitHub Advisory Database

- **CISA KEV:** Not listed.
- **EPSS:** 0.024, the 84th percentile, on 9 Nov 2026: FIRST’s estimate of the chance of exploitation in the next 30 days.

## Timeline

This record came from the full history of the GitHub Advisory Database, published 14 May 2022. New records show when each source confirmed them.

## Sources

- [GitHub Advisory Database: GHSA-f57c-hx33-hvh8](https://github.com/advisories/GHSA-f57c-hx33-hvh8)
- [OSV: GHSA-f57c-hx33-hvh8](https://osv.dev/vulnerability/GHSA-f57c-hx33-hvh8)
- <https://nvd.nist.gov/vuln/detail/CVE-2013-3221>
- <https://github.com/rails/rails>
- <https://github.com/rubysec/ruby-advisory-db/blob/master/gems/activerecord/CVE-2013-3221.yml>
- <https://groups.google.com/group/rubyonrails-security/msg/1f3bc0b88a60c1ce?dmode=source&output=gplain>
- <https://web.archive.org/web/20130825191249/http://www.phenoelit.org/blog/archives/2013/02/index.html>
- <http://openwall.com/lists/oss-security/2013/02/06/7>
- <http://openwall.com/lists/oss-security/2013/04/24/7>
- <http://pl.reddit.com/r/netsec/comments/17yajp/mysql_madness_and_rails>

Facts on this page come from the GitHub Advisory Database (CC-BY 4.0), OSV and the other sources listed, as published. We don’t reproduce full advisory descriptions, which can contain exploit code.

## Check whether this affects you

A Match means an installed version is in the affected range above. Most don’t affect the app; agentprime hasn’t analysed this one yet.

- With the agentprime MCP server (<https://api.agentprime.io/mcp>), ask your agent to check the project: `check_lockfile` sends a lockfile, `check_packages` a list of installed packages, and both return the Matches and the upgrades that clear them. `get_advisory` returns this record. Setup: <https://agentprime.io/mcp.md>
- In a browser: <https://agentprime.io/check/> reads your lockfile in the browser, never uploading it.
- Whether it touches your code, with file and line: the Claude Code plugin, <https://agentprime.io/plugin.md>
- As JSON: <https://api.agentprime.io/v1/advisories/GHSA-f57c-hx33-hvh8>, or `POST https://api.agentprime.io/v1/match` with your packages (<https://agentprime.io/api.md>)

---

The web page: <https://agentprime.io/advisories/GHSA-f57c-hx33-hvh8/>. Everything for agents: <https://agentprime.io/llms.txt>.
