[Last Call] Learn about multicloud storage options and how to improve your company's cloud strategy. Register Now

x
?
Solved

Layered Service Provider for Windows(LSP)

Posted on 2004-08-19
3
Medium Priority
?
397 Views
Last Modified: 2013-12-19
Hi,

I am creating a Layered Service Provider for windows to check outgoing packets.

When I am in the WSPSend function I look through the data and if it meets a certain condition,
I am interested in connecting the socket up to my listening server on Windows, so that instead of the packet
being sent out to the website, it goes to my server.

Do you by chance know how to reconnect the socket without causing errors in the programs that
made the connection, to the listening server I created. <-- want to reconnect the socket within the WSPSend function of my lsp dll, so the packet can be sent to my server instead.

 I tried connect, but throws a -1 error.

Thanks,
Matt
0
Comment
Question by:JaffaLink
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 37

Accepted Solution

by:
bbao earned 500 total points
ID: 11875283
"If no error occurs and the send operation has completed immediately, WSPSend returns zero. Note that in this case the completion routine, if specified, will have already been queued. Otherwise, a value of SOCKET_ERROR is returned, and a specific error code is available in lpErrno. The error code WSA_IO_PENDING indicates that the overlapped operation has been successfully initiated and that completion will be indicated at a later time. Any other error code indicates that no overlapped operation was initiated and no completion indication will occur."

http://msdn.microsoft.com/library/en-us/winsock/winsock/wspsend_2.asp

so, which error code's value is -1, could you please clarify? thanks, bbao
0

Featured Post

Nothing ever in the clear!

This technical paper will help you implement VMware’s VM encryption as well as implement Veeam encryption which together will achieve the nothing ever in the clear goal. If a bad guy steals VMs, backups or traffic they get nothing.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Have you ever set up your wireless router at home or in the office to find that you little pop-up bubble in the bottom right-hand corner of Windows read "IP Conflict - One of more computers on the network have been assigned the following IP address"…
Are you one of those front-line IT Service Desk staff fielding calls, replying to emails, all-the-while working to resolve end-user technological nightmares? I am! That's why I have put together this brief overview of tools and techniques I use in o…
Michael from AdRem Software explains how to view the most utilized and worst performing nodes in your network, by accessing the Top Charts view in NetCrunch network monitor (https://www.adremsoft.com/). Top Charts is a view in which you can set seve…
In this video, Percona Solutions Engineer Barrett Chambers discusses some of the basic syntax differences between MySQL and MongoDB. To learn more check out our webinar on MongoDB administration for MySQL DBA: https://www.percona.com/resources/we…

656 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question