All Tests  /  Test 4955

Test Id

Test 4955

Test Trace Id

1485c589-34f8-4468-88bd-81294d2a0e4f

Timestamp

Tue, 23 Jun 2026 21:36:15 GMT

Scenario

Send XSS injection payload in field [deviceId]: [<img src=x onerror=alert('XSS')>]

Expected Result

Should return 4XX

Result

Result Details

The following keywords were detected in the response which might suggest an error details leak: [forbidden]

Contract Path

/api/alerts/by-device/{deviceId}

Fuzzer

XssInjectionInStringFields

Full Request Path

https://qa-api.puk3p.online/api/alerts/by-device/%3Cimg+src%3Dx+onerror%3Dalert%28%27XSS%27%29%3E?size=20&page=0

Http Method

get
Request Details
Payload
{
  "size": 20,
  "deviceId": "<img src=x onerror=alert('XSS')>",
  "page": 0
}
Request Details
Headers
[
  {
    "key": "Accept",
    "value": "application/json"
  },
  {
    "key": "Content-Type",
    "value": "application/json"
  },
  {
    "key": "User-Agent",
    "value": "cats/13.8.1-SNAPSHOT (Test 4955 - XssInjectionInStringFields)"
  },
  {
    "key": "X-Cats-Trace-Id",
    "value": "1485c589-34f8-4468-88bd-81294d2a0e4f"
  }
]
Request Details
cURL
curl  -X GET \
     -H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "User-Agent: cats/13.8.1-SNAPSHOT (Test 4955 - XssInjectionInStringFields)" \
-H "X-Cats-Trace-Id: 1485c589-34f8-4468-88bd-81294d2a0e4f" \
 \
      \
      https://qa-api.puk3p.online/api/alerts/by-device/%3Cimg+src%3Dx+onerror%3Dalert%28%27XSS%27%29%3E?size=20&page=0
Response
{
  "responseCode": 403,
  "httpMethod": "GET",
  "responseTimeInMs": "843",
  "numberOfWordsInResponse": "1",
  "numberOfLinesInResponse": "1",
  "contentLengthInBytes": "153",
  "jsonBody": {
    "timestamp": "2026-06-23T21:36:16.037Z",
    "status": 403,
    "error": "Forbidden",
    "path": "/api/alerts/by-device/%3Cimg+src%3Dx+onerror%3Dalert%28%27XSS%27%29%3E"
  },
  "headers": [
    {
      "key": "cache-control",
      "value": "no-cache, no-store, max-age=0, must-revalidate"
    },
    {
      "key": "content-type",
      "value": "application/json"
    },
    {
      "key": "date",
      "value": "Tue, 23 Jun 2026 21:36:16 GMT"
    },
    {
      "key": "expires",
      "value": "0"
    },
    {
      "key": "pragma",
      "value": "no-cache"
    },
    {
      "key": "server",
      "value": "nginx/1.24.0 (Ubuntu)"
    },
    {
      "key": "strict-transport-security",
      "value": "max-age=31536000 ; includeSubDomains"
    },
    {
      "key": "vary",
      "value": "Origin"
    },
    {
      "key": "x-content-type-options",
      "value": "nosniff"
    },
    {
      "key": "x-frame-options",
      "value": "DENY"
    },
    {
      "key": "x-xss-protection",
      "value": "0"
    }
  ],
  "responseContentType": "application/json"
}
CATS Replay
cats replay Test4955