Allow Youtube but need permissions in third-party sites

Ask for help about NoScript, no registration needed to post
ReporterX
Senior Member
Posts: 74
Joined: Mon Sep 15, 2014 11:46 pm

Allow Youtube but need permissions in third-party sites

Post by ReporterX »

How could I configure it so it is allowed to load in Youtube, but asks for permission to embed/load in third-party sites?
There will be a placeholder on each youtube embedding (on third-party sites) and you need to click to allow it to load.

I know it has an "apply these restrictions to whitelist sites too" option.
But it applies globally. I only want it for some websites only.
Thanks a lot. :)
Firefox 37.0.2, NoScript 2.6.9.22
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:32.0) Gecko/20100101 Firefox/32.0
barbaz
Senior Member
Posts: 11144
Joined: Sat Aug 03, 2013 5:45 pm

Re: Allow Youtube but need permissions in third-party sites

Post by barbaz »

Unfortunately, you're going to have to wait for NoScript 3 for that.
If you don't mind not having placeholders, you could use ABE like

Code: Select all

Site .youtube.com .ytimg.com .googlevideo.com
Accept from .youtube.com .ytimg.com .googlevideo.com
Deny INCLUSION(SCRIPT, OBJ, FONT, XHR, MEDIA, SUBDOC)
Sandbox
and add other domains to the Accept line as needed.
ReporterX wrote:I know it has an "apply these restrictions to whitelist sites too" option.
But it applies globally. I only want it for some websites only.
about:config -> noscript.allowedMimeRegExp
*Always* check the changelogs BEFORE updating that important software!
Mozilla/5.0 (Windows NT 5.1; rv:32.0) Gecko/20100101 Firefox/32.0 SeaMonkey/2.29
ReporterX
Senior Member
Posts: 74
Joined: Mon Sep 15, 2014 11:46 pm

Re: Allow Youtube but need permissions in third-party sites

Post by ReporterX »

Thanks for the reply. :D
Unfortunately what I want is "Ask per request" even in the same website that I would allow.
If I add the domain name to the "Accept from", it would be "Allow per site".

About noscript.allowedMimeRegExp, let's say I want to apply these restrictions to yahoo.com only (but not other whitelist sites).
What should I type? It does not seem like this pref could do this job. :|
Firefox 37.0.2, NoScript 2.6.9.22
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:32.0) Gecko/20100101 Firefox/32.0
barbaz
Senior Member
Posts: 11144
Joined: Sat Aug 03, 2013 5:45 pm

Re: Allow Youtube but need permissions in third-party sites

Post by barbaz »

ReporterX wrote:Thanks for the reply. :D
Unfortunately what I want is "Ask per request" even in the same website that I would allow.
If I add the domain name to the "Accept from", it would be "Allow per site".
That is what I answered wait until NoScript 3 :(

If you don't allow scripts on the third-party websites, and check all Embeddings (not necessarily "Apply these restrictions to whitelisted sites too") then I think NoScript will default display placeholders for youtube embeddings. It's when scripts are allowed on the 3rd-party site that you're stuck with either not having this or "Apply these restrictions to whitelisted sites too".
ReporterX wrote:About noscript.allowedMimeRegExp, let's say I want to apply these restrictions to yahoo.com only (but not other whitelist sites).
What should I type? It does not seem like this pref could do this job. :|
No, it can't act that way, because it's a whitelist of origin sites for plugin content, nothing to do with sites requesting the content.
Maybe ABE alongside that pref could do that, but again, I think the sort of feature you're looking for will likely be part of NoScript 3...
*Always* check the changelogs BEFORE updating that important software!
Mozilla/5.0 (Windows NT 5.1; rv:32.0) Gecko/20100101 Firefox/32.0 SeaMonkey/2.29
User avatar
Thrawn
Master Bug Buster
Posts: 3106
Joined: Mon Jan 16, 2012 3:46 am
Location: Australia
Contact:

Re: Allow Youtube but need permissions in third-party sites

Post by Thrawn »

You could also try FlashBlock. Just bear in mind that it's not as reliable as NS for security purposes.
======
Thrawn
------------
Religion is not the opium of the masses. Daily life is the opium of the masses.

True religion, which dares to acknowledge death and challenge the way we live, is an attempt to wake up.
Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:32.0) Gecko/20100101 Firefox/32.0
ReporterX
Senior Member
Posts: 74
Joined: Mon Sep 15, 2014 11:46 pm

Re: Allow Youtube but need permissions in third-party sites

Post by ReporterX »

Thrawn wrote:You could also try FlashBlock. Just bear in mind that it's not as reliable as NS for security purposes.
Thanks for your suggestion.

I see this line in the Flashblock page.

"Note: Flashblock does not work with Javascript disabled or with NoScript installed."

Too bad they are incompatible.
I prefer keeping NoScript. :D
Firefox 37.0.2, NoScript 2.6.9.22
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:32.0) Gecko/20100101 Firefox/32.0
barbaz
Senior Member
Posts: 11144
Joined: Sat Aug 03, 2013 5:45 pm

Re: Allow Youtube but need permissions in third-party sites

Post by barbaz »

I suspect Flashblock would work as expected on script-allowed sites, which is the missing feature you're looking for.
(Note that IIRC it doesn't prevent things from being downloaded; it's basically pressing "Pause" as soon as it can, which isn't always immediately. Check Giorgio's blog for more details.)
*Always* check the changelogs BEFORE updating that important software!
Mozilla/5.0 (Windows NT 5.1; rv:32.0) Gecko/20100101 Firefox/32.0 SeaMonkey/2.29
User avatar
therube
Ambassador
Posts: 7980
Joined: Thu Mar 19, 2009 4:17 pm
Location: Maryland USA

Re: Allow Youtube but need permissions in third-party sites

Post by therube »

I haven't thought it through, but click-to-play settings need not necessarily coincide between Mozilla & NoScript, so perhaps something along that end?
Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.1.19) Gecko/20110420 SeaMonkey/2.0.14 Pinball NoScript FlashGot AdblockPlus
Mozilla/5.0 (Windows NT 5.1; rv:32.0) Gecko/20100101 SeaMonkey/2.29
ReporterX
Senior Member
Posts: 74
Joined: Mon Sep 15, 2014 11:46 pm

Re: Allow Youtube but need permissions in third-party sites

Post by ReporterX »

therube wrote:I haven't thought it through, but click-to-play settings need not necessarily coincide between Mozilla & NoScript, so perhaps something along that end?
Do you mean the "plugins.click_to_play" pref?

It is true by default but it does not help.

Youtube will still load into the site (even though it isn't played automatically).
Firefox 37.0.2, NoScript 2.6.9.22
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:32.0) Gecko/20100101 Firefox/32.0
Post Reply