Something like “decentraleyes” for Privoxy…
|
Jan. 01, 2017, 12:56 PM
(This post was last modified: Dec. 08, 2017 10:22 PM by Faxopita.)
Post: #1
|
|||
|
|||
Something like “decentraleyes” for Privoxy…
To roughly mimic “decentraleyes” Firefox add-on…
More info here or there. Quote:Decentraleyes is a new open source Firefox add-on that aims to improve your privacy while browsing. It does this by hosting CND resources locally. When your browser makes a request for one of these CDN resources, the request is blocked and you are served up a local version instead. Quote:Can CDNs track me even though they do not place tracking cookies? GitHub/Synzvato/decentraleyes
This rule allows Privoxy to use local versions instead: Code: { +redirect{[email protected]^(https?://)?[^,%]+\b(angular|backbone|dojo|ember|ext.core|jquery.ui|jquery|modernizr.min|mootools-yui-compressed|prototype|scriptaculous|swfobject|underscore.min)\b[^/]*\.js[^,%]*@http://localhost/~Your_Path_to/CommonJS/$[email protected]} } Put it in `user.action` file. Instead of using `?!`, the above exception could be equally rewritten like this: Code: { -redirect } Useful for some websites requiring a specific resource version. If you encounter an issue while visiting a website, the following alias can help you isolate it: Code: JSRoute='egrep "Redirect:\s+pcrs.*changed" /private/var/log/privoxy/logfile.log | \ Example of outputs: Code: 2016-09-05 11:12:07.640 Note: do update your libraries regularly… ![]() Some stats. After one week of surfing… Code: Libraries | Request # | JS Sizes 173 MB's worth of third-party resources that didn't get downloaded over just one week. -–— Minuscule donations are always appreciated… Code: BTC --> 34WKogWorDoReJ2MSxw8rTsrGD87VMAPJY |
|||
![]() cattleyavns, kik0s |
Jan. 05, 2017, 08:30 AM
(This post was last modified: Jan. 05, 2017 12:24 PM by cattleyavns.)
Post: #2
|
|||
|
|||
RE: Something like “decentraleyes” for Privoxy…
Thank you for this very useful tutorial, just one thing I would like to share is, config.privoxy.org/user-manual/ can be used to serve local content, support HTTPS if you open ProxHTTPSProxy's config.ini, find the line with "[SSL No-Verify]" and add:
Code: config.privoxy.org And you can access https://config.privoxy.org. Privoxy have a hidden feature is "user-manual" folder can be used as webserver. An example: Code: FILTER:gmfunc |
|||
![]() kik0s |
Jan. 05, 2017, 12:36 PM
(This post was last modified: Jan. 05, 2017 05:38 PM by Faxopita.)
Post: #3
|
|||
|
|||
RE: Something like “decentraleyes” for Privoxy… | |||
Jan. 14, 2017, 11:48 PM
(This post was last modified: Jan. 15, 2017 01:27 PM by kik0s.)
Post: #4
|
|||
|
|||
RE: Something like “decentraleyes” for Privoxy…
(Jan. 05, 2017 08:30 AM)cattleyavns Wrote: Thank you for this very useful tutorial, just one thing I would like to share is, config.privoxy.org/user-manual/ can be used to serve local content, support HTTPS if you open ProxHTTPSProxy's config.ini, find the line with "[SSL No-Verify]" and add: so i can put the GM file their instead of using greasyfork? but why are you saying it here? ![]() now i got what you meant with the webserver stuff. @faxtopia so i can use that commonJS file for every site?! why is it always the same? |
|||
Jan. 15, 2017, 03:00 PM
(This post was last modified: Jan. 15, 2017 05:30 PM by cattleyavns.)
Post: #5
|
|||
|
|||
RE: Something like “decentraleyes” for Privoxy…
(Jan. 14, 2017 11:48 PM)kik0s Wrote: so i can put the GM file their instead of using greasyfork? but why are you saying it here? I think that time I put greasefork.org link for my GM_function to make sure that the script "can" run on HTTPS site ( the greasefork one is HTTPS ), but a few months from that time, I found out that I can use config.privoxy.org as not only a webserver, but it can work as a HTTPS webserver. Normally if I use http://config.privoxy.org/user-manual/GM_function.js and try to open Youtube.com, web browser will block GM_function, the reason is, Youtube is HTTPS, the js file is HTTP, HTTPS will block all HTTP (see Mixed Content) All thank to ProxHTTPSProxy, the above problem is solved. And I also want to share another filter, this filter will disable Content-Security-Policy on all website, will prevent websites from blocking our local content. Code: SERVER-HEADER-FILTER: removecontentsecuritypolicy The better way is we can parse Content-Security-Policy and add our local webserver's domain to it, but it is hard for me, but I think someone can do that. |
|||
![]() Faxopita |
Jan. 16, 2017, 01:02 PM
(This post was last modified: Jan. 17, 2017 12:22 PM by Faxopita.)
Post: #6
|
|||
|
|||
RE: Something like “decentraleyes” for Privoxy…
(Jan. 14, 2017 11:48 PM)kik0s Wrote: @faxtopia so i can use that commonJS file for every site?! why is it always the same? CommonJS is a folder that contains most common used libraries. Privoxy will query the corresponding local versions—inside folder CommonJS—to the remote ones. Web pages will load faster. If you are not inclined to enable your local web server… You can copy the content of CommonJS folder to… Code: /usr/local/share/doc/privoxy/user-manual/ -–— I tried copying the folder CommonJS itself, but Privoxy does not, for example, allow access to… Code: https://config.privoxy.org/user-manual/CommonJS/angular.js It doesn't like the folder CommonJS in-between… ![]() —–- Then, you can replace… Code: http://localhost/~Your_Path_to/CommonJS/$2.js Code: https://config.privoxy.org/user-manual/$2.js As an example, you can access angular.js by typing Code: https://config.privoxy.org/user-manual/angular.js Notes:
|
|||
![]() cattleyavns, kik0s |
Jan. 16, 2017, 02:58 PM
Post: #7
|
|||
|
|||
RE: Something like “decentraleyes” for Privoxy…
@faxtopia looks like the internal webserver is only using one folder. i will check the source if their is a limitation of somekind. so putting the files directly into user-manual should wirk?
|
|||
Jan. 16, 2017, 03:19 PM
(This post was last modified: Jan. 17, 2017 12:30 PM by Faxopita.)
Post: #8
|
|||
|
|||
RE: Something like “decentraleyes” for Privoxy…
(Jan. 16, 2017 02:58 PM)kik0s Wrote: @faxtopia looks like the internal webserver is only using one folder. i will check the source if their is a limitation of somekind. so putting the files directly into user-manual should wirk? Just tested. I confirm it works. Make sure you replace Code: http://localhost/~Your_Path_to/CommonJS/$2.js Code: https://config.privoxy.org/user-manual/$2.js Example with angular: Code: 2017-01-16 15:20:55.539 |
|||
![]() kik0s, cattleyavns |
Sep. 02, 2017, 07:57 AM
Post: #9
|
|||
|
|||
RE: Something like “decentraleyes” for Privoxy…
Files that are redirected, such as specially made?
|
|||
Sep. 02, 2017, 09:23 AM
(This post was last modified: Sep. 02, 2017 09:31 AM by vlad_s.)
Post: #10
|
|||
|
|||
RE: Something like “decentraleyes” for Privoxy…
Another way to cancel a redirect. Makes a filter:
Code: CLIENT-HEADER-TAGGER: do-not-redirect Next action: Activating the filter on yastatic.net and googleapis.com Code: {+client-header-tagger{do-not-redirect} \ Canceling the redirect when the "test" tag appears: Code: {-redirect \ |
|||
![]() Faxopita |
Jul. 16, 2018, 09:03 PM
Post: #11
|
|||
|
|||
RE: Something like “decentraleyes” for Privoxy…
(Jan. 15, 2017 03:00 PM)cattleyavns Wrote: And I also want to share another filter, this filter will disable Content-Security-Policy on all website, will prevent websites from blocking our local content.I like that, but it seems not to work as websites still give messages of disabled content ![]() mixedcontent.filter Code: SERVER-HEADER-FILTER: removecontentsecuritypolicy Code: {+server-header-filter{removecontentsecuritypolicy}} I server with privoxy same content to the webpage with ssl for devices that accept local certificates and without ssl for those that don't so at least http only content would keep filtered there, but getting this to work would mean I could use only http for both. Would I need to disable it for webpages I visit? I would like to avoid that as disabling seurity policies on web pages seems not as the best idea. On other side have You been able to write the code that would inject information about local server as trusted into the webpage code? |
|||
Jul. 17, 2018, 01:40 PM
(This post was last modified: Jul. 17, 2018 01:41 PM by ryszardzonk.)
Post: #12
|
|||
|
|||
RE: Something like “decentraleyes” for Privoxy…
@Faxopita & @cattleyavns
(Jan. 01, 2017 12:56 PM)Faxopita Wrote: To roughly mimic “decentraleyes” Firefox add-on… Seems that BetterCache approach proposed by cattleyavns could also achieve the same and hence if I understand it right cached files are there until next privoxy restart than by restarting once a month one could have both freshest libraries which would be downloaded only once by privoxy when needed. |
|||
Jul. 21, 2018, 09:45 PM
Post: #13
|
|||
|
|||
RE: Something like “decentraleyes” for Privoxy…
(Jul. 16, 2018 09:03 PM)ryszardzonk Wrote: I like that, but it seems not to work as websites still give messages of disabled content I just want to correct about "prevent Content-Security-Policy from blocking local contents", this feature prevent "Content-Security-Policy's rules" (see https://developer.mozilla.org/en-US/docs/Web/HTTP/CSP ) from blocking our local contents and not "Mixed Content", the only way to bypass "Mixed Content" on HTTPS websites is to make our local contents become HTTPS. |
|||
Aug. 14, 2018, 07:54 PM
Post: #14
|
|||
|
|||
RE: Something like “decentraleyes” for Privoxy…
I actually tried it for static fonts as they do not change, but seems it does not work. What am I doing wrong?
Code: 2018-08-14 21:47:12.444 7fc5e27fc700 Request: encrypted-tbn3.gstatic.com/shopping?q=tbn:ANd9GcRsGohMOn8Ns7Wivy1PWEDrP2NrCHiu-pFfzY0x4l9LyEB5fJVvjrxHgE77AOXH3DHWVGAW4hs&usqp=CAc decentraleyes.action Code: #P5sMzZCDf9_T_10XxCF8jA.woff2 |
|||
Aug. 17, 2018, 05:26 PM
Post: #15
|
|||
|
|||
RE: Something like “decentraleyes” for Privoxy…
(Aug. 14, 2018 07:54 PM)ryszardzonk Wrote: I actually tried it for static fonts as they do not change, but seems it does not work. What am I doing wrong? There is something wrong with your Regex rule, I think modify it again is the way to go. |
|||
« Next Oldest | Next Newest »
|