[newbie][OFF][Win32][Winsock] reading from and writing to connections
- From: Leslie Kis-Adam <dfighter@xxxxxxxxxxx>
- Date: Sat, 10 May 2008 22:39:34 +0200
Dear everyone!
I'm new to network programming and I require some help. =)
So I decided to write a little utility similar to netcat as 2nd networking program, and when I'm writing to port 25 (an Exim mailer daemon is sitting on it), it gives me an SMTP code 554 (Synchronization error). I've found out it means I broke the protocol with writing to it before receiveing code 220 (the banner). I'd like to fix it, the problem is I have no idea how to :\. Since it is a generic application, if I used recv(), before sending a command it could be hanging there blocking until the end of time if I used it to connect to another service.
the source: http://pastebin.ca/1014034
screenshot about the error: http://img123.imageshack.us/img123/5176/554lh6.jpg
packets captured with wireshark: http://filebin.ca/oyudtg/mync.pcap
Any help is appreciated.
I know it is offtopic here (as the topic shows) a bit since I am trying this in win32 environment, but since my problem is generic enough I thought I would try it here. Also if you can direct me to the right group, that would be nice too =)
.
- Follow-Ups:
- Re: [newbie][OFF][Win32][Winsock] reading from and writing to connections
- From: Jens Thoms Toerring
- Re: [newbie][OFF][Win32][Winsock] reading from and writing to connections
- Prev by Date: Re: Regarding Network Programming
- Next by Date: Re: [newbie][OFF][Win32][Winsock] reading from and writing to connections
- Previous by thread: Protect yourself against Operation Sudden Fall
- Next by thread: Re: [newbie][OFF][Win32][Winsock] reading from and writing to connections
- Index(es):
Relevant Pages
|