Live data from Hacker News

Mozilla shouldn't copy Chrome's permission prompt for extensions

palant.de

1–10 of 77 posts

Re: Mozilla shouldn't copy Chrome's permission prompt for extensions

#2
It sounds like a case of overly broad permissions. Have they looked at other permissions models?

For one, extensions should be able to include an explanation why they need each permission.

Network access should be a separate permission like it is for iOS keyboards. It's safer for an ad blocker to read and modify a page if it has no method of exfiltrating the content. Blacklist updates can be done through the regular extension update mechanism.

Looking at the list of permissions in the documentation, a lot of these look like they should be asked for at the time of first use (location, clipboard, screenshots, etc). This would avoid the problem of asking for overly broad permissions upfront "just in case". Android had the same problem.

But in the end, not informing the user is the wrong choice, no matter how bullet-proof you think your vetting process is. You'll always have users who are paranoid (as developers of a camera app on iOS, we've had 1-star reviews left because our app "uploads all your photos to the internet" because we need photo library access) and it's their loss mainly, not yours.

Re: Mozilla shouldn't copy Chrome's permission prompt for extensions

#3
post #2

It sounds like a case of overly broad permissions. Have they looked at other permissions models? For one, extensions should be able to include an explanation why they need each permission. Network access should be a separate permission like it is for iOS keyboards. It's safer for an ad blocker to read and modify a page if it has no method of exfiltrating the content. Blacklist updates can be done through the regular…

> It's safer for an ad blocker to read and modify a page if it has no method of exfiltrating the content.

The problem is that being able to modify the page is a method of exfiltrating information - e.g. you can add an img tag triggering a GET to an arbitrary URL. I suspect it would be surprisingly tricky to try restricting page modification in such a way that information can't be sent anywhere the page wouldn't have sent it originally.

But +1 on deferring permissions prompts until the moment the app actually needs the privilege, though. It's worked pretty well on iOS, and it's finally coming to Android - maybe it'll come to Chrome or Firefox next.

Re: Mozilla shouldn't copy Chrome's permission prompt for extensions

#4
As extension developer, it is easier to request "Access all web sites data" at the beginning. The alternative for using optional (host origin) permissions have to deal with complex UI workflows and often ask user to grant permission that is already granted - due to Chrome bug not fixes for years[1].

1. https://bugs.chromium.org/p/chromium/issues/detail?id=310815

Re: Mozilla shouldn't copy Chrome's permission prompt for extensions

#5
I don't agree with the article at all.

Chrome is being completely honest with the user. If a youtube extension asks permission to "read data from all websites" you must ask yourself and the developer why it needs access to all websites and not just youtube. A good extension must enumerate all the permissions it demands and give good reasons why it needs each of them. If an extension seeks new permissions, then consent must be sought from the user before update . This is obviously the correct approach(How it affects the extension developer's revenue\user-adoption is unimportant). Chrome's model is comparable to the security model of Android and iOS. Sure its not perfect, But its much better than the firefox model which is comparable to Windows 98.

Also i don't understand the whole shifting of responsibility jibe. Does Mozilla review every extension and every update in their store? Do they accept responsibility if malicious code is downloaded from their store?

To conclude , i would like firefox's stringent app review process and chrome's fine-grained permissions and sandbox model.

Edit: I want to point out that this article is really looking after the interests of the developer, and not after the interests of the user.

Edit 2 : Also to add: Sandboxing is simply good security practice. Even if the author is not malicious, but in case an extension is exploited due to a bug, the damage done by a well-sandboxed extension is limited by the permissions granted. In firefox such an exploit could hoover all your data, credit card info & passwords from all your websites and data from you harddrive as well.

Re: Mozilla shouldn't copy Chrome's permission prompt for extensions

#6
post #5

I don't agree with the article at all. Chrome is being completely honest with the user. If a youtube extension asks permission to "read data from all websites" you must ask yourself and the developer why it needs access to all websites and not just youtube. A good extension must enumerate all the permissions it demands and give good reasons why it needs each of them. If an extension seeks new permissions, then consen…

> Chrome is being completely honest with the user.

The article is not advocating otherwise.

A lot of extensions need that permission, even though they only need it to do something much more specific. Adblock uses it to read (but not transmit) your webpages, and remove sections. Password managers use it to scan (but not transmit) webpage content, and fill certain form fields.

If there is a review process (which Firefox already has in place), then you can actually give out permissions like this. You can ensure that the data read from the webpage is never sent to the server, and useful things like that.

I believe the proposal for webextensions in Firefox is to have certain kinds of extensions get auto-approved, the ones which need simple, sandboxable permissions (not "read all my webpages"). Extensions that need more permissions will need review, and they can request semantic permissions instead of just "give me all your data and trust I don't do anything bad with it", which is bad and has already lead to issues in the past where a Chrome extension developer sells their extension which is then used to transmit malware.

> To conclude , i would like firefox's stringent app review process and chrome's fine-grained permissions and sandbox model.

The article is proposing finer grained permissions than Chrome.

Re: Mozilla shouldn't copy Chrome's permission prompt for extensions

#7
post #2

It sounds like a case of overly broad permissions. Have they looked at other permissions models? For one, extensions should be able to include an explanation why they need each permission. Network access should be a separate permission like it is for iOS keyboards. It's safer for an ad blocker to read and modify a page if it has no method of exfiltrating the content. Blacklist updates can be done through the regular…

> Have they looked at other permissions models?

I believe that's the idea. To make the permissions more finer grained. However, that crosses the line of what can be automatically enforced by sandboxing -- chrome's permissions model is defined by what they can restrict via software. To make it more finer-grained, you need a review process, which Firefox has.

Re: Mozilla shouldn't copy Chrome's permission prompt for extensions

#8
post #5

I don't agree with the article at all. Chrome is being completely honest with the user. If a youtube extension asks permission to "read data from all websites" you must ask yourself and the developer why it needs access to all websites and not just youtube. A good extension must enumerate all the permissions it demands and give good reasons why it needs each of them. If an extension seeks new permissions, then consen…

The article does make a good point regarding warning fatigue, which was one of the main reasons why Android is moving towards a permission system similar to what iOS does, i.e. ask for permission only when needed, and degrade gracefully if the permission is not granted. The previous system of showing a gigantic list of required permissions probably caused most users to a) blindly accept the permissions or b) not install some apps out of fear.

