usefulteam / jwt-auth

WordPress JSON Web Token Authentication
https://wordpress.org/plugins/jwt-auth/
122 stars 48 forks source link

Slash password before authenticating #64

Open sviluppomania opened 2 years ago

sviluppomania commented 2 years ago

Fixes erroneous 403 response when a password contains a single quote.

When attempting to authenticate with a (correct) password containing quotes, the API returns "403 Forbidden": { "code": "[jwt_auth] incorrect_password", "message": "...", "data": { "status": 403 } }

Using wp_slash (https://developer.wordpress.org/reference/functions/wp_slash/) to make sure the password is handled correctly.