mirror of
https://github.com/j93es/browser-use-oauth.git
synced 2026-06-04 05:11:53 +09:00
Add function to read sensitive data from .sensitive.json file
- Implemented GetSensitiveData function to load sensitive data from a JSON file. - Added error handling for missing file scenario.
This commit is contained in:
parent
29d91bac56
commit
1b65693ba5
6 changed files with 77 additions and 13 deletions
2
main.py
2
main.py
|
|
@ -20,6 +20,7 @@ from lib.utils.backend_client import notify_backend
|
|||
from lib.utils.browser_use import model
|
||||
from lib.utils.browser_use.clean_resources import clean_resources
|
||||
from lib.utils.browser_use.func import setup_storage_state
|
||||
from lib.utils.browser_use.sensitive_data import GetSensitiveData
|
||||
from lib.utils.config import BACKEND_URL, GOOGLE_MODEL, GOOGLE_PLANNER_MODEL
|
||||
from lib.utils.is_html import is_html_url
|
||||
from lib.utils.read_txt import read_lines_between
|
||||
|
|
@ -114,6 +115,7 @@ async def scan_one_url(url: str, skip_html_check: bool = False):
|
|||
agent = Agent(
|
||||
browser_session=session,
|
||||
initial_actions=initial_actions,
|
||||
sensitive_data=GetSensitiveData(),
|
||||
task=(
|
||||
"Navigate to the login page, identify all OAuth provider buttons (excluding Passkey), "
|
||||
"and for each one: click the button, follow the full OAuth login flow as far as possible "
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue