Skip to content

feat: add --url flag for deploy preview pentesting#9

Merged
Yuvanesh-ux merged 1 commit intomainfrom
feat/url-flag
Mar 30, 2026
Merged

feat: add --url flag for deploy preview pentesting#9
Yuvanesh-ux merged 1 commit intomainfrom
feat/url-flag

Conversation

@Yuvanesh-ux
Copy link
Copy Markdown
Collaborator

@Yuvanesh-ux Yuvanesh-ux commented Mar 30, 2026

Summary

  • Add -u, --url <url> option to pensar pentest for URL-based pentests against deploy preview URLs
  • Sends targetUrl in the POST /ci/dispatch request body when provided
  • Client-side URL validation with clear error message

Test plan

  • npx pensar pentest --help shows --url option
  • --url with invalid URL prints error and exits
  • --url with valid URL includes targetUrl in dispatch request
  • Omitting --url does not send targetUrl

Note

Low Risk
Low risk: additive CLI/API payload change with basic client-side URL validation; main risk is backend compatibility if targetUrl is not expected.

Overview
Adds a new -u, --url <url> option to pensar pentest to run scans against a specific deploy-preview URL.

When provided, the CLI validates the URL and forwards it as targetUrl through CI.runScan into the POST /ci/dispatch request body; omitted URLs keep the existing request shape.

Written by Cursor Bugbot for commit b7c36b3. Configure here.

@Yuvanesh-ux Yuvanesh-ux merged commit d6b1bbb into main Mar 30, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant