Execute Attack - Login attacks
(args)
| 320 | print("\n✅ Analyze completed!") |
| 321 | |
| 322 | def execute_attack(args): |
| 323 | """Execute Attack - Login attacks""" |
| 324 | print("🚀 BruteForceAI Attack - Login Attacks") |
| 325 | print("=" * 80) |
| 326 | print(f"Mode: {args.mode}") |
| 327 | print(f"Attack method: {args.attack}") |
| 328 | print(f"Threads: {args.threads}") |
| 329 | print(f"Retry attempts: {args.retry_attempts}") |
| 330 | print(f"DOM threshold: {args.dom_threshold}") |
| 331 | print(f"Delay: {args.delay}s") |
| 332 | print(f"Jitter: {args.jitter}s") |
| 333 | print(f"Success exit: {args.success_exit}") |
| 334 | print(f"User agents: {args.user_agents or 'Default browser'}") |
| 335 | print(f"URLs file: {args.urls}") |
| 336 | print(f"Usernames file: {args.usernames}") |
| 337 | print(f"Passwords file: {args.passwords}") |
| 338 | print(f"Database: {args.database}") |
| 339 | print(f"Show browser: {args.show_browser}") |
| 340 | print(f"Browser wait: {args.browser_wait}s") |
| 341 | print(f"Proxy: {args.proxy or 'None'}") |
| 342 | print(f"Debug: {args.debug}") |
| 343 | print(f"Verbose: {args.verbose}") |
| 344 | print(f"Force retry: {args.force_retry}") |
| 345 | |
| 346 | # Print webhook configuration |
| 347 | webhooks_configured = [] |
| 348 | if getattr(args, 'discord_webhook', None): |
| 349 | webhooks_configured.append("Discord") |
| 350 | if getattr(args, 'slack_webhook', None): |
| 351 | webhooks_configured.append("Slack") |
| 352 | if getattr(args, 'teams_webhook', None): |
| 353 | webhooks_configured.append("Teams") |
| 354 | if getattr(args, 'telegram_webhook', None) and getattr(args, 'telegram_chat_id', None): |
| 355 | webhooks_configured.append("Telegram") |
| 356 | |
| 357 | if webhooks_configured: |
| 358 | print(f"Webhooks: {', '.join(webhooks_configured)}") |
| 359 | else: |
| 360 | print(f"Webhooks: None") |
| 361 | |
| 362 | print("=" * 80) |
| 363 | |
| 364 | # Initialize BruteForceAI |
| 365 | bf = BruteForceAI( |
| 366 | urls_file=args.urls, |
| 367 | usernames_file=args.usernames, |
| 368 | passwords_file=args.passwords, |
| 369 | show_browser=args.show_browser, |
| 370 | browser_wait=args.browser_wait, |
| 371 | proxy=args.proxy, |
| 372 | database=args.database, |
| 373 | debug=args.debug, |
| 374 | retry_attempts=args.retry_attempts, |
| 375 | dom_threshold=args.dom_threshold, |
| 376 | verbose=args.verbose, |
| 377 | delay=args.delay, |
| 378 | jitter=args.jitter, |
| 379 | success_exit=args.success_exit, |
no test coverage detected