Skillpedia
الوكلاء35k · #7806

detecting-broken-object-property-level-authorization

ما الذي تفعله

تساعد هذه المهارة على العثور على ثغرات أمنية في واجهات البرمجة. تتحقق مما إذا كانت الواجهة تعرض معلومات لا ينبغي عرضها (مثل كلمات المرور أو الرواتب)، أو تسمح للمستخدمين بتغيير بيانات لا يحق لهم تغييرها، مثل رفع صلاحياتهم إلى مسؤول.

متى تستخدمها

  • ✓عندما تحقق في مشكلة أمنية في تطبيق.
  • ✓عندما تُنشئ اختبارات لضمان أمان واجهة البرمجة.
  • ✓عندما تشتبه في أن بيانات حساسة تُكشف بشكل غير سليم.

رابط المهارة

https://github.com/mukul975/Anthropic-Cybersecurity-Skills/blob/main/skills/detecting-broken-object-property-level-authorization/SKILL.md

انسخه والصقه في الذكاء الاصطناعي الذي تستخدمه (Claude أو ChatGPT أو Cursor) واطلب منه اتباع التعليمات.

طريقة الاستخدام

أسهل طريقة: انسخ الرسالة والصقها في الذكاء الاصطناعي الذي تستخدمه. سيقرأ المهارة وينفّذ تعليماتها.

رسالة جاهزة للصق

استخدم هذه المهارة لمساعدتي: https://github.com/mukul975/Anthropic-Cybersecurity-Skills/blob/main/skills/detecting-broken-object-property-level-authorization/SKILL.md اقرأ ملف SKILL.md في هذا الرابط ونفّذ تعليماته لمهمتي.
تريد أن يجد الذكاء الاصطناعي مهارات مثل هذه بنفسه؟ثبّت خادم Skillpedia MCP المجاني: سطر واحد، ويبحث في 15,000+ مهارة قبل كل مهمة.ثبّته في دقيقة واحدة →

مثال على ما تطلبه من الذكاء الاصطناعي

“تحقق مما إذا كانت واجهة المستخدمين تكشف حقولًا مثل « salary » أو « password » في الاستجابات.”

5 مهارات جديدة كل أسبوع. قراءة في دقيقة واحدة.

كيف تعمل

تقارن المهارة البيانات التي تعيدها الواجهة بما هو متوقع. وتحاول أيضًا إرسال بيانات إضافية أو معدّلة لمعرفة إن كانت الواجهة تقبل تغييرات غير سليمة في الحقول الحساسة.

المحتوى التقني (ملف SKILL.md الأصلي)

النص الأصلي من المؤلف، مباشرة من GitHub.

Detecting Broken Object Property Level Authorization

Overview

Broken Object Property Level Authorization (BOPLA), classified as API3:2023 in the OWASP API Security Top 10, combines two related vulnerability classes: Excessive Data Exposure (API returning more data than needed) and Mass Assignment (API accepting more data than intended). Even when APIs enforce object-level authorization correctly, they may fail to control which specific properties of an object a user can read or modify. Attackers exploit this by reading sensitive properties from API responses or injecting additional properties into request bodies to modify fields they should not have access to.

When to Use

  • When investigating security incidents that require detecting broken object property level authorization
  • When building detection rules or threat hunting queries for this domain
  • When SOC analysts need structured procedures for this analysis type
  • When validating security monitoring coverage for related attack techniques

Prerequisites

  • Target API with endpoints that return or accept object data
  • API documentation or schema (OpenAPI spec preferred)
  • Burp Suite or Postman for API request manipulation
  • Multiple user accounts with different privilege levels
  • Python 3.8+ with requests library for automated testing
  • Authorization to perform security testing

Vulnerability Patterns

Excessive Data Exposure

The API returns object properties the client does not need:

// GET /api/v1/users/123
// Response includes sensitive fields the UI doesn't display:
{
  "id": 123,
  "username": "john_doe",
  "email": "john@example.com",
  "name": "John Doe",
  "ssn": "123-45-6789",           // Sensitive - not needed by UI
  "salary": 95000,                 // Sensitive - not needed by UI
  "internal_notes": "VIP client",  // Internal - should not be exposed
  "password_hash": "$2b$12...",    // Critical - never expose
  "role": "admin",                 // May enable privilege discovery
  "created_by": "system_admin",   // Internal metadata
  "credit_card_last4": "4242"     // PCI compliance violation
}

