• Hi,

    I am unable to create an application password. User is an administrator, and the section for creating the application password under the users profile does have the option.
    When you type in a username and press the “add new application password” button it opens the box where the new password should show but the box stays empty. The sites is https also.

    I have disabled all plugins as well as my theme and revert to twentytwentythree wp basic theme with no success. Do you have any ideas ? or is there another way to create the application password ?

    WordPress 6.1.1, PHP 7.4 Windows Server 2012 r2

    Thanks

    • This topic was modified 1 year, 10 months ago by bulletjie.

    The page I need help with: [log in to see the link]

Viewing 4 replies - 1 through 4 (of 4 total)
  • Moderator bcworkz

    (@bcworkz)

    When you type in a username…

    Do you mean application password name? It can be any arbitrary name, it needn’t be a username. I suppose using a username would be acceptable. I seriously doubt that’s the issue here.

    When you try to add a password, do you at least get the dialog box telling you what the password is? If so, you should at least be able to use it even if it is not shown in the profile table. Have you tried using it?

    You could verify the password was actually saved through the phpMyAdmin app. See if the user has a “_application_passwords” user meta record. They are all saved in a serialized array which is difficult to read, but you should be able to make out the name you used for the password.

    It is possible to create passwords with custom code using the WP_Application_Passwords class. You’d be replicating what the profile dialog does, so I’m not confident this would be a useful workaround. If the profile dialog is failing for some reason, the class’ methods will also likely fail for the same reasons. See if your PHP error log has logged any new messages after you try to add a new password.

    If the password is saved and usable, then the issue is with the profile page itself and the WP_Application_Passwords class is probably fine. If it’s just the profile page display at issue, perhaps some sort of inappropriate caching is at play? Try flushing any caches involved, both client and server side.

    Thread Starter bulletjie

    (@bulletjie)

    Hi Bcworkz,

    Thank you for your reply. Re your question . . yes I do get the dialog box for the password but it stays empty or if the password is there it is hidden somehow. Please see image below

    Moderator bcworkz

    (@bcworkz)

    Your image didn’t embed properly. It could be due to an editor glitch, the block editor in these forums is a new feature and not all the bugs have been fully squashed. No matter, I know what the app passwords UI is supposed to look like ??

    If the generated password is usable, the password list table doesn’t really do much for you beyond reminding you which ones were created. You cannot determine the password from the table, the table mainly serves as a way to revoke individual passwords. You could delete a user’s related meta data to revoke all of their passwords without using the table. It’s much more difficult to remove them individually without the table.

    I’m not suggesting that you shouldn’t want to have a functional table, only that you can still have most password functionality without it while you continue to seek a proper solution.

    I had suspected there’s something amiss with either your SSL cert or the WP algorithm that checks for one. (App passwords are disabled without proper SSL.) Except an anomaly would disable everything, not the just the table. You could try forcing app password availability by adding this line to your theme’s functions.php file:
    add_filter( 'wp_is_application_passwords_available', '__return_true' );
    I’m not convinced it’ll help, but it’s an easy thing to try.

    I wonder if the table HTML is actually there in the profile, but hidden by CSS. To find out, right click on the Add New Application Paasword button and pick Inspect from the context menu. In the resulting element inspector window the button’s HTML will be highlighted. On a normal profile page there should be a list table wrapper div as the next element below the button. Within that div there should be an empty table nav div, then the HTML table itself.

    If the table HTML is there, use the element inspector tool to determine what CSS is hiding it. You could then either correct the source or override it with some custom admin CSS. If it is not there, there is something amiss with the PHP that generates the table. See if your error log has any recent entries associated with when you viewed a user profile. Any related logged message could be a clue to what’s going wrong.

    If the table is completely missing when it should exist and you have no plugins and a default theme, your WP installation is likely corrupted. You may need to do a manual update, even if you “update” to the same version. Before doing that, see if there is a must-use plugin that might be influencing things. Switch to a default theme and deactivate plugins as you have done before. Also rename the /mu-plugins/ folder in /wp-content/. (If there is no such folder, you don’t have must-use plugins.) Now see if a password table is visible. If not, go ahead and do the manual update process.

    I also encountered this problem and don’t know how to solve it. Seems to be a Windows system issue

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘application password not populated’ is closed to new replies.