Why is the password input field auto populated? - html

I have a really strange behaviour of the password input field. When the page is loaded, the first instance of the password input field is populated.
The second password input field, which I added for testing, is not automatically populated. If I change the first password input type from password to text, it is not automatically populated.
There is no JS that populates this field (that I can find).
The code for the new password input fields are:
<input class="form-control" name="User[pass]" type="password" value="" placeholder="New password" autocomplete="off" />
<input class="form-control" name="User[pass]" type="password" value="" placeholder="New password" autocomplete="off" />
The only solution I can think of now, is to add a dummy input field before the New password and hide it.
Has anyone experienced this?
Update
- It seems this problem is only in Firefox
- If I open a new "private browser window", the problem goes away. Most likely because this window do not save anything to the cache.
So if Firefox password caching is the problem, then
a) Why does it populate the password field? This usually only happens when you enter a username in the login form,
b) How can I prevent it?

It happened to me after I installed a password-manager: sometimes when there is a password field it auto-generates a 'secure' password for me. Try disabling all your browser extensions or use a different browser and see if that solves your problem.

This can happen if your browser is using a password manager.
Firefox comes with a password manager, so you don't have to have any extensions installed for this to be a problem.
To clear the passwords from Firefox:
Open the security tabs in Firefox options.
You can get to this by either clicking on the Options button and then clicking on the Security tab, or by typing the following into your browser:
about:preferences#security
Click on the "Saved Logins..." button to open the Saved Logins popup.
The Saved Logins popup should have the list of all the passwords currently saved in the Firefox password manager. At this point, you can choose to "Remove All" passwords, select a specific password to "Remove", or use the Search box to filter the results and "Remove All Shown".
To prevent Firefox from continuing to store passwords, you can uncheck the "Remember logins from sites" checkbox on the Security tab.

Related

How to hide the Manage password bar above the keyboard for non password textboxes in android Chrome?

When I focus in any textbox field, the Password suggestion bar/Manage password board is displayed above the keyboard. In our case, it’s giving very small display for the user to visualize the typed information. I have tried several options like:
Disabling auto-save password
Removing existing saved passwords in the chrome
Disabling keyboard/password settings present in the chrome://flags
Nothing works for me. This looks like a defect as this Manage Password bar is showing up regardless of the field type is password or not. Is there any alternate option/ workaround not to show this bar? It’s working fine for Firefox though.
Defect screenshot for reference

Remove Browser Autofill feature

I need to remove the browser's autofill/suggestion feature.
This autofill is disabled using autocomplete="off" in Textfield component. once I do that this brings browser's auto fill feature
In Edge, If I turn off the "Save and fill the personal info" option in "Settings/Profile/Personal info" the above suggestion is not shown. Is there any way without turning off that setting I can remove the autofill feature using Material UI TextField property or CSS property "input:-webkit-autofill"
If autocomplete fails to work, most likely it's a bug or for some reason, react is preventing the attribute from being modified.
However, I know a simple way to bypass by changing the type attribute to something random, where the browser can't understand what it should ask from the user and therefore, the browser can't prompt an autofill.
For example on a standard HTML input tag:
<input type="inputText"/>
This will still treat it as an input field, however, it will not attempt to autofill.
Its browser functionality which you cant handle from code level. If you want to prevent it than you have to made setting changes in browser
Turning Off Autofill in Chrome
Click the Chrome menu icon. (Three dots at top right of screen.)
Click on Settings.
In the "Autofill" section, expand the area for which you wish to disable Autofill.
Toggle the setting OFF if it is on. The system will automatically save your settings.
More details found here => https://support.iclasspro.com/hc/en-us/articles/218569268-How-Do-I-Disable-or-Clear-AutoFill-AutoComplete-Information-
So for html you can simply put autocomplete="new-password" in your
Auto-complete="off" can also be used nut it has some drawbacks.
Banks and other security institutes turn auto complete off .Problem is user change frequently their passwords and fields and use simple passwords to remeber.So auto complete is good feature in these cases.
But you can try this solution if you want .I hope it will work fine
<input type="password" autocomplete="new-password">
you can add autocomplete="off" to your form or input but many modern browsers do not support autocomplete="off" for login fields
but you can prevent it using autocomplete="new-password"
Preventing autofilling with autocomplete="new-password"
for more information check this link
https://developer.mozilla.org/en-US/docs/Web/Security/Securing_your_site/Turning_off_form_autocompletion#the_autocomplete_attribute_and_login_fields
Its most likely a bug, the solution I've found works best is to have auto-complete have a hard coded random value which will prevent a user from using auto-complete...
Try this:
<input type='password' name='pass' autocomplete='password' />
In terms of the auto-complete value you can have anything you want there.
New edit:
<script>
// Execute this code when page is
// totally loaded
$(document).ready(function () {
/* Setting the autocomplete of
input field to off to make
autofill to disable */
$("#name").prop("autocomplete", "off");
});
</script>

How does chrome detect login text boxes?

I have a textBox, that is supposed to get an url from an user.
Unfortunately, chrome autofills it with saved login name.
I would like to understand how chrome detects login input? How can I stop chrome filling this textbox?
My textbox does not have 'login' in Id or name. I could set autocomplete="off" or autocomplete = "false" for the input but I do not think it solves the problem. Tomorrow another textbox may be treated as login and I will have to redeploy code again. I need to prevent chrome thinking the input is a login textbox.
Instead of autocomplete="off" use autocomplete="false"
Setting the autocomplete attribute to "off" does not disable Chrome autofill in more recent versions of Chrome.

Firefox 26 showing credentials in suggestion for form fields

I'm using firefox 26. I have saved my credentials to my development site. And then i have used auto complete off feature. Following is my sample code
<form id="loginform" autocomplete="off">
<input name="username" type="text" autocomplete="off">
<input name="pwd" type="password" autocomplete="off">
</form>
Its worked fine for previous versions. After update to firefox 26, its not working. when i type first letter of my username, its showing saved credentials in suggestion. How to disable this?
Even i selected the suggested credentials, its auto fill the username and password field. But its not allowing to access site, showing login errors like enter password.
From: http://support.mozilla.org/en-US/kb/control-firefox-automatically-fills-in-forms#w_prevent-firefox-from-storing-form-entries
If you don't want Firefox to remember what you've entered into form fields, you can turn off the auto form fill feature:
On the menu bar, click on the Firefox menu and select Preferences...
.
Select the Privacy panel.
Set Firefox will: to Use custom settings for history.
Remove the check mark from the box that says Remember search and form history.
Close the Preferences window .
Disabling form history also prevents Firefox from storing search history for the Search bar in the Navigation Toolbar.
Clearing form history
If you want Firefox to forget all of your previous form entries:
On the menu bar, click on the History menu, and select Clear Recent History….
In the Time Range to clear: drop-down, select Everything.
Click the arrow next to Details to display the list of items that can be cleared.
Make sure only Form & Search History is check marked.
Click Clear Now. The dialog box will disappear and your form history will be erased.
Prevent Firefox from storing form entries
In some browsers you may need to activate an autocomplete function for this to work, or deactivate by unchecking its relative checkbox. (Look under "Preferences" in the browser's menu. This feature is in the control of user. At least in the current time.

Tabbing does not work in a chrome extension

I am trying to build a simple login form in a chrome extension. In my popup.html, I have a few input fields that have their corresponding tabindex values set. The username field has the autofocus property set through HTML or $('#myelement').focus() (I've tried both methods).
For some reason, tabbing does not work on my form when I first click the button next to the omnibar to open the popup. The username field has focus, but pressing the tab key makes the cursor disappear. It only shows up again if I explicitly click one of the input fields and then tab over, but never when they popup first opens.
<input type="text" id="one" tabindex=1 autofocus />
<input type="text" id="two" tabindex=2 />
If I open popup.html in a web browser (and not the extension), I've noticed that the tabbing in my form works perfectly.
This is a regression, which has a bug filed here. Unfortunately it has been around for quite some time now, and there doesn't seem any progress on it.
There is no known scriptable workaround for this bug.