Projects STRLCPY Hunt3r Commits 9ec0aef0
🤬
  • ■ ■ ■ ■ ■ ■
    backend/app/controllers/scans_controller.rb
    skipped 83 lines
    84 84   scan_cmd[:cmd] += " --scan-id #{scan.id} --type-scan #{scan.type_scan} -d #{scan.domain}"
    85 85   
    86 86   slack_webhook = Tool.find_by(name: 'slack')&.infos
    87  - scan_cmd[:cmd] += " --slack #{slack_webhook['webhook']}"
    88  - scan_cmd[:errors] = 'missing_webhook' if scan.notifs && slack_webhook.nil?
     87 + if scan.notifs && slack_webhook.nil?
     88 + scan_cmd[:errors] = 'missing_webhook'
     89 + else
     90 + scan_cmd[:cmd] += " --slack #{slack_webhook['webhook']}"
     91 + end
    89 92   
    90 93   scan_cmd = build_recon_scan_cmd(scan, scan_cmd) if scan.type_scan == 'recon'
    91 94   scan_cmd = build_nuclei_scan_cmd(scan, scan_cmd) if scan.nuclei || scan.type_scan == 'nuclei'
    skipped 240 lines
Please wait...
Page is in error, reload to recover