adnanh / webhook

webhook is a lightweight incoming webhook server to run shell commands
MIT License
10.38k stars 831 forks source link

Invalid url scape "% a" #598

Open Techmahindro opened 2 years ago

Techmahindro commented 2 years ago

hello

I am using webhook to receive hook from a monitoring system.

the way it works is simple my payload captures everything that arrives in a json file.

[
  {
    "id": "testing_start",
    "execute-command": "/monitoring/.local/bin/scripts/redeploy.sh",
    "command-working-directory":"/monitoring/.local/bin/",
    "pass-arguments-to-command":
    [
        {
          "source": "entire-payload"
        }
    ]
  }
]

the problem is that when I receive a hook that contains a special character a % symbol I get the error

error parsing from payload invalid URL escape "% a".

moorereason commented 2 years ago

What version of webhook? Can you show an example request?

Techmahindro commented 2 years ago

webhook version 2.8.0

Techmahindro commented 1 year ago

someone could give me a solution I have the same problem.

fbartels commented 1 year ago

someone could give me a solution I have the same problem.

you are the op ;-)

Can you provide some reproducer. maybe a curl command that posts the data along with your hooks.json? maybe that would help reproducing the problem and moving it further.

Techmahindro commented 1 year ago

it's almost the same as the source problem, i'm using webhook to collect events coming from a monitoring system. we get a simple curl with the parameters. the problem is when that curl contains a sign like % or & forsea and gives the error in the title.