Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

What kind of permission screen(s) should the user see? (To avoid spamming and spoofing) #1

Open
ArthurSonzogni opened this issue Feb 8, 2021 · 9 comments

Comments

@ArthurSonzogni
Copy link

I understand this is still not fully defined, so it might be hard to give a precise answer.

I would like to know what kind of permission screen the user will have to approve before adding new icons. It seems vital the icon and name are present when the prompt is presented to the user. Otherwise, there are risk of spoofing.

Some question, mostly taken from the security/privacy review preparation:

  1. Do we show a new prompt for every individual icon?
  2. Did you considered throttling requests and then make a "group" prompt?
  3. How would we make the prompt repeatable for every icon, but not spammable?
  4. Does the decision to block an icon remains permanent?
  5. How would users revisit a decision to block an app from adding an additional icon?
  6. Would PWAs know which icons have been blocked by the users so they can stop asking for those icons?
  7. Is there a limit? Can we add 1000 icons in a single request?
  8. Does updating one icon is subject to a "revalidation" via a prompt from the user?
  9. Asking too many things to the user might lead to prompt fatigue. Some might auto-pilot after the 3rd prompt. We are wondering how this could be avoided.

+CC @Sauski, @andypaicu, @amtunlimited, @ArthurSonzogni

@ivansandrk
Copy link
Owner

ivansandrk commented Feb 10, 2021

Hi Arthur, thanks for chiming in!

As mentioned in the "Security & Privacy considerations" section in the explainer, we would prompt the user for adding new icons, and this prompt would include both the icon and the name of what is being added.

  1. Do we show a new prompt for every individual icon?

Yes.

  1. Did you considered throttling requests and then make a "group" prompt?

It did cross my mind, but that would significantly complicate the feature; we could though have a regular add(), and in addition also have a batchAdd() if it turns out it's needed.

  1. How would we make the prompt repeatable for every icon, but not spammable?

Can you explain this in bit more details?

  1. Does the decision to block an icon remains permanent?

No.

  1. How would users revisit a decision to block an app from adding an additional icon?

N/A (previous answer).

  1. Would PWAs know which icons have been blocked by the users so they can stop asking for those icons?

Yes naturally. We expect to have a mechanism that notifies the app of the success status; most likely return codes.

  1. Is there a limit? Can we add 1000 icons in a single request?

At this point we weren't planning on implementing a batch approach, but that can be done if necessary and throttled at say 10 icons per request.

  1. Does updating one icon is subject to a "revalidation" via a prompt from the user?

This can mean two different things:

  1. The app calls an update() on the icon - the user would be prompted again;
  2. If we implement the feature with the technical approach that seems most viable atm (shortcuts as main app literally installing its sub apps) then whenever the manifest of the "added icon" (installed sub app) gets updated, that "icon" would be updated as well in the exact same way how installed web apps are usually updated when their manifest gets updated.
  1. Asking too many things to the user might lead to prompt fatigue. Some might auto-pilot after the 3rd prompt. We are wondering how this could be avoided.

I wouldn't know what to do about it. Do you have any suggestions? If anything, I don't think this will be a big issue in practice. In addition, we're mostly expecting enterprise partners to use this API, and in enterprise environments we will allow the admins to override the prompt via policy so users won't have to worry about being spammed.

@ArthurSonzogni
Copy link
Author

Thanks for those answers!

What you have in mind is a new permission prompt for every individual icons. The most important part is requiring the user to validate and "see" any new icon and icon name. It shouldn't be easy to spoof other applications. This shouldn't depend on the number of new icons, or whether this is an update or not.
From your answers this seems to be the case. Good!

If we implement the feature with the technical approach that seems most viable atm (shortcuts as main app literally installing its sub apps) then whenever the manifest of the "added icon" (installed sub app) gets updated, that "icon" would be updated as well in the exact same way how installed web apps are usually updated when their manifest gets updated.

How does it works today when the manifest file is updated? I just read:
https://web.dev/manifest-updates/#cr-desktop
It seems you can change the icon, without the user being prompted again. You can do it for the icon, but not the icon name.
Is this correct? If yes, then this looks worrying to me, because a website seems to be able to spoof other application this way.

Asking too many things to the user might lead to prompt fatigue. Some might auto-pilot after the 3rd prompt. We are wondering how this could be avoided.

I wouldn't know what to do about it. Do you have any suggestions?

I don't know either. I am just copying an interesting potential question from two other persons in CC, maybe they have some suggestions?

@ivansandrk
Copy link
Owner

If we implement the feature with the technical approach that seems most viable atm (shortcuts as main app literally installing its sub apps) then whenever the manifest of the "added icon" (installed sub app) gets updated, that "icon" would be updated as well in the exact same way how installed web apps are usually updated when their manifest gets updated.
How does it works today when the manifest file is updated? I just read:

https://web.dev/manifest-updates/#cr-desktop
It seems you can change the icon, without the user being prompted again. You can do it for the icon, but not the icon name.
Is this correct? If yes, then this looks worrying to me, because a website seems to be able to spoof other application this way.

It might or might not be a problem.

If it is, then the problem doesn't exist only for this particular feature, but it exists in general for any installed PWA, and should be solved for the general case.

And if it's not a problem for the general case, then it also isn't a problem for this particular feature since it's not really any different.

@andypaicu
Copy link

andypaicu commented Feb 16, 2021 via email

@ivansandrk
Copy link
Owner

Hey Andy, thanks for commenting and sharing your thoughts!

#1 There's no functional difference really if you have many PWAs installed and any one of them could sneakily change its icon to something else compared to what this feature is adding. I'll reiterate - if you think this is a problem then you should solve it at the global PWA level, and not special-case this particular feature. Once it's solved there, it will naturally propagate also here as the technical idea behind this feature is in essence "installing" the sub-apps using the same already available infrastructure. Changing that would be very painful and in my opinion unnecessary additional work.

#2 I understand your concerns around spamming the user, but I wouldn't consider them a real issue. I, as a user, expect that my apps are well behaved and I trust the developers of the applications I use to be considerate of this. In the rare case that they aren't, it's easy to just not use them / remove them. As a data point here - I've been using computers since ~1995' (25 years) and I must say I can't even remember if any of the apps that were natively installed on my computers have misbehaved, much less done malicious things, and they had much more power than PWAs have these days.

@andypaicu
Copy link

andypaicu commented Feb 17, 2021 via email

@dmurph
Copy link

dmurph commented Feb 18, 2021

Hello!

Chiming in here regarding the current state of web app updatability - we allow the web app to update their icons, but we do NOT allow the name to be updated. This was seen as a phishing security risk. I think that @michaelwasserman is doing some work here to help prevent possible phishing here even more.

One reason why updatable icons is more understandable than an updatable name is that developers developers often will launch or test with bad / not quite HD icons, and then need to update them later.

This security decision was before my time on the team, but I can try to look up this review. @mgiuca might also have info here on the top of their head

@ivansandrk
Copy link
Owner

@andypaicu

  1. I spent some time digging around the original issue and it will be fixed at the origin (ie. there will be either a warning when the icon changes, or this will be disabled completely).

  2. Fair enough, I see your point. What do people usually do in this domain?

Thanks,
Ivan

@ArthurSonzogni
Copy link
Author

ArthurSonzogni commented Feb 24, 2021

  1. I spent some time digging around the original issue and it will be fixed at the origin (ie. there will be either a warning when the icon changes, or this will be disabled completely).

Nice! I am happy to see the root cause will be fixed at the origin! Do you have some bugs referencing this? This is the path forward I am the most comfortable with.
I was about writing a doc discussing what would be the other options like fixing revalidation only for multi-apps at the cost of inconsistencies or whether we can afford temporarily not to have this bug fixed. If you can fix the issue at the root, that's ideal!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants