본문 바로가기

반응형

분류 전체보기

(185)
[PortSwigger] Lab: OS command injection, simple case https://portswigger.net/web-security/os-command-injection/lab-simple Lab: OS command injection, simple case | Web Security Academy This lab contains an OS command injection vulnerability in the product stock checker. The application executes a shell command containing user-supplied ... portswigger.net OS command Injection : 공격자가 응용 프로그램을 실행하는 서버에서 임의의 운영 체제(OS) 명령을 실행할 수 있게 하는 웹 보안 취약점이며, 일반적으로 ..
[PortSwigger] Lab: Basic SSRF against another back-end system https://portswigger.net/web-security/ssrf/lab-basic-ssrf-against-backend-system Lab: Basic SSRF against another back-end system | Web Security Academy This lab has a stock check feature which fetches data from an internal system. To solve the lab, use the stock check functionality to scan the internal ... portswigger.net 서버 측 요청 위조로 자주 발생하는 유형은 애플리케이션 서버가 사용자가 직접 연결할 수 없는 다른 백엔드 시스템과 상호 작용할 수 있는..
[PortSwigger] Lab: Basic SSRF against the local server https://portswigger.net/web-security/ssrf/lab-basic-ssrf-against-localhost Lab: Basic SSRF against the local server | Web Security Academy This lab has a stock check feature which fetches data from an internal system. To solve the lab, change the stock check URL to access the admin interface at ... portswigger.net " SSRF{Server-side Request Forgery} : 공격자가 서버 측 애플리케이션이 공격자가 선택한 임의의 도메인에 HTTP 요청을..
Lord of SQLInjection 13번 bugbear https://los.rubiya.kr/ Lord of SQLInjection los.rubiya.kr Lord of SQLInjection 13번 bugbear if(preg_match('/prob|_|\.|\(\)/i', $_GET[no])) exit("No Hack ~_~"); if(preg_match('/\'/i', $_GET[pw])) exit("HeHe"); if(preg_match('/\'|substr|ascii|=|or|and| |like|0x/i', $_GET[no])) exit("HeHe"); 이번 필터링은 저번 문제에 이어서 ' substr ascii = or and 공백 like 0x '는 hex값을 사용했지만 0x가 안되므로 char를 사용하여 10진수 값을 넣어야 한다. asci..
Lord of SQLInjection 12번 darkknight https://los.rubiya.kr/ Lord of SQLInjection los.rubiya.kr Lord of SQLInjection 12번 darkknight if(preg_match('/prob|_|\.|\(\)/i', $_GET[no])) exit("No Hack ~_~"); if(preg_match('/\'/i', $_GET[pw])) exit("HeHe"); if(preg_match('/\'|substr|ascii|=/i', $_GET[no])) exit("HeHe"); no 필터링은 prob _ . ' substr ascii = 이렇게 되어있다. 싱글쿼터는 goblin 문제처럼 hex값을 사용하면 된다. substr은 mid로 우회할 수 있고, ascii는 ord, =은 like로 우회..
Lord of SQLInjection 11번 golem https://los.rubiya.kr/ Lord of SQLInjection los.rubiya.kr Lord of SQLInjection 11번 golem orge 문제 처럼 파이썬으로 pw를 정확히 구해야 하는 문제이다. 이번 문제에는 and, or 필터링에서 substr과 = 필터링까지 추가 되었다. pw 길이를 먼저 구할때 = 은 입력이 안되니까 like를 사용하여 우회한다. ?pw=%27%20||%20id%20like%20%27admin%27%26%26length(pw)>7%23 pw='' || id like 'admin'&&length(pw)>7#' 이상하게 뒤에 length(pw) like 8은 안된다.. 원래 안되는건가..// 일단 pw의 길이는 8글자이다. import requests ..
Lord of SQLInjection 10번 skeleton https://los.rubiya.kr/ Lord of SQLInjection los.rubiya.kr Lord of SQLInjection 10번 skeleton 이전에 풀었던 wolfman 문제와 비슷하다 뒤에 and 연산이 붙었는데 주석처리를 하여 검증을 하지 못하도록 하면 된다. ?pw=%27or%20id=%27admin%27%23 id='guest' and pw=''or id='admin'#' and 1=0 false and false or true (and는 주석처리)false or truetrue
Lord of SQLInjection 9번 vampire https://los.rubiya.kr/ Lord of SQLInjection los.rubiya.kr Lord of SQLInjection 9번 vampire if(preg_match('/\'/i', $_GET[id])) exit("No Hack ~_~"); i 는 대소문자를 구분하지 않는 필터링이다. $_GET[id] = str_replace("admin","",$_GET[id]); $_GET[id]에 admin이라는 문자열이 있으면 공백으로 바꾸라는 뜻이다. str_replace() : 문자열을 치환하는 함수 1번째 인수 : 변경대상 문자열 2번째 인수 : 변경하려는 문자열 3번째 인수 : replace가 바꾸고자 하는 문자열 ?id=adadminmin replace함수가 있을 때 admin을 'a..

반응형