News for hackers. Stuff that matters.
Re:Et Tu, Grammarly? by dbushell on Saturday March 29, 2025 @06:27AM (#43514309)
How do you deal with hostile browser extensions?
Re:Et Tu, Grammarly? by WJW on Saturday March 29, 2025 @07:36AM (#43514670)
Uninstall them?
Re:Et Tu, Grammarly? by dbushell on Saturday March 29, 2025 @07:55AM (#43514789)
If only I could opt-out, disable, or uninstall those used by visitors to my website when the extension breaks it :(
Re:Et Tu, Grammarly? by diggan on Saturday March 29, 2025 @08:30AM (#43515010)
Not much you can do, user agents continue to act as agents for the users, meaning you can serve them stuff but beyond that it's up to them to dictate their experience, for better or worse.

It really sucks when extensions do fudgy stuff in global space and sometimes break your stuff though, agree. Best approach I've found is to have a help page you can link to so people can go through the typical steps of "disabling all extensions, clearing cache, etc, etc" when things break in very unexpected way and you find no causes for it.

Re:Et Tu, Grammarly? by dbushell on Saturday March 29, 2025 @08:45AM (#43515107)
Indeed. It's the user's browser and experience, it's not up to the website owner. But it's frustrating to get bug reports when a 3rd party extension is the problem, not the website. Many visitors will just bounce blaming the website too.
Re:Et Tu, Grammarly? by ziml77 on Saturday March 29, 2025 @10:21AM (#43515786)
Without someone pointing the user to what the issue is, it's very difficult for the user to know it's an extension causing the problem.

Many years ago I had performance issues with a site and the only reason I knew it was due to an extension is I dug into it with the dev tools and managed to identify Dashlane as the problem.

Re:Et Tu, Grammarly? by netsharc on Saturday March 29, 2025 @08:31AM (#43515016)
I guess you could figure out valid states for your page's DOM, and a few seconds after the page has finished loading, scan it for "hostile" elements and CSS styles, and delete them...

Having this idea and opening a random page (from The Guardian) on DevTools, somehow somebody's inserted scripts and iframes pointing to twitter.com.

Re:Et Tu, Grammarly? by kelvinjps10 on Saturday March 29, 2025 @05:24PM (#43518857)
But wouldn't you brake their extensions if the user wanted them to work?
Re:Et Tu, Grammarly? by eadmund on Saturday March 29, 2025 @08:36AM (#43515058)
I don’t think that ‘hostile’ is really fair in this case, when ‘insufficiently competent’ will do (albeit at the cost of more syllables).

I am not a fan of Grammarly or their technical model, but I don think it’s fair to attribute malice when it is adequately explained by stupidity.

It’s been a long time since I did any front-end work: should both Grammarly’s extension and your own code use namespaced property names?

Re:Et Tu, Grammarly? by chuckadams on Saturday March 29, 2025 @11:55AM (#43516464)
Any sufficiently advanced stupidity is indistinguishable from malice.
Re:Et Tu, Grammarly? by QuadmasterXLII on Saturday March 29, 2025 @11:29AM (#43516294)
We tried applying cunningham’s law widely and it created disastrous incentives. It’s better to assume profitable yet destructive incompetence is malice.
Re:Et Tu, Grammarly? by dbushell on Saturday March 29, 2025 @08:42AM (#43515091)
yep, it's in Grammarly's interest to namespace or scope their CSS in a way that doesn't conflict. Not doing it adequately goes both ways, website CSS could break their extension, or their extension could break the website.
Re:Et Tu, Grammarly? by MartijnHols on Saturday March 29, 2025 @01:05PM (#43516925)
Unfortunately browsers don't really provide good solutions for extensions that need to inject or change sites. Look at Google's owner in-browser translate extension, its DOM manipulation breaks many interactive apps as well. There are no tools available in browsers for it to not need to do that.
Re:Et Tu, Grammarly? by amelius on Saturday March 29, 2025 @11:25AM (#43516270)
At this point, I'm not installing any browser extensions, period.
Re:Et Tu, Grammarly? by gs17 on Saturday March 29, 2025 @11:32AM (#43516317)
OP's problem wasn't that they had it installed, it's that enough of their users did to make it a problem when it breaks the site's CSS.
Re:Et Tu, Grammarly? by bmacho on Saturday March 29, 2025 @11:53AM (#43516454)
Browser extensions are the equivalent of running random .exe on your computer except that you have to trust every vendor protecting their keys forever due to the autoupdate.
Re:Et Tu, Grammarly? by bufferoverflow on Saturday March 29, 2025 @11:57AM (#43516480)
But our users do.
Re:Et Tu, Grammarly? by silvestrov on Saturday March 29, 2025 @12:41PM (#43516755)
The biggest problem with browser extensions is that the source code (both css and javascript) is not easy to read/check.

There should be an easy "view source" for extensions inside Chrome and extensions should be mandated to ship non-minimized code.

Re:Et Tu, Grammarly? by kelvinjps10 on Saturday March 29, 2025 @05:25PM (#43518863)
Not even ublock?
Re:Et Tu, Grammarly? by Doctor_Fegg on Saturday March 29, 2025 @11:58AM (#43516486)
Ah, my favourite complaint for the community website I run. "I can't see any photos on the adverts page." Are you running an ad-blocker? "Yes." What do you think an ad-blocker does...