Issues for LSPs that connect to local host

As discussed in my previous post, the autobind_lsp performs
hard binding.  This will cause issues for LSPs that need to connect to


About hard binding:

Hard binding is a per socket TCP options specified by:

    WSAIoctl(..., SIO_UCAST_IF,..).


Once a socket is hard bound, all data on that socket must be
sent/received from the same adapter.  In hard binding, the loop back
adapter is a distinct adapter.


When does hard binding cause a problem?

Hard binding causes a problem when you want your LSP to
connect to local host after a hard bind has occurred. In this case, you do not
want the hard binding to occur.


Example of common failure:

        step 1) App:
connect (
        step 2) autobind_lsp:
bind  (

        step 3) autobind_lsp:
WSAIoctl(…, SIO_UCAST_IF, …)
        step 4) autobind_lsp:
connect (

        step 5)
YourProxy_LSP: connect_to_your_proxy_server  (

step 5) Will fail since your socket is already hard bound to


The work around:

A work around is to layer your LSP under autobind, and 
not propagate the SIO_UCAST_IF IOCTLs to the next LSP in the stack.

When you should use the work around:

This work around should only be used for sockets on which
your LSP is explicitly proxying all data to a component you control. If
your LSP is not doing this, the workaround should not be used.

[Author: Igor Dvorkin]