This project has moved. For the latest updates, please go here.

Error! Could not listen to TCP

Mar 26, 2013 at 4:55 PM
Hi,

I am at the first step of configuring Barba Tunnel server on an XP box. What I have done so far is to install WinpkFilter and change some settings in ini files. When I start BarbaTunnel.exe, I get:

C:\TEMP\BarbaTunnel-6.4-win\Bin\x86>BarbaTunnel.exe
Barba Server Started...
Version: 6.4
FilterDriver: WinpkFilter
Adapter: Local Area Connection
HttpHost: TID: 3ec, Listening to TCP 10.22.0.87:443.
HttpHost: TID: 3ec, Error! Could not listen to TCP 10.22.0.87:443. The requested address is not valid in its context.
Ready!

I can ping the 10.22.0.87 box from the XP box and there is a service running on port 443.

Here is how the ini files look like:

------------- BarbaTunnel.ini ---------------

[General]
ServerMode=1
VerboseMode=1
DebugMode=
FilterDriver=WinpkFilter
AdapterIndex=
MTUDecrement=
ConnectionTimeout=

[Server]
ConfigFileName=
VirtualIpRange=
AutoStartDelay=3

--------------------------- config.ini ---------------------

[General]
ServerAddress=10.22.0.87
Enabled=1
Mode=HTTP-Tunnel
Key=1234567890ABCDEF
TunnelPorts=443
GrabProtocols=GRE:*,TCP:1723
MaxUserConnections=
FakeFileTypes=jpg,zip
FakeFileMaxSize=
FakePacketMinSize=
KeepAliveInterval=
RequestDataKeyName=

I can't find much documentation about the "ServerAddress" setting and thought it should be the IP address of the real server (web server in this case), is that right?

Could someone point out what wrong in my configuration is, please?

Thanks,

vda
Coordinator
Mar 26, 2013 at 8:28 PM
Hi
It look you are using http tunnel for port 443. I think your IIS or another application already binding this port. I recommend you use another port for http tunnel such 8080. The best port is 80 but you need unbind IIS or any service that use your specified port.
Regards
Mar 27, 2013 at 10:26 AM
Hi BarbaCoder,

Let's me clarify the configuration:

Barba Tunnel is installed on an XP box, the IP address of that XP box doesn't matter.

10.22.0.87 is the IP address of another box (OS doesn't matter). On the 10.22.0.87 box there is a web server listening on port 443. There is nothing wrong with the web server as I can connect to it normally.

The XP box on which Barba Tunnel is tried to run as a server is a virtual machine. There is no firewall, anti-virus or what so ever that could block any port.

Second question: As far as I understand, Barba Tunnel does nothing but sits on a network card and examines packets passing through that card. If the IP address/port/protocol of a packet matches what is specified in config file, Barba will encrypt (client) or decrypt (server) the packet in order to hide some information from 3rd party blocking mechanism, e.g. proxy of firewall, is that correct?

If my understanding was correct, I just don't understand why Barba needs to connect to any server. The error message "Error! Could not listen to..." implies that Barba is trying to establish some kind of connection. Could you explain, please?

Thanks,

vda
Coordinator
Mar 28, 2013 at 10:39 AM
Yes, you understood right, but in http tunnel Barbatunnel establish standard tcp connection and your IIS already reserve that port.
You should change barbatunnel port or disable IIS on that port.
IIS bind that port for https protocol by by default.
Regards
Mar 28, 2013 at 4:40 PM
Hi BarbaCoder,

Whatever port number I put in, the result is the same. However if I provide a non-existing server, e.g. ServerAddress=www.fake.foo and TunnelPorts=12345 it was happy. So I still do not understand the logic behind it.

I very much appreciate your willingness to help. Your software is very promising but believe me, without a good documentation and if people can't use it, it is not helpful, just a bit of interesting software.

Would you mind updating the documentation section with explanation why a setting must be what it expected to be. Even better if there is an axample config files with some diagrams of how the server and client is connected using that example ini files, it would hep many people, not just me, to understand how to configure it correctly.

Sorry if I was a pain.

Thanks,

vda
Coordinator
Mar 28, 2013 at 7:19 PM
Dear vda
I understand the importance of documentation, but network is very very wide area, and when an unknown issue occur such as your case it is very hard to solve it.
Your server just could not start listening to a port with standard socket API. Actually this error raised by Microsoft socket API, so how it should be documented when the reason is unknown for me?

I would be happy if you document the issue and resolution if you solve it.
Regards