T05 · Unauthorized Access and Privilege Escalation
- Location
scripts/run_web_chat.py:449- Finding
Whole Browser Profile Is Copied and Exposed Through Chrome DevTools
- Content
View full analysis
None: if not src.exists(): return if src.is_dir(): shutil.copytree(src, dst, dirs_exist_ok=True) return dst.parent.mkdir(parents=True, exist_ok=True) shutil.copy2(src, dst) def seed_debug_profile(source: Optional[Path], target: Path, profile_directory: str = "Default") -> None: target.parent.mkdir(parents=True, exist_ok=True) if source and source.exists(): try: if source.resolve() == target.resolve(): clear_lock_markers(target) return except OSError: pass reset_directory(target) if not source or not source.exists(): return for item_name in SHARED_USER_DATA_ITEMS: copy_path(source / item_name, target / item_name) profile_source = source / profile_directory if profile_source.exists(): copy_path(profile_source, target / profile_directory) clear_lock_markers(target) ``` ```python args = [ str(installation.browser_path), f"--remote-debugging-port={port}", "--remote-debugging-address=127.0.0.1", f"--user-data-dir={installation.user_data_dir}", f"--profile-directory={installation.profile_directory}", "--no-first-run", "--no-default-browser-check", "--disable-breakpad", initial_url, ] ``` ```python seed_debug_profile( installation.user_data_dir, debug_profile_dir, installation.profile_directory, ) debug_installation = BrowserInstallation( name=installation.name, browser_path=installation.browser_path, user_data_dir=debug_profile_dir, prof ...[truncated 2636 chars]- Remediation
View remediation
