2

I am currently using an application as tuxler from https://tuxler.com/ to pass through a proxy to browse the internet.

I wanted to know if its possible via c# to also use that proxy to download a web page. I tried a few items, one of them is below:-

var handler = new HttpClientHandler();
handler.UseProxy = true;
handler.UseDefaultCredentials = true;
handler.Proxy = WebRequest.DefaultWebProxy;
var client = new HttpClient(handler);
client.DefaultRequestHeaders.TryAddWithoutValidation("User-Agent", "Mozilla/5.0 Bla");
response = await client.GetByteArrayAsync(page);

So basically what i want to do is a c# code to use the same proxy as my browser is using.

1
  • Is that code not working in some way? Are you getting exceptions/errors? You should explain what the issue is more clearly. Commented Mar 16, 2018 at 20:57

1 Answer 1

2

Tuxler is VPN based on google extension, so you can use it only in Chrome browser.

Try some other VPN with desktop application like: Windscribe (free) or OpenVPN (you need configs for VPN).

All traffic from your computer will be pushed through a VPN. You don't need to setup anything in c# code.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.