flat assembler
Message board for the users of flat assembler.
![]() |
Author |
|
Trentie89
Hi Guys,
How do i send HTTP data in fasm.?. I Simply want to say, make the program open the website www.google.com.au, but not actually opening it in a new window, just sending HTTP data. Trent. _________________ I Am the greatest.!. ( NOT YET ). |
|||
![]() |
|
revolution
There are already a few solutions posted on this board. Good search terms could be "winsock" and "WSAStartup"
|
|||
![]() |
|
revolution
URLDownloadToFile is a high level API, you don't get much control over the sending of the HTTP data. Winsock allows more flexibility.
|
|||
![]() |
|
Trentie89
The reason i want to send data via HTTP is because i am collecting data with my Arduino microcontroller and i want to send the details remotely via HTTP so that my mate can see them 5,000 km away.!.
|
|||
![]() |
|
revolution
HTTP is a client/server type protocol. It makes a difference in the code if you are writing the client or the server.
If you want to send data to a remote location then one end will be the client and the other will be the server. It doesn't matter which end is which role, just as long a they are not the same. But I wonder if HTTP is the best protocol for you in your case? There are other protocols that might be easier. You can use Winsock for other protocols also. |
|||
![]() |
|
Trentie89
Ahh okay, yes i think HTTP is as i am running my asm code as a client to a PHP Server.
But, where can i learn about winsock apis in fasm.?. If you say that's best even for HTTP. Trent. |
|||
![]() |
|
revolution
I'm not saying it is best. Just that you can completely control the HTTP protocol with winsock. If you want something "easier" then there are higher level APIs that will do all the HTTP stuff for you. I was just commenting on your initial request to "just [send] HTTP data".
|
|||
![]() |
|
Trentie89
Can i use URLDownloadToFile with fasm.?. Which library.?.
|
|||
![]() |
|
revolution
That API isn't in the normal set of API defintions that asm comes with. But you can add it
A quick search shows that this is in Urlmon.dll. So you can make a new definition for it and update the sources to include it. |
|||
![]() |
|
Trentie89
I'm trying to get my head around all this. As you know, i am a beginner. I can do most things,
i know how to call API's and such, but am not entirely familiar with ASM Completely yet. I've been looking at the amazingly awesome tool quetannon, someone posted. It would be nice if one of you guys could just show me here some simple code to make a winsock connection to localhost:80. Thankx.!. |
|||
![]() |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2020, Tomasz Grysztar. Also on GitHub, YouTube, Twitter.
Website powered by rwasa.