Miggo Logo

CVE-2025-59712: Snipe-IT allows XSS

6.4

CVSS Score
3.1

Basic Information

EPSS Score
0.06674%
Published
9/19/2025
Updated
9/19/2025
KEV Status
No
Technology
TechnologyPHP

Technical Details

CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:L/I:L/A:N
Package NameEcosystemVulnerable VersionsFirst Patched Version
snipe/snipe-itcomposer< 8.1.188.1.18

Vulnerability Intelligence
Miggo AIMiggo AI

Miggo AIRoot Cause Analysis

The vulnerability analysis began by examining the release notes for Snipe-IT version 8.1.18, the patched version. The release notes explicitly mentioned a fix for escaping user_agent and remote_ip variables in API results, referencing pull request #17330. By inspecting this pull request and its associated commit, I identified the exact code change that addressed the vulnerability. The commit diff clearly shows that the e() (escape) function was added to the remote_ip and user_agent fields within the transformActionlog method of the ActionlogsTransformer.php file. This indicates that prior to the patch, these values were being returned unescaped, creating a Cross-Site Scripting (XSS) vulnerability. When action logs were retrieved via the API, any malicious scripts stored in the user_agent or remote_ip fields would be rendered, leading to execution in the client's browser. Therefore, the transformActionlog function is the identified vulnerable function as it was responsible for processing and returning the unescaped, potentially malicious data.

Vulnerable functions

App\Http\Transformers\ActionlogsTransformer::transformActionlog
app/Http/Transformers/ActionlogsTransformer.php
The `transformActionlog` function in the `ActionlogsTransformer` class was vulnerable to XSS. The `remote_ip` and `user_agent` fields from the `Actionlog` model were returned without proper HTML entity escaping. An attacker could craft a malicious user agent or spoof their IP address to inject malicious scripts. When the action logs are viewed in the application's API responses, these scripts would be executed in the user's browser. The patch mitigates this by applying the `e()` (escape) helper function to these fields, which neutralizes any embedded HTML or scripts.

WAF Protection Rules

WAF Rule

Snip*-IT ***or* *.*.** *llows XSS.

Reasoning

T** vuln*r**ility *n*lysis ****n *y *x*minin* t** r*l**s* not*s *or Snip*-IT v*rsion *.*.**, t** p*t**** v*rsion. T** r*l**s* not*s *xpli*itly m*ntion** * *ix *or *s**pin* `us*r_***nt` *n* `r*mot*_ip` v*ri**l*s in *PI r*sults, r***r*n*in* pull r*qu*s