Mass Assignment

The API binds client-supplied data to internal object properties without filtering:

// Normal user update request
PUT /api/v1/users/123
Content-Type: application/json

{
  "name": "John Updated",
  "email": "new@example.com",
  "role": "admin",           // Attacker-injected: privilege escalation
  "is_verified": true,       // Attacker-injected: bypass verification
  "discount_rate": 100,      // Attacker-injected: business logic abuse
  "account_balance": 999999  // Attacker-injected: financial fraud
}

Testing Methodology

#!/usr/bin/env python3
"""BOPLA Vulnerability Scanner

Tests APIs for Broken Object Property Level Authorization
including Excessive Data Exposure and Mass Assignment.
"""

import requests
import json
import sys
from typing import Dict, List, Optional, Set
from dataclasses import dataclass, field
from copy import deepcopy

@dataclass
class BOPLAFinding:
    endpoint: str
    method: str
    vulnerability_type: str  # "excessive_exposure" or "mass_assignment"
    severity: str
    property_name: str
    details: str

class BOPLAScanner:
    SENSITIVE_PROPERTY_PATTERNS = {
        "critical": [
            "password", "password_hash", "secret", "token", "api_key",
            "private_key", "secret_key", "access_token", "refresh_token",
        ],
        "high": [
            "ssn", "social_security", "tax_id", "credit_card", "card_number",
            "cvv", "bank_account", "routing_number",
        ],
        "medium": [
            "salary", "income", "internal_notes", "admin_notes",
            "created_by", "modified_by", "ip_address", "session_id",
            "role", "permissions", "is_admin", "is_superuser", "privilege",
        ],
        "low": [
            "phone", "address", "date_of_birth", "dob", "age",
            "gender", "ethnicity", "religion",
        ]
    }

    MASS_ASSIGNMENT_FIELDS = [
        ("role", "admin"),
        ("is_admin", True),
        ("is_verified", True),
        ("is_active", True),
        ("email_verified", True),
        ("account_type", "premium"),
        ("discount_rate", 100),
        ("credit_limit", 999999),
        ("permissions", ["admin", "write", "delete"]),
        ("account_balance", 999999),
        ("subscription_tier", "enterprise"),
        ("rate_limit", 999999),
    ]


…
الأسئلة الشائعة

ما هو « Broken Object Property Level Authorization » (BOPLA)؟

هو نوع من الثغرات تفشل فيه واجهة البرمجة في التحكم بشكل صحيح في الأجزاء (الخصائص) من الكائن، مثل المستخدم أو الطلب، التي يحق للمستخدم عرضها أو تعديلها. وقد يؤدي ذلك إلى كشف بيانات حساسة أو تغييرها بشكل غير سليم.

ما نوعا المشكلات التي تكشفها هذه المهارة؟

تكشف « Excessive Data Exposure » (الواجهة تعرض معلومات أكثر من اللازم) و« Mass Assignment » (الواجهة تقبل بيانات لحقول لا يجب أن تقبلها، فيسمح بتغييرات غير سليمة).

هل أحتاج إلى أن أكون مبرمجًا محترفًا لاستخدام هذه المهارة؟

ليس بالضرورة. صُممت المهارة للمساعدة في كشف المشكلات الأمنية، لكن لإعداد الاختبارات الآلية وتشغيلها، تفيد معرفة برمجية أساسية وبعض الإلمام بأدوات مثل Burp Suite وPostman.

التفاصيل

الوصف الأصلي من المؤلف

Detect and test for OWASP API3:2023 Broken Object Property Level Authorization (BOPLA), covering excessive data exposure in API responses and mass assignment via injected request-body properties. Use when reviewing API responses/requests for over-exposed or over-writable object fields, or building detection rules and test cases for property-level authorization gaps that object-level checks miss.

repo: mukul975/Anthropic-Cybersecurity-Skills

الشعبية

نجوم GitHub
35k
الترتيب
#7806
الترخيص
Apache-2.0
آخر تحديث
31‏/8‏/2026

هل هذه المهارة مفيدة؟

0

سجّل الدخول للتصويت.

التعليقات

  • …

المزيد من المهارات من هذا المستودع

مهارات مشابهة