luci-base: ui.js: set autocomplete="new-password"
for password fields
Attempt to prevent Firefox from randomly filling nonesense into arbitrary password fields such as the WireGuard private key field by setting the `autocomplete="new-password"` attribute on any password type fields. Signed-off-by: Jo-Philipp Wich <jo@mein.io>
This commit is contained in:
parent
a4a4273ca4
commit
23a246e4b4
1 changed files with 1 additions and 0 deletions
|
@ -374,6 +374,7 @@ var UITextfield = UIElement.extend(/** @lends LuCI.ui.Textfield.prototype */ {
|
|||
'disabled': this.options.disabled ? '' : null,
|
||||
'maxlength': this.options.maxlength,
|
||||
'placeholder': this.options.placeholder,
|
||||
'autocomplete': this.options.password ? 'new-password' : null,
|
||||
'value': this.value,
|
||||
});
|
||||
|
||||
|
|
Loading…
Reference in a new issue