strongbox-password-safe / Strongbox

A KeePass/Password Safe Client for iOS and OS X
https://strongboxsafe.com
GNU Affero General Public License v3.0
1.33k stars 102 forks source link

Strongbox Autofill for Chrome ignores username field #707

Closed howdytom closed 1 year ago

howdytom commented 1 year ago

There seems to be a bug in the Strongbox AutoFill for Chrome. Strongbox does fill the password field, however misses the username field. It is happening on a couple of Drupal logins and multiple sites e.g. slack.com or https://myaccount.economist.com. I do not recognise any pattern here. I have also tried to create a new entry to no avail.

I am able to use AutoFill Passwords in Safari on Mac on ALL sites. How can I define the input username?

strongbox-mark commented 1 year ago

It will totally depend on the structure of the page itself, how the developers have marked up the fields, we can investigate particular URLs if you have them, to try to improve the detection algorithm though.

howdytom commented 1 year ago

That is weird. All Drupal CMS logins are using the same structure page e.g. https://www.drupal.org/user. Chrome does not Autofill username and password when you access the page with www.example.com, however it is working with subdomains. I hope this make sense.

Same Chrome AutoFill issue with these login pages:

https://forum.matomo.org/ https://www.shutterstock.com/ https://userexperiencedesign.slack.com/ https://drupal.slack.com/

strongbox-mark commented 1 year ago

I'm afraid I don't fully understand your message or what you mean, for example: https://forum.matomo.org/ works for me.

Could you clarify what sites are not working for you?

We can then look at fixing those ones.

howdytom commented 1 year ago

Mark, these sites are not working for me:

https://www.drupal.org/user (highly important to me) https://myaccount.economist.com/ https://www.shutterstock.com/ https://userexperiencedesign.slack.com/ https://drupal.slack.com/

I'm sorry! Please ignore https://forum.matomo.org. Indeed, AutoFill is working.

strongbox-mark commented 1 year ago

Got it thanks!

howdytom commented 1 year ago

...and Chrome AutoFill for SoundCloud is not working for me. Whereas AutoFill works seamless with Safari.

https://soundcloud.com/signin

strongbox-mark commented 1 year ago

Hey @howdytom - that seems ok to me on both Brave and Chrome... What are you seeing?

howdytom commented 1 year ago

@strongbox-mark Hm, Here it does not fill the username in Brave. The inputfield remains empty. I have to manually copy and paste the username and password from the Strongbox AutoFill Extension. The strongbox URL entry with https://www.soundcloud.com is correct.

strongbox-mark commented 1 year ago

That is strange @howdytom - Any other plugins that might interfere? Does it work on Chrome?

howdytom commented 1 year ago

@strongbox-mark There are no additional Extensions in use in Brave. SoundCloud AutoFill works in Safari und Firefox. I have found a solution. When I change the Strongbox AutoFill Site access from "On Click" to "On all sites" the username is filled correctly. It looks like a bug to me? The extension setting does not solve the AutoFill issues with the example site urls from above, though.

Screenshot 2023-06-17 at 18 42 00

strongbox-mark commented 1 year ago

Hi @howdytom - You'll need to give Strongbox permissions. There's no way around this. Please do mention details like this when reporting things.

Understood re the sites above that don't work. We'll work on those.

hehongbo commented 1 year ago

This issue brings my attention. Our company's website uses Drupal under the hood, and with Firefox the autofill add-on of Strongbox will fill in only the password but not the username.

As someone who worked with Drupal-based website development and theming before, I can tell that Drupal allows developers and designers to override the login page to provide a more friendly user interface. BUT even with the native login form from Drupal without any override, the autofill add-on can still only see the password field, not the username.

This is the login form from Drupal without any override. Hope this helps if you want to look into this issue.

<form class="user-login-form" data-drupal-selector="user-login-form" action="/en/user/login" method="post" id="user-login-form" accept-charset="UTF-8">
    <div class="js-form-item form-item js-form-type-textfield form-item-name js-form-item-name"> <label for="edit-name" class="js-form-required form-required">Username</label> <input autocorrect="none" autocapitalize="none" spellcheck="false" autofocus="autofocus" data-drupal-selector="edit-name" aria-describedby="edit-name--description" type="text" id="edit-name" name="name" value="" size="60" maxlength="60" class="form-text required" required="required" aria-required="true">
        <div id="edit-name--description" class="description"> Enter your Website username.</div>
    </div>
    <div class="js-form-item form-item js-form-type-password form-item-pass js-form-item-pass"> <label for="edit-pass" class="js-form-required form-required">Password</label> <input data-drupal-selector="edit-pass" aria-describedby="edit-pass--description" type="password" id="edit-pass" name="pass" size="60" maxlength="128" class="form-text required" required="required" aria-required="true">
        <div id="edit-pass--description" class="description"> Enter the password that accompanies your username.</div>
    </div><input autocomplete="off" data-drupal-selector="form-msazbmmuvznysimbartgbp-1h4m3-slhxjantwsokwe" type="hidden" name="form_build_id" value="form-msaZBmmuvZNYSimBArtgbP-1H4M3-SLHXJantWsOkwE"><input data-drupal-selector="edit-user-login-form" type="hidden" name="form_id" value="user_login_form">
    <div data-drupal-selector="edit-actions" class="form-actions js-form-wrapper form-wrapper" id="edit-actions"><input data-drupal-selector="edit-submit" type="submit" id="edit-submit" name="op" value="Log in" class="button js-form-submit form-submit"></div>
</form>
strongbox-mark commented 1 year ago

Hi @hehongbo @howdytom - This should be improved for you with 1.0.7 on the Extension Stores now. Could you check and let me know?

howdytom commented 1 year ago

@strongbox-mark FANTASTIC!! With 1.0.7, I can confirm it is finally possible to use Autofill on all my Drupal 7 sites. This is a huge step forward. Great job. Thank you such much.