1. Getting Started

Intro to Web Proxies

Web Proxy = أداة تعترض HTTP/S requests بين المتصفح والسيرفر وتسمح بتعديلها

الأدوات الرئيسية:

Setting Up

# Burp Suite
# 1. Proxy → Options → port 8080
# 2. المتصفح → proxy: 127.0.0.1:8080
# 3. زيارة http://burp → تحميل CA Certificate
# 4. ثبّت الشهادة في المتصفح

# FoxyProxy extension — أسهل لتبديل الـ proxy
# أو استخدم Burp Browser المدمج

# ZAP
# Tools → Options → Network → Local Servers → port 8080

2. Web Proxy

Proxy Setup

# Burp intercept
Proxy → Intercept → Intercept is ON

# Forward request:
Forward (Ctrl+F)

# Drop request:
Drop

# إرسال لـ Repeater:
Right click → Send to Repeater (Ctrl+R)

# إرسال لـ Intruder:
Right click → Send to Intruder (Ctrl+I)

Intercepting Web Requests

# مثال request معترض
GET /api/user?id=1 HTTP/1.1
Host: target.com
Cookie: session=abc123
Authorization: Bearer eyJ...

# تعديل مباشر:
# غيّر id=1 إلى id=2
# غيّر الـ Cookie
# أضف headers

Intercepting Responses

# Burp — اعترض الـ response
# Proxy → Options → Intercept Server Responses → Intercept responses based on the following rules

# لماذا؟
# - تعطيل JavaScript checks
# - إزالة disabled attributes
# - تعديل قيم مخفية

# مثال — تعديل response:
# disabled="true"  →  disabled="false"
# max="100"        →  max="9999"

Automatic Modification

# Burp → Proxy → Options → Match and Replace
# مثال:
# Match: User-Agent: Chrome
# Replace: User-Agent: Googlebot

# أو تعديل تلقائي على كل request/response:
# Add header تلقائياً
# استبدال قيمة معينة في كل response

Repeating Requests