That model is probably not that good a fit for browser extensions. There might be a couple of permissions where this would work, but the biggest issue is definitely the "Read and change all your data on the websites you visit." permission, and that's not really something you could work around with using on-demand prompts. The idea of combining code reviews with an explanation of the required permissions provided by the developer and vetted by the reviewers sounds interesting, but it's not clear to me whether a model like that would work in practice.

Re: Mozilla shouldn't copy Chrome's permission prompt for extensions

#9
post #3
post #2

It sounds like a case of overly broad permissions. Have they looked at other permissions models? For one, extensions should be able to include an explanation why they need each permission. Network access should be a separate permission like it is for iOS keyboards. It's safer for an ad blocker to read and modify a page if it has no method of exfiltrating the content. Blacklist updates can be done through the regular…

> It's safer for an ad blocker to read and modify a page if it has no method of exfiltrating the content. The problem is that being able to modify the page is a method of exfiltrating information - e.g. you can add an img tag triggering a GET to an arbitrary URL. I suspect it would be surprisingly tricky to try restricting page modification in such a way that information can't be sent anywhere the page wouldn't have…

That's a good point about modifying the page. It could probably be done but there are a LOT of edge cases in there that will be easy to overlook and it would become a constant source of security bugs.

edit: since content blockers in particular are so popular, it might even make sense for them to create a security-conscious content blocker specific API like Apple did

Re: Mozilla shouldn't copy Chrome's permission prompt for extensions

#10
post #5

I don't agree with the article at all. Chrome is being completely honest with the user. If a youtube extension asks permission to "read data from all websites" you must ask yourself and the developer why it needs access to all websites and not just youtube. A good extension must enumerate all the permissions it demands and give good reasons why it needs each of them. If an extension seeks new permissions, then consen…

> Chrome is being completely honest with the user. The article is not advocating otherwise. A lot of extensions need that permission, even though they only need it to do something much more specific. Adblock uses it to read (but not transmit) your webpages, and remove sections. Password managers use it to scan (but not transmit) webpage content, and fill certain form fields. If there is a review process (which Firefo…

>A lot of extensions need that permission, even though they only need it to do something much more specific. Adblock uses it to read (but not transmit) your webpages, and remove sections. Password managers use it to scan (but not transmit) webpage content, and fill certain form fields.

Yes. But the user should be made aware of the consequence of their action. Do they realize that installing a password manager means granting access to all their data to a third party. Is this author reliable? What do other users think of the author? Has anyone reviewed the code for this? These are all questions potential users should ask.

>they can request semantic permissions instead of just "give me all your data and trust I don't do anything bad with it", which is bad and has already lead to issues in the past where a Chrome extension developer sells their extension which is then used to transmit malware.

A lot of things cannot be controlled either by review process or sandboxing. What if your extension has a web-component ( say your password manager backs up passwords to the cloud)? Mozilla cannot review your server code. A sandbox won't protect resources you have already given access to, but it will limit the damage done.

>The article is proposing finer grained permissions than Chrome.

I have reread the article and haven't found anything that backs this assertion. Indeed the author seems to say : Mozilla vouches for me, so you trust me with all your stuff too. From article :

'Wouldn’t it be a better idea to keep doing that so that the installation prompt can simply say: “Hey, we made sure that this extension is doing what it says, want to install it?”'

Edit : I agree that some form of review is needed for extensions. Simple sandboxing alone is not enough. But article doesn't seem to support sandboxing.

Post reply on HN