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
def login_check(username, password):
options = uc.ChromeOptions()
options.add_argument("--headless") # Run headless for no browser UI
driver = uc.Chrome(options=options)
# Open the login page
driver.get(login_url)
time.sleep(2) # Wait for the page to load
# Find username and password fields
username_field = driver.find_element(By.NAME, "email")
password_field = driver.find_element(By.NAME, "password")
# Enter credentials
username_field.send_keys(username)
password_field.send_keys(password)
# Click login button
login_button = driver.find_element(By.XPATH, "//button[@type='submit']")
login_button.click()
# Wait for the login attempt to complete
time.sleep(5)
# Check if login was successful (example: by checking URL or page content)
if "dashboard" in driver.current_url or "dashboard" in driver.page_source:
print(f"[+] Login successful for {username}")
else:
print(f"[-] Login failed for {username}")
# Close the browser
driver.quit()
Main function to run login checks for all accounts
def check_all_accounts():
for username, password in accounts:
login_check(username, password)
Originally posted by @MrDot33 in #12045
The text was updated successfully, but these errors were encountered: