Anyone know how to write a surrogate script?

Ask for help about NoScript, no registration needed to post
harryray2
Posts: 16
Joined: Wed Mar 08, 2017 4:53 pm

Anyone know how to write a surrogate script?

Post by harryray2 »

Anyone know how to write a surrogate script?
Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:55.0) Gecko/20100101 Firefox/55.0
barbaz
Senior Member
Posts: 10847
Joined: Sat Aug 03, 2013 5:45 pm

Re: Anyone know how to write a surrogate script?

Post by barbaz »

Create two preferences in about:config, replacing <name> with the name of your surrogate:

right-click > New > String
name:

Code: Select all

noscript.surrogate.<name>.replacement
value is either the JS code, or a file: URL pointing to the .js file to run

right-click > New > String
name:

Code: Select all

noscript.surrogate.<name>.sources
value is the URLs to run the surrogate at, specified as a URL pattern with the same syntax as ABE resources (but no special tokens. See ABE Rules .pdf for details.) Depending what type of surrogate you're writing and when you want the surrogate to run, you can add a prefix to this value as explained in the surrogate script article.
*Always* check the changelogs BEFORE updating that important software!
-
harryray2
Posts: 16
Joined: Wed Mar 08, 2017 4:53 pm

Re: Anyone know how to write a surrogate script?

Post by harryray2 »

I've tried writing the script but I can't seem to get this to work, the site I'm trying to write a surrogate for is primewire.unblocked.vc Trying to stop the cloudflare page stopping me accessing the site telling me that I have to enable javascript
Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:55.0) Gecko/20100101 Firefox/55.0
barbaz
Senior Member
Posts: 10847
Joined: Sat Aug 03, 2013 5:45 pm

Re: Anyone know how to write a surrogate script?

Post by barbaz »

harryray2 wrote: the site I'm trying to write a surrogate for is primewire.unblocked.vc Trying to stop the cloudflare page stopping me accessing the site telling me that I have to enable javascript
Again, please stick to https://forums.informaction.com/viewtop ... =7&t=24297 for this issue. As noted in Forum Rules #8, spreading a single issue across multiple threads makes it needlessly difficult to help you.
*Always* check the changelogs BEFORE updating that important software!
-
harryray2
Posts: 16
Joined: Wed Mar 08, 2017 4:53 pm

Re: Anyone know how to write a surrogate script?

Post by harryray2 »

Still have problem with this...Can anyone help?

Thanks.
Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:55.0) Gecko/20100101 Firefox/55.0
Post Reply