CVE-2024-58362 SurrealDB before 1.5.5 Query Injection via RPC API
- Published
- Updated
- Exploit status
- No public exploit known
- CISA SSVC
- No known exploitation · automatable: no · technical impact: total
Description
SurrealDB before 1.5.5 (and 2.0.0-beta before 2.0.0-beta.3) accepts an arbitrary object in the signin and signup operations of the RPC API without recursively validating it for non-computed values. When a record access method defines a SIGNIN or SIGNUP query and the RPC API is exposed to untrusted users, an unauthenticated attacker can encode a binary object containing a subquery using the bincode serialization format and supply it in place of credentials. The subquery is then executed within the database owner's SIGNIN/SIGNUP query under a system user session with the editor role, allowing the attacker to select, create, update, and delete non-IAM resources (though not view the query results directly, and not affect IAM resources, which require the owner role).
Upgrade path
5 packages: 4 fixed, 1 partially fixed.
| Package | Affected | Fixed in | Status |
|---|---|---|---|
| crates.io surrealdb(crates.io) | < 1.5.5; >= 2.0.0-beta.1, < 2.0.0-beta.3; All versions | 1.5.5, 2.0.0-beta.3 | Partially fixed |
| crates.io surrealdb | < 1.5.5; >= 2.0.0-beta.1, < 2.0.0-beta.3 | 1.5.5, 2.0.0-beta.3 | Fixed |
| crates.io surrealdb-core | < 1.5.2 | 1.5.2 | Fixed |
| crates.io surrealdb-core(crates.io) | < 1.5.2 | 1.5.2 | Fixed |
| surrealdb | < 1.5.5; = 2.0.0-beta1; = 2.0.0-beta2 | 1.5.5 | Fixed |
Affected products
| Product | Affected versions | Fixed in |
|---|---|---|
| crates.io surrealdb(crates.io) | < 1.5.5 | 1.5.5 |
| crates.io surrealdb-core(crates.io) | < 1.5.2 | 1.5.2 |
| crates.io surrealdb(crates.io) | >= 2.0.0-beta.1, < 2.0.0-beta.3 | 2.0.0-beta.3 |
| crates.io surrealdb(crates.io) | All versions | No fix listed |
| crates.io surrealdb | < 1.5.5 | 1.5.5 |
| crates.io surrealdb | >= 2.0.0-beta.1, < 2.0.0-beta.3 | 2.0.0-beta.3 |
| crates.io surrealdb-core | < 1.5.2 | 1.5.2 |
| surrealdb | < 1.5.5 | 1.5.5 |
| surrealdb | = 2.0.0-beta1 | No fix listed |
| surrealdb | = 2.0.0-beta2 | No fix listed |
References
- GitHub Security Advisory (GHSA-64f8-pjgr-9wmr) vendor-advisory
- github.com patch
- github.com patch
- github.com product
- surrealdb.com
- surrealdb.com
- nvd.nist.gov third-party-advisory vendor-advisory
- VulnCheck Advisory: SurrealDB before 1.5.5 Query Injection via RPC API third-party-advisory
- github.com
- github.com