> For the complete documentation index, see [llms.txt](https://hacking-notes.jord4n.pro/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://hacking-notes.jord4n.pro/ar/web-vulnerabilities/proxys-squid-attack/proxys-squid-techniques-pentesting-web.md).

# تقنيات Squid Proxy

## خوادم بروكسي SQUID:

إذا أجرينا هذا الفحص على المنفذ 80، فهذا يدل على أنه **مصفّى** وليس مغلقًا:

<figure><img src="/files/3426a8ab5c2f3feb9dc11173765ca99915fb77df" alt="" width="563"><figcaption></figcaption></figure>

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

إليك الموقع العادي حيث **لا يظهر شيء**:

<figure><img src="/files/59f8d32da09820639376222283af0c9b7a5655b8" alt="" width="560"><figcaption></figcaption></figure>

ننشئ بروكسيًا جديدًا باستخدام **عنوان IP للجهاز** والمنفذ **3128**:

<figure><img src="/files/a9dc7553101a2225d8ba04e11309be7e51c65026" alt="" width="563"><figcaption></figcaption></figure>

مع **FoxyProxy**، يظهر المحتوى:

<figure><img src="/files/1c12e249099a8875a26e6f97ba75b124804e9115" alt="" width="563"><figcaption></figcaption></figure>

### الطريقة في سطر الأوامر:

نرسل باستخدام curl طلبًا إلى خادم الويب باستخدام بروكسي الجهاز عبر المنفذ **3128**:

<figure><img src="/files/2b98ba65b6fda528f42ca683f4144bcb9fe3facb" alt="" width="562"><figcaption></figcaption></figure>

إذا طلب **المصادقة**، فقم بذلك كما يلي:

<figure><img src="/files/5d8cd16a9042610f8ff23e71d2aac9b935464160" alt="" width="563"><figcaption></figcaption></figure>

## استطلاع المسارات (بالمرور عبر البروكسي):

أحيانًا، **لا تظهر المسارات إلا** مع البروكسي، وإليك مثالًا على كيفية رؤيتها:

```bash
gobuster dir -u http://192.168.71.131/ --proxy http://192.168.71.131:3128 -w /usr/share/SecLists/Discovery/Web-Content/directory-list-2.3-medium.txt -t 20

```

<figure><img src="/files/979d1758911f5b1241f2aa103a90b28aca6172e6" alt="" width="563"><figcaption></figcaption></figure>

## سكربت بايثون آلي:

```python
#!/usr/bin/python3
import sys, signal, requests
def def_handler(sig, frame):
    print("/n/n[!] Exiting.../n")
    sys.exit(1)
# تقنيات بروكسي Squid
signal.signal(signal.SIGINT, def_handler)
main_url = "http://127.0.0.1"
squid_proxy = {'http': 'http://192.168.71.131:3128'}
def portDiscovery():
    common_tcp_port= {21, 22, 23, 25, 53, 80, 110, 111, 135, 139, 143, 443, 445, 993, 995, 1723, 3306, 3389, 5900, 8080, 8443, 8888, 5900, 6666, 6667, 6668, 6669, 7000, 10000, 32768, 32769, 32770, 32771, 32772, 32773, 32774, 32775, 32776, 32777, 32778, 32779, 49152, 49153, 49154, 49155, 49156, 49157, 49158, 49159, 49160, 49161, 49162}
    for tcp_port in common_tcp_port:
        r = requests.get(main_url + ':' + str(tcp_port), proxies=squid_proxy)
        if r.status_code != 503:
            print("/n[+] المنفذ " + str(tcp_port) + "- مفتوح")
if __name__ == '__main__':
    portDiscovery()

```

<figure><img src="/files/8c73be0afe9fa9980a1fdf4777ace7d833e25446" alt="" width="563"><figcaption></figcaption></figure>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://hacking-notes.jord4n.pro/ar/web-vulnerabilities/proxys-squid-attack/proxys-squid-techniques-pentesting-web.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
