摘要:
Impossible Level 查看源码 impossible.php <?php $headerCSP = "Content-Security-Policy: script-src 'self';"; header($headerCSP); ?> <?php if (isset ($_POST[ 阅读全文
posted @ 2020-05-06 17:22
zhengna
阅读(339)
评论(0)
推荐(0)
摘要:
High Level 查看源码 high.php <?php $headerCSP = "Content-Security-Policy: script-src 'self';"; header($headerCSP); ?> <?php if (isset ($_POST['include'])) 阅读全文
posted @ 2020-05-06 17:21
zhengna
阅读(427)
评论(0)
推荐(0)
摘要:
Medium Level 查看代码 <?php $headerCSP = "Content-Security-Policy: script-src 'self' 'unsafe-inline' 'nonce-TmV2ZXIgZ29pbmcgdG8gZ2l2ZSB5b3UgdXA=';"; heade 阅读全文
posted @ 2020-05-06 17:20
zhengna
阅读(354)
评论(0)
推荐(0)
摘要:
CSP Content-Security-Policy是指HTTP返回报文头中的标签,浏览器会根据标签中的内容,判断哪些资源可以加载或执行。翻译为中文就是内容安全策略。是为了缓解潜在的跨站脚本问题(XSS),浏览器的扩展程序系统引入了内容安全策略这个概念。原来应对XSS攻击时,主要采用函数过滤、转义 阅读全文
posted @ 2020-05-06 17:19
zhengna
阅读(848)
评论(0)
推荐(0)
摘要:
Impossible Level 查看源码 <?php if( isset( $_POST[ 'btnSign' ] ) ) { // Check Anti-CSRF token checkToken( $_REQUEST[ 'user_token' ], $_SESSION[ 'session_t 阅读全文
posted @ 2020-05-06 17:17
zhengna
阅读(413)
评论(0)
推荐(0)
摘要:
High Level 查看源码 <?php if( isset( $_POST[ 'btnSign' ] ) ) { // Get input $message = trim( $_POST[ 'mtxMessage' ] ); $name = trim( $_POST[ 'txtName' ] ) 阅读全文
posted @ 2020-05-06 17:16
zhengna
阅读(385)
评论(0)
推荐(0)
摘要:
Medium Level 查看代码 <?php if( isset( $_POST[ 'btnSign' ] ) ) { // Get input $message = trim( $_POST[ 'mtxMessage' ] ); $name = trim( $_POST[ 'txtName' ] 阅读全文
posted @ 2020-05-06 17:15
zhengna
阅读(452)
评论(0)
推荐(0)
摘要:
Low Level 查看代码 <?php if( isset( $_POST[ 'btnSign' ] ) ) { // Get input $message = trim( $_POST[ 'mtxMessage' ] ); $name = trim( $_POST[ 'txtName' ] ); 阅读全文
posted @ 2020-05-06 17:13
zhengna
阅读(316)
评论(0)
推荐(0)
摘要:
Impossible Level 查看源码 <?php // Is there any input? if( array_key_exists( "name", $_GET ) && $_GET[ 'name' ] != NULL ) { // Check Anti-CSRF token check 阅读全文
posted @ 2020-05-06 17:12
zhengna
阅读(604)
评论(0)
推荐(0)
摘要:
High Level 查看源码 <?php header ("X-XSS-Protection: 0"); // Is there any input? if( array_key_exists( "name", $_GET ) && $_GET[ 'name' ] != NULL ) { // G 阅读全文
posted @ 2020-05-06 17:11
zhengna
阅读(454)
评论(0)
推荐(0)
浙公网安备 33010602011771号