Allow scripts only if a specific website is visited

Ask for help about NoScript, no registration needed to post
E

Allow scripts only if a specific website is visited

Post by E »

Hi,

I have recently started to use NoScript. It is very very useful and because of NoScript, I switched to Firefox from Chrome.

Anyway, I sometimes visit IEEE website to look for some papers. It uses Google as its search engine. So I have to allow google.com. But if I allow google.com, when I actually visit google.com, NoScript automatically allows it. But in fact, I just want it to allow google.com when I visit IEEE. If I opted for "temporarily allow google.com", it would be annoying to do this task every time I visit the site. Any trick to handle this?

Thanks,
E
Mozilla/5.0 (Macintosh; Intel Mac OS X 10.10; rv:35.0) Gecko/20100101 Firefox/35.0
barbaz
Senior Member
Posts: 11143
Joined: Sat Aug 03, 2013 5:45 pm

Re: Allow scripts only if a specific website is visited

Post by barbaz »

if IEEE is including Google scripts:
http://noscript.net/faq#qa8_10
or wait for noscript 3

if they dump you on a google page, there's no perfect solution, best you can do atm is this:
Allow google.com, then
NoScript Options > Advanced > ABE > USER, add

Code: Select all

# Allow Google only when referred by IEEE
Site .google.com
Accept from .[IEEE's 2nd level domain]
Deny INC(SCRIPT, OBJ, FONT, XHR, MEDIA)
Sandbox
which would still allows google if you visit google directly from the address bar or search bar in your browser...
i don't know if noscript 3 will offer ability to control that
*Always* check the changelogs BEFORE updating that important software!
Mozilla/5.0 (X11; NetBSD i386; rv:28.0) Gecko/20100101 Firefox/28.0 SeaMonkey/2.25
E

Re: Allow scripts only if a specific website is visited

Post by E »

Thanks, barbaz

As you said, it still had to allow that domain. In case of google.com, it is frequently visited so when I visit it, I have to forbid it again.

As far as you know, is the situation common? Can we raise a request so that NoScript can include it in later versions?
Mozilla/5.0 (Macintosh; Intel Mac OS X 10.10; rv:35.0) Gecko/20100101 Firefox/35.0
barbaz
Senior Member
Posts: 11143
Joined: Sat Aug 03, 2013 5:45 pm

Re: Allow scripts only if a specific website is visited

Post by barbaz »

E wrote:when I visit it, I have to forbid it again.
why? Normal script blocking is independent of ABE. Unless you are visiting it from the address bar or a bookmark or something like that, script will be forbidden.

I haven't tested this, but what if you add immediately before the ABE rule I gave you,

Code: Select all

Site .google.com
Sandbox from ^(?!https?)[0-9A-Za-z-]+:
Does that affect script enabled status when google.com is Allowed in script blocking and visited directly from address bar?
E wrote:As far as you know, is the situation common?
I still don't know whether this is a Google page, or an IEEE page that just requires some Google script.
If the former (which I think you're implying), I've never done anything like that, and I haven't seen any threads here about that before...
If the latter... well, it's so common it's got a FAQ ;)
E wrote:Can we raise a request so that NoScript can include it in later versions?
You can if you register, just post your RFE as a new thread in NoScript Development (if someone else has already requested it, please bump their thread instead). However, in this case I'm not sure Giorgio would implement it. It's pointless from a security standpoint, and even from a privacy standpoint I'd think it doesn't offer much advantage if any since Google is still tracking your search terms *and* the fact you visit the IEEE site... so this is purely a 'make Google more usable' thing, and NoScript is a security tool not an accessibility tool..
*Always* check the changelogs BEFORE updating that important software!
Mozilla/5.0 (X11; NetBSD i386; rv:28.0) Gecko/20100101 Firefox/28.0 SeaMonkey/2.25
Satoshi

Re: Allow scripts only if a specific website is visited

Post by Satoshi »

You can minimize exposition to Google by using Startpage. Results are almost identical to Google (they actually come from Google).
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:35.0) Gecko/20100101 Firefox/35.0
Post Reply