-
Notifications
You must be signed in to change notification settings - Fork 62
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
Should a RS require user consent to use scripting? #2321
Comments
cc @bduga |
#2297 has this:
If a book comes straight from the vendor's store to the RS, do we want to worry users every time or do we trust that vendors are vetting their content? |
I'm not really sure. Vetting scripts is hard, and I expect it would be entirely possible for bad actors to insert malicious code into some epubs without the epub creator being aware of it. That said, do we want to become the "accept all cookies" of the publishing world? We could add a comment along the lines of "Even content that comes directly from a known party could contain malicious code and Reading Systems MAY want to allow users to treat such content as untrusted, for example by allowing users to disable scripts and network access. Whether such controls are provided is left to the Reading System implementor, as is their specific design (e.g. allowing per-source controls, global settings, etc)." |
Ya, that also worries me, but I actually read the request here to warn the user after they've paid for the book as they download it to their reading system. That strikes me as a strange time to inject the warning. It seems like a warning you should get before purchasing, but then we're really going far afield from epub content or reading systems. I'd be fine with recommending that reading systems allow scripting to be disabled for all/individual publications. We already recommend that for network access, and scripting seems like the lesser of the two evils. I can disable scripting in my browser, so why not for publications? |
I would be fine with that, but this would really work if I, as a user, knew that there is scripting in the publication in the first place. I wonder whether it is realistic to say that RS-s might consider giving a visual clue when a publication includes scripting (just like my mac has a small light on the menubar if there is a recording going on). That, plus the possibility to turn scripting off, might be enough, and that avoids the "accept all cookies" effect... |
That's probably more reasonable than an alert every time a book is loaded into a reading system, but on the flip side we're getting into the UI which we've generally avoided doing. |
I like the option to disable scripting for all publications. But indeed, most users won't be aware of scripting, unless there's an explicit indication. Another option would be to disable scripting by default, so the user is required to explicitly enable it through the RS's settings if they want to. To me, this especially makes sense because the majority of publications do not seem to embed scripts (please correct me if I’m wrong!). Consequently, EPUB creators wanting to embed scripts, could just still do so and additionally include <noscript>
This publication employs scripts, please enable scripting in your reading application
or use an application that supports scripts.
</noscript> Other than the somewhat increased user friction, there's still a downside from a security perspective as well. Once a user enables scripting because of one publication requiring it, all other publications loaded afterwards will be able to silently execute scripts, unless the user disables scripting again. |
Alas! That won't work. AFAIK, |
I believe this depends on the type of publishing. For trade fiction, no, but for educational material scripting is more common. Maybe some of the vendors here have general numbers on how much scripting there is in the content they distribute.
Yes, it not only doesn't work but isn't valid in XHTML. The answer doesn't have to be never to warn users, but the requirement should allow flexibility for reading systems to adapt their interfaces to user preferences. If I'm not worried about scripting and don't care about warnings, maybe there's an "accept all" option that disables the warning. Going over this discussion so far, and just mulling the problem generally, it seems like there are a number of recommendations that could be needed:
Not suggesting we have to implement all of the above, but getting consent and making sure users know what is going on is a multi-faceted problem. |
The issue was discussed in a meeting on 2022-06-09 List of resolutions:
View the transcript4. Should a RS require user consent to use scripting?.See github issue epub-specs#2321. Wendy Reid: mixed feelings. Yes we should be asking for user consent if the script is taking info out of the epub, but i've seen more epubs that use js innocuously to animate things, and I don't want to scare users. Dave Cramer: we use it in cookbooks to make a timer in the corner. Brady Duga: what about tracking external media on every page? No scripting is involved, but no consent there?. Matt Garrish: the network activity part of it is the more dangerous thing. Dave Cramer: it leads to the web situation where 100x a day you get a cookies pop-up. Wendy Reid: it is worth having something about this, because it is a true threat. Dave Cramer: what do we have on network activity right now?. Wendy Reid: nothing specific. Ben Schroeter: how would you word it so that your average user would really understand what they are consenting to? "Network activity"? I wouldn't expect people to understand.
Wendy Reid: like the MacOS approach: "always load links from this source" sort of thing. Brady Duga: but a Zoom link, for example, is the user clicking on a link. What if the user just turns a page and a video auto-plays?. Wendy Reid: we have recommendation re. consent to network access. Dave Cramer: going stricter than what we have could be hard.
Brady Duga: it's not that user consent to scripting goes too far, it's that the real threat is network activity. |
This came up at the discussion with @GJFR at the EPUB meeting: should we advise Reading Systems (e.g., in §15.3) to ask for user's consent before accepting a publication that uses scripting?
The text was updated successfully, but these errors were encountered: