In Firefox we use the CredUIPromptForWindowsCredentialsW function to display this prompt, whereas Chromium uses the older[1] CredUIPromptForCredentialsW function. The documentation for CredUIPromptForWindowsCredentialsW doesn't mention a flag that can be used to show a "Logon unsuccessful" message, whereas CredUIPromptForCredentialsW provides CREDUI_FLAGS_INCORRECT_PASSWORD. When CREDUI_FLAGS_INCORRECT_PASSWORD is used with CredUIPromptForWindowsCredentialsW, the prompt removes the option to authenticate with anything other than the password, and the username must be manually entered. We would have to switch to using CredUIPromptForCredentialsW to get the behavior requested by comment #0. It would take some refactoring to use CredUIPromptForCredentialsW and could be do-able for Firefox 77 but probably not upliftable to Firefox 76. [1] The Microsoft documentation includes this note: "Applications that target Windows Vista or Windows Server 2008 should call CredUIPromptForWindowsCredentials instead of this function, for the following reasons: * CredUIPromptForWindowsCredentials is consistent with the current Windows user interface. * CredUIPromptForWindowsCredentials is more extensible, allowing integration of additional authentication mechanisms such as biometrics and smart cards. * CredUIPromptForWindowsCredentials is compliant with the Common Criteria specification."
Bug 1629873 Comment 2 Edit History
Note: The actual edited comment in the bug view page will always show the original commenter’s name and original timestamp.
In Firefox we use the CredUIPromptForWindowsCredentialsW function to display this prompt, whereas Chromium uses the older[1] CredUIPromptForCredentialsW function. The documentation for CredUIPromptForWindowsCredentialsW doesn't mention a flag that can be used to show a "Logon unsuccessful" message, whereas CredUIPromptForCredentialsW provides CREDUI_FLAGS_INCORRECT_PASSWORD. When CREDUI_FLAGS_INCORRECT_PASSWORD is used with CredUIPromptForWindowsCredentialsW, the prompt removes the option to authenticate with anything other than the password, and the username must be manually entered. No message is shown explaining that the password or PIN was incorrect. We would have to switch to using CredUIPromptForCredentialsW to get the behavior requested by comment #0. It would take some refactoring to use CredUIPromptForCredentialsW and could be do-able for Firefox 77 but probably not upliftable to Firefox 76. [1] The Microsoft documentation includes this note: "Applications that target Windows Vista or Windows Server 2008 should call CredUIPromptForWindowsCredentials instead of this function, for the following reasons: * CredUIPromptForWindowsCredentials is consistent with the current Windows user interface. * CredUIPromptForWindowsCredentials is more extensible, allowing integration of additional authentication mechanisms such as biometrics and smart cards. * CredUIPromptForWindowsCredentials is compliant with the Common Criteria specification."