Skip to content

Question: Send body with http-post module #1063

Description

@mb720

Hi and thanks for Hydra!

After reading hydra -U http-post, I can't figure out how to send an HTTP POST body.

The server accepts credentials as JSON in the body. This works for logging in: curl -X POST http://npm-registry:4873/-/verdaccio/sec/login -H "Content-Type: application/json" -d '{"username":"testuser","password":"myPassword"}'

Trying hydra -d -l testuser -P ./hydra_passwords.txt -s 4873 npm-registry http-post '/-/verdaccio/sec/login:{"username"\:"^USER^","password"\:"^PASS^"}:h=Content-Type\: application/json:denied' I get the error

optional parameters must have the format X=value

Can I define a body using the http-post module?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions