Support » Plugin: Application Passwords » The Generated Password

  • When I use this, I get a password that looks like this:

    uyd6 2eRm 198d 6gJ9 0GvtF f0rL

    Obviously, that is made up. Then I encode the string using the base64 command:

    echo -n “admin@uyd6 2eRm 198d 6gJ9 0GvtF f0rL” | base64

    I get back nice long string that I will represent like this: lkdfjalkdfjaldskjfaldkjf

    So… when I use this in a curl statement, it looks like this:

    curl –header “Authorization: Basic lkdfjalkdfjaldskjfaldkjf”

    I have also tried:

    curl –header “Authorization: Basic lkdfjalkdfjaldskjfaldkjf” -X GET

    I expect to get my user information, but instead I get back a response that says “User not logged in.”

    It seems like the authentication isn’t working but I don’t know how to test it.

    Does it look like I am doing things correctly?

Viewing 5 replies - 1 through 5 (of 5 total)
  • I had the same trouble, it appears that the spaces in the password are for readability: they should be removed before encoding the name:password string.

    Gah, oops, that wasn’t the issue after all… I too am not having luck with this plugin.

    I’m having trouble too, don’t know if you ever solved it but I believe you need to base64-encode username:password not username@password.

    But I am not able to get it to work either. I wasn’t trying GET, as apparently that should work even without authorization. I tried -X OPTIONS, and on rest api url …/wp-json/wp/v2/posts, WP documentation says supposed to get back the schema of available fields. I can’t get anything but 403 Forbidden, even though viewing the url in a browser works

    Seems that you for some servers need to enable REMOTE_USER variable for remote requests. This solved it for me:—-Missing

    • This reply was modified 2 years, 10 months ago by oan.
    Plugin Author George Stephanis


    You can also run it as

    curl -u username:password and curl will build the auth header for you. May wanna strip out the spaces from the pw, though, or wrap double quotes around the whole parameter.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘The Generated Password’ is closed to new replies.