Get the App
SLTechnology News&Howtos  ›  Network Security  › 

XSS Learning Tour

Shulou Source: shulou.com Published: 2022-06-01 02:51:06 10月04日 Update

The experimental environment is the xss9 experiments in Hetian Zhihui.

Experiment 1:

The key code is as follows

Go directly to the payload of xss

Experiment 2:

The key code is as follows:

It's just filtered and keywords, and you can use uppercase bypass.

Experiment 3:

Key code:

The function of the preg_replace function is to filter the keyword and case of the sum, replace it with empty, and construct the payload as shown in the following figure.

Experiment 4:

Key code:

Here just filter the keyword script, change to a payload and then

Experiment 5:

Key code:

What is filtered here is that there is an I after the alert function to indicate ignoring case. Payload is as follows:

Experiment 6:

Key code:

This is mainly bypassed by php syntax, with each statement ending with a semicolon.

Then you can construct the following payload

The source code after execution is as follows:

Experiment 7:

Key code:

The htmlentities function can materialize some symbols. As follows

You can see that the single quotation marks are not filtered, which is basically the same as experiment 6.

Experiment 8 and experiment 9:

Xiaobai has just learned, you can see the specific solution of this place: https://blog.csdn.net/u012763794/article/details/48215585

Experiment 10:

Key code:

It is similar to experiment 6 above. Payload:; alert

Tags: Experiment key code keyword function almost just size function semicolon place uppercase entity quotation mark situation solution source code environment symbol solution Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno macOS Microsoft MySQL vpn Huawei