M师傅语录:
题目很多围绕着security header来出题,希望开发者重视这些问题,在防御上,正确的设置下面的值,是能够避免很多问题.
content-type、x-xss-protection、x-frame-options、x-content-type-options
1. 文件上传
<?php
header("X-XSS-Protection: 0");
$target_dir = "uploads/";
$target_file = $target_dir . basename($_FILES[&...