Arjun icon indicating copy to clipboard operation
Arjun copied to clipboard

how to pass JWT Token

Open niyosh opened this issue 3 years ago • 2 comments

I am using the JWT token for authorisation in the header. How to pass it in Arjun. I tried the "--header" option, but it did not work.

Authorization: Bearer eyJhbGciOiJIUzUxMiJ9.eyJzdWIiOiJmZWxpeF8wOV9AZ21haWwuY29tIiwiaWF0IjoxNjUzODg0ODgxLCJleHAiOjE2NTM5NzEyODF9.Ep0Abs-riT5DgEZns9QNdgVjAWFC8ZRlbkq1AYPSf_l-0Y7ab7T4yYjRzv2bBwyc92Ekg1Nsq3i8M7M1HGseMA

niyosh avatar May 30 '22 05:05 niyosh

Can you share the exact command so I can know that you are supplying it correctly?

s0md3v avatar May 30 '22 08:05 s0md3v

arjun -u http://localhost:8888/api/customer/details --headers 'Authorization: Bearer eyJhbGciOiJIUzUxMiJ9.eyJzdWIiOiJmZWxpeF8wOV9AZ21haWwuY29tIiwiaWF0IjoxNjUzODg0ODgxLCJleHAiOjE2NTM5NzEyODF9.Ep0Abs-riT5DgEZns9QNdgVjAWFC8ZRlbkq1AYPSf_l-0Y7ab7T4yYjRzv2bBwyc92Ekg1Nsq3i8M7M1HGseMA'

error: unrecognized arguments: Bearer eyJhbGciOiJIUzU....

niyosh avatar May 30 '22 11:05 niyosh

Looks like there's some mess up in how your shell interprets command line arguments. You can try using double quotes instead of single quotes.

I am unable to reproduce this and there are no other reports for this so I will close it.

s0md3v avatar Aug 27 '22 07:08 s0md3v