0

I trying to do request to IPLogger to see which kind of systems using my software, I am not sure but seems like IPLogger couldn't see a client User Agent. So the question is how to make a request to URL with User Agent?

I tried this:

HttpWebRequest myRequest = (HttpWebRequest)WebRequest.Create(url);
myRequest.Method = "GET";   

And this:

var data = new WebClient().DownloadString(url);

As you can see, client system and browser is unknown. But when I do it manually from my browser it works fine.

Ryan Cowl
  • 53
  • 1
  • 4
  • Check out this question and answer: https://stackoverflow.com/questions/11841540/setting-the-user-agent-header-for-a-webclient-request – JonyVol Dec 24 '18 at 21:02
  • @YoniV i guess this question is about how to set a custom User Agent string, but i need the default user agent, because i want to know which system is on my client. It's should be something like how to make a request from client default browser or smth like that. – Ryan Cowl Dec 24 '18 at 21:15
  • There's no way to accomplish what you want. Windows can tell you what the user's default browser is, but has no way of knowing its user agent string. You shouldn't be trying to send through a browser's UA though anyway, **because your app is not that browser**. – Ian Kemp Dec 24 '18 at 22:03

0 Answers0