Author Topic: [Solved]needs some help with: Webbrowser or Webclient  (Read 5195 times)

0 Members and 2 Guests are viewing this topic.

Offline Huntondoom

  • Baron
  • ****
  • Posts: 856
  • Cookies: 17
  • Visual C# programmer
    • View Profile
[Solved]needs some help with: Webbrowser or Webclient
« on: May 04, 2011, 07:46:22 pm »
Hello,

as Im working on a program for my band
this program should update the following:
myspace stuff
facebook stuff
hyves stuff
youtube stuff

but the problem is once I use webbrowser on Myspace I get a page that
says that the browser is incompatible :(
is there a way to undo this sort of stuff?

and:

Im using webbrowser cause I know how to use that with Username and Password
but how would I do that with Webclient?
(since Webclient is beter and faster then Webbrowser)
« Last Edit: May 05, 2011, 08:44:15 pm by Huntondoom »
Aslong as you are connected to the internet, you'll have no privacy

Advanced Internet Search
Clean Up!

Offline Satan911

  • VIP
  • Knight
  • *
  • Posts: 289
  • Cookies: 25
  • Retired god/admin
    • View Profile
Re: [problem]needs some help with: Webbrowser or Webclient
« Reply #1 on: May 05, 2011, 12:19:11 am »
Spoof your user agent? Should work..
Satan911
Evilzone Network Administrator

Offline Huntondoom

  • Baron
  • ****
  • Posts: 856
  • Cookies: 17
  • Visual C# programmer
    • View Profile
Re: [problem]needs some help with: Webbrowser or Webclient
« Reply #2 on: May 05, 2011, 02:38:40 pm »
Spoof your user agent? Should work..
and Any idea how I would that?
Aslong as you are connected to the internet, you'll have no privacy

Advanced Internet Search
Clean Up!

Offline ande

  • Owner
  • Titan
  • *
  • Posts: 2664
  • Cookies: 256
    • View Profile
Re: [problem]needs some help with: Webbrowser or Webclient
« Reply #3 on: May 05, 2011, 05:16:34 pm »
If it says the browser is incompatible, chances are it is. And changing the user-agent wont help anything. Either way...;

You can use the net.webclient to all web related stuff, login, logout, post things, check things, upload stuff, upload files etc etc etc etc. You name it.

You use the webclient.headers.add() to add different HTTP header flags, like cookies, user agent and more. And a byte array of POST data and webclient.uploaddate(url, "POST", bytedata) if you want to perform POST stuff(99,99% logins and such will be POST).

I can help you out later, but I am EXTREMELY busy these days. Ill check back on this topic later if I remember it. Most likely I will not so you will have to remind me, but later. Much later.
if($statement) { unless(!$statement) { // Very sure } }
https://evilzone.org/?hack=true

Offline Huntondoom

  • Baron
  • ****
  • Posts: 856
  • Cookies: 17
  • Visual C# programmer
    • View Profile
Re: [problem]needs some help with: Webbrowser or Webclient
« Reply #4 on: May 05, 2011, 08:43:59 pm »
You use the webclient.headers.add() to add different HTTP header flags, like cookies, user agent and more. And a byte array of POST data and webclient.uploaddate(url, "POST", bytedata) if you want to perform POST stuff(99,99% logins and such will be POST).

so I have to look for the method on the website right?
cause On the Evilzone forum I found:
Code: [Select]
<form id="guest_form" action="http://evilzone.org/login2/" method="post" where the method is post, so you use Post (just to check)

and I used this:
Code: [Select]
Dim Browser As New WebClient
        Browser.Headers.Add(HttpRequestHeader.UserAgent, "Google Chrome")
        Dim Page As String = Browser.DownloadString("http://www.myspace.com/")
        Console.WriteLine(Page)
        Console.ReadLine()
and It worked, got the website
thanks All!
Aslong as you are connected to the internet, you'll have no privacy

Advanced Internet Search
Clean Up!

Offline Stackprotector

  • Administrator
  • Titan
  • *
  • Posts: 2515
  • Cookies: 205
    • View Profile
Re: [Solved]needs some help with: Webbrowser or Webclient
« Reply #5 on: May 07, 2011, 09:50:25 am »
huntodoom,.
you have POST and GET as methods, GET is like (most commonly) evilzone.org/index.php?id=myfile.
Then the variable id is set to myfile when reqeusting the GET method in php.
That is the reason why logins are not in GET but in POST, otherwise it would be like this evilzone.org/index.php?username=huntodoom&password=justingbieber.

Hope this helps you out.
« Last Edit: May 07, 2011, 09:53:19 am by Factionwars »
~Factionwars

Offline Satan911

  • VIP
  • Knight
  • *
  • Posts: 289
  • Cookies: 25
  • Retired god/admin
    • View Profile
Re: [Solved]needs some help with: Webbrowser or Webclient
« Reply #6 on: May 09, 2011, 09:27:01 am »
If it says the browser is incompatible, chances are it is. And changing the user-agent wont help anything. Either way...;

Why not? The user agent is "the term most notably refers to applications that access the World Wide Web". If you are using application and the user agent is not recognized, spoofing the user agent to like "Firefox 4.1 Windows NT" will fool the server making it think you are using Firefox. Maybe I'm missing something but that should solve the problem no?
Satan911
Evilzone Network Administrator

Offline ande

  • Owner
  • Titan
  • *
  • Posts: 2664
  • Cookies: 256
    • View Profile
Re: [Solved]needs some help with: Webbrowser or Webclient
« Reply #7 on: May 09, 2011, 12:11:39 pm »
Why not? The user agent is "the term most notably refers to applications that access the World Wide Web". If you are using application and the user agent is not recognized, spoofing the user agent to like "Firefox 4.1 Windows NT" will fool the server making it think you are using Firefox. Maybe I'm missing something but that should solve the problem no?

You might fool the server, but you cant fool the browser into thinking it is something else, and therefore work with various plugins, functions and so on.
if($statement) { unless(!$statement) { // Very sure } }
https://evilzone.org/?hack=true

Offline Huntondoom

  • Baron
  • ****
  • Posts: 856
  • Cookies: 17
  • Visual C# programmer
    • View Profile
Re: [Solved]needs some help with: Webbrowser or Webclient
« Reply #8 on: June 12, 2011, 09:05:14 pm »
argh T.T

I Tried to make something that would login into myspace
but it failed T.T

any one has a good example/snippet on how to login onto a site?
Aslong as you are connected to the internet, you'll have no privacy

Advanced Internet Search
Clean Up!

Offline ande

  • Owner
  • Titan
  • *
  • Posts: 2664
  • Cookies: 256
    • View Profile
Re: [Solved]needs some help with: Webbrowser or Webclient
« Reply #9 on: June 13, 2011, 12:08:18 am »
argh T.T

I Tried to make something that would login into myspace
but it failed T.T

any one has a good example/snippet on how to login onto a site?

Bump this thread sometime tomorrow or late late late late tonight when I have my machine back and running and ill help ya ;)
if($statement) { unless(!$statement) { // Very sure } }
https://evilzone.org/?hack=true

Offline Huntondoom

  • Baron
  • ****
  • Posts: 856
  • Cookies: 17
  • Visual C# programmer
    • View Profile
Re: [Solved]needs some help with: Webbrowser or Webclient
« Reply #10 on: June 13, 2011, 06:30:34 pm »
I declare here by: Bump
Aslong as you are connected to the internet, you'll have no privacy

Advanced Internet Search
Clean Up!

Offline ande

  • Owner
  • Titan
  • *
  • Posts: 2664
  • Cookies: 256
    • View Profile
Re: [Solved]needs some help with: Webbrowser or Webclient
« Reply #11 on: June 13, 2011, 06:33:50 pm »
lolfuu

Computer still fucked up :P ETA 3-4 hours
if($statement) { unless(!$statement) { // Very sure } }
https://evilzone.org/?hack=true

Offline Huntondoom

  • Baron
  • ****
  • Posts: 856
  • Cookies: 17
  • Visual C# programmer
    • View Profile
Re: [Solved]needs some help with: Webbrowser or Webclient
« Reply #12 on: June 17, 2011, 12:55:01 am »
Omg I forgot!
Bump!
Aslong as you are connected to the internet, you'll have no privacy

Advanced Internet Search
Clean Up!

Offline Huntondoom

  • Baron
  • ****
  • Posts: 856
  • Cookies: 17
  • Visual C# programmer
    • View Profile
Re: [Solved]needs some help with: Webbrowser or Webclient
« Reply #13 on: June 21, 2011, 12:03:25 am »
bump?
Aslong as you are connected to the internet, you'll have no privacy

Advanced Internet Search
Clean Up!

Offline ande

  • Owner
  • Titan
  • *
  • Posts: 2664
  • Cookies: 256
    • View Profile
Re: [Solved]needs some help with: Webbrowser or Webclient
« Reply #14 on: June 21, 2011, 12:18:05 am »
bump?

Okay yah. This one is a bit tricky. First you have to query the page once to get some sort of hash from the page in order to be able to perform a valid login attempt. Then you have to send the actual logins. Ill try a few mins and tell you the results.

EDIT:

Okay, myspace is a fucking mess. The guys who designed that thing deserves to get shoot. They cannot have any idea what they are doing and are generally just clashing things together. Or they are simply trying to make it impossible for others to make anything other than humans/browsers login there.

The easiest way to login to myspace would be using the webbrowser control. Its not something I like to use, in fact I try to avoid it. Anyway. You can use the webbrowser.document.all.item("name_of_input").setattribute("value", "some_value") for username and password. Then use webbrowser.document.all.item("button_name").invokmember("click") to click the login button.

You CAN do this with webclient instead, but it would require a lot of trail and error.
« Last Edit: June 21, 2011, 12:35:42 am by ande »
if($statement) { unless(!$statement) { // Very sure } }
https://evilzone.org/?hack=true