Answer the question
In order to leave comments, you need to log in
Is this considered a vulnerability and is it possible to carry the attack and hack the site?
There is a field in the site search form:
<input type="text" id="input_id" name="val" value="">
<input type="text" id="input_id" name="val" value="" placeholder="crack">
Answer the question
In order to leave comments, you need to log in
<input type="text" id="input_id" name="val" placeholder="crack_start">
<script>
console.log('Knock-knock')
alert('u h4z b33n cr4ck3d')
<"crack_end">
Can you explain to me how to break the site through placeholder?: D, because in fact it does not give anything
You won't be able to break the site through placeholder!
and whatever XSS is, just filter the variables at least by the minimum
strip_tags - removes html tags.
htmlspecialchars - converts special. characters in the html entity.
This is how you protect yourself from XSS attacks, in addition to SQL injection.
If you need html tags, but only for displaying the source code, then it is enough to use:
$input_text = htmlspecialchars($_GET['input_text']);
$input_text = mysql_escape_string($input_text);
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question