Jeanluca Scaljeri
Jeanluca Scaljeri

Reputation: 29097

Prevent popup in Firefox if username/password are in URL

If you have a site protected with Basic authentication, you can automatically login if you add the username and password to the url

http://foo:bar@localhost

However, in Firefox, you will still get a popup

enter image description here

Is there a way in firefox to tell it not to show this dialog. For example, I can imagine that there is a setting inside the Profiles section to trust this site (which might solve this problem). Any help would be appreciated!

UPDATE: After a bit more searching I discovered that it might be possible with network.http.phishy-userpass-length, But when I check this in about:config I can't find it. So possibly this options has been removed

Upvotes: 3

Views: 2584

Answers (2)

andrew_laser
andrew_laser

Reputation: 39

The possibility to use login credential in the URL has been deprecated in Firefox:

https://username:[email protected]/

See https://developer.mozilla.org/en-US/docs/Web/HTTP/Authentication#access_using_credentials_in_the_url

Upvotes: 0

chloesoe
chloesoe

Reputation: 453

Just ran over that question and it helped me. So here the solution, if someone else has the same issue:

  1. open about:config in Firefox (confirm the message)
  2. right mouse on the list: New - Integer
  3. Set property name network.http.phishy-userpass-length
  4. Set Value to 255
  5. restart Firefox

Upvotes: 5

Related Questions