10

I regularly need to fill in a form on our intranet but the devs for an unknown reason have disabled autocomplete on some of the text fields. This means I have to repeatedly type in entries.

I have asked them to disable autocomplete=off but they are ignoring me.

Is there a way to make the browser (Chrome) override the autocomplete=off so it can then remember my previously typed entries in an autocomplete selection list.

I have tried various extensions (Autofill, RoboForm) but I cant get them to do this somewhat simple thing. ChatGPT suggested I use the extension "Ignore X-Frame-Options Header" but still no luck

TripToBelize
  • 115
  • 1
  • 7
  • I believe there have been several security vulnerabilities/exploits that work using autocomplete. The devs are probably simply applying proper security practices. – Bakuriu May 11 '23 at 18:23
  • No they are not because it is enabled on other string fields – TripToBelize May 31 '23 at 12:23

2 Answers2

7

The following Chrome extensions could help :

Force Autocomplete

Force autocomplete attribute in input fields to be on.

Force "autocomplete" attribute in input fields to be "on". Allows form fields to remember what you typed the next time you re-visit them.

Always Autocomplete

Changes webpage elements' autocomplete to be on. It helps you with enabling autofill feature for disabled web sites.

This extension automatically changes webpage elements' autocomplete to be on. It helps you with enableing autofill feature for disabled web sites. E.g. A website doesn't want the browser to remember your user name and password, now you have a choice there.

I would suggest not enabling the extension when consulting sensitive websites, such as your bank account.

harrymc
  • 455,459
  • 31
  • 526
  • 924
  • 2
    Force Autocomplete is open-source and so simple you can understand how the entire thing works even if you don't know js well in under 5 minutes. I think it's safe to use even in sensitive contexts. https://github.com/numediaweb/nw_force_autocomplete – ScottishTapWater May 10 '23 at 17:51
  • 1
    @ScottishTapWater It's possible they could have a "security" mechanism that detects changes to the page contents. Also, even if the extension is open source, you have to make sure the extension actually matches the source code, and that nothing malicious ever gets added. – Solomon Ucko May 11 '23 at 12:32
  • The worst thing that could happen in that regard is that the bank would pop a message up asking you to disable your extensions... That being said, I'm constantly running exceptions that change page content and I've never encountered any issue... – ScottishTapWater May 11 '23 at 12:33
5

You can use any extension that enables scripting specific websites, such as Tampermonkey, and use this or similar script:

let fields = document.querySelectorAll('[autocomplete="off"]');

[...fields].forEach((field) => {
  field.removeAttribute('autocomplete');
});

This finds all elements with autocomplete="off" HTML and removes the attribute from them. You can limit the script to a specific URL with the // @match metadata comment - e.g.:

// @match *.superuser.com/*

and also limit the HTML selector further if needed.

user985366
  • 105
  • 5
Destroy666
  • 5,299
  • 7
  • 16
  • 35
  • Thanks, tried it but I can't get it to work, when I inspect the HTML element it still shows autocomplete=off, although the Tampermonkey icon shows it has access to the site. My script is in next comment – TripToBelize May 10 '23 at 09:10
  • `// ==UserScript== // @name AutoComplete On // @namespace http://tampermonkey.net/ // @version 0.1 // @description try to take over the world! // @author You // @match https://.net // @icon data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw== // @grant none // ==/UserScript== let fields = document.querySelectorAll('[autocomplete="off"]'); [...fields].forEach((field) => { field.removeAttribute('autocomplete'); });` – TripToBelize May 10 '23 at 09:10
  • 1
    Not too sure your matching is correct, that matches only the main domain, no subpages. Did you check if the script runs? You do that by checking the extension's icon next to address bar. It might also be that the values are added later. Hard to say without looking at the code of the webpage. – Destroy666 May 10 '23 at 16:15