szerhusenBC / jwt-spring-security-demo

A demo for using JWT (Json Web Token) with Spring Security and Spring Boot 2

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Unable to access API via curl

alinmateut opened this issue · comments

Whenever I try to run in my terminal
curl localhost:8080/auth --data "username=admin&password=admin"
it gives me an 401 Unauthorized status. How can I fix this?

On your curl command, are you specifying the method request flag, i think it is "-X POST"

i am also having this issue and i am doing it both with postman and passing it with "-X POST" -- no matter what it returns 401 Unauthorized.

Closed, because I published a complete new version.

Closed, because I published a complete new version.