Disclosure Statement: This site contains affiliate links, which means that I may receive a commission if you make a purchase using these links. As an eBay Partner, I earn from qualifying purchases.

How to set proxy settings ... especially tor network

snoop
Posts: 75
Joined: Mon Jul 10, 2017 12:06 pm

Re: How to set proxy settings ... especially tor network

Post by snoop »

Sure I call UpdatePreferences
Just tested that demo project with proxy addition
Unfortunately same results and 407 error! Both with shared and not settings
I also tried to set proxy after creating browser and with update. No result
Please buy a proxy and test it, it costs nothing for just one
Or you can contact me to get a proxy if you want

UPD: its not even getting to doOnGetAuthCredentials! I tried breakpoint
User avatar
salvadordf
Posts: 4016
Joined: Thu Feb 02, 2017 12:24 pm
Location: Spain
Contact:

Re: How to set proxy settings ... especially tor network

Post by salvadordf »

snoop wrote: Fri Jan 26, 2018 4:56 pm Sure I call UpdatePreferences
Just tested that demo project with proxy addition
Unfortunately same results and 407 error! Both with shared and not settings
I also tried to set proxy after creating browser and with update. No result
Please buy a proxy and test it, it costs nothing for just one
Or you can contact me to get a proxy if you want

UPD: its not even getting to doOnGetAuthCredentials! I tried breakpoint
Send me the details for that proxy server in a private message.

Have you tried to use Chrome or Chromium with that proxy?
snoop
Posts: 75
Joined: Mon Jul 10, 2017 12:06 pm

Re: How to set proxy settings ... especially tor network

Post by snoop »

sent pm with proxy
Please read all my messages carefully. Proxy is 100% working
It works on main form, on other forms after clearing cache or some re-entering proxy, it worked everywhere on previous CEF builds
User avatar
salvadordf
Posts: 4016
Joined: Thu Feb 02, 2017 12:24 pm
Location: Spain
Contact:

Re: How to set proxy settings ... especially tor network

Post by salvadordf »

I just uploaded a quick fix to create the request handler even when you don't use any of its events.
Please, download CEF4Delphi again and try it in you app.
snoop
Posts: 75
Joined: Mon Jul 10, 2017 12:06 pm

Re: How to set proxy settings ... especially tor network

Post by snoop »

Thank you! Finally it works! Also small question: How to force to load site without loading it from cache? To load newest version
User avatar
salvadordf
Posts: 4016
Joined: Thu Feb 02, 2017 12:24 pm
Location: Spain
Contact:

Re: How to set proxy settings ... especially tor network

Post by salvadordf »

You can use TChromium.ReloadIgnoreCache; to reload ignoring the cache or you can modify the HTTP headers to append :

Code: Select all

Cache-Control: no-cache, no-store
You can append a custom header by setting the TChromium.CustomHeaderName and TChromium.CustomHeaderValue properties or by using the TChromium.OnBeforeResourceLoad event.
snoop
Posts: 75
Joined: Mon Jul 10, 2017 12:06 pm

Re: How to set proxy settings ... especially tor network

Post by snoop »

Hello again, Salvador. Do you remember my old request about different proxies in 2 browsers? Different proxies, but same other context (cookie,cache,etc)... I still need this feature a lot. Can I do it now somehow?
User avatar
salvadordf
Posts: 4016
Joined: Thu Feb 02, 2017 12:24 pm
Location: Spain
Contact:

Re: How to set proxy settings ... especially tor network

Post by salvadordf »

As I commented in this thread, that's how CEF3 works and I can't do anything about it :
https://www.briskbard.com/forum/viewtop ... rt=10#p754

If you need that feature you can request it in the CEF3 project website :
https://bitbucket.org/chromiumembedded/cef
User avatar
xpert13
Posts: 39
Joined: Wed May 31, 2017 5:26 pm

Proxy...

Post by xpert13 »

Hello, everyone.

I did the same thing but I didn't get even errors. The pages load in the same way as usual. Proxy settings is ignoring;

Code: Select all

FChromium := TChromium.Create(Sender);

FChromium.ProxyType := CEF_PROXYTYPE_FIXED_SERVERS;
FChromium.ProxyScheme := psSOCKS5;
FChromium.ProxyServer := '189.102.74.134';
FChromium.ProxyPort := 33601;
FChromium.ProxyUsername := '';
FChromium.ProxyPassword := '';  

FChromium.DefaultUrl := 'http://myip.ru/';
FChromium.CreateBrowser(Sender);
User avatar
xpert13
Posts: 39
Joined: Wed May 31, 2017 5:26 pm

Re: How to set proxy settings ... especially tor network

Post by xpert13 »

I found the solution. It was need to add UpdatePreferences after CreateBrowser
Post Reply