Custom Build to overcome firewall

Problems compiling? Don't understand the source code? Don't know how to code your feature? Post here.

Moderator: Moderators

Locked
vandalman
Posts: 4
Joined: 2004-04-16 14:46

Custom Build to overcome firewall

Post by vandalman » 2004-04-16 15:40

I'm trying to create a custom build of DC++ v.401 to go through a firewall. The network admin says that he will open a port for client-hub(411) and for client-client connections(1412). There are lots of people who are on the network and it's easiest to have it work automatically, instead of having each person set it up.

I have figured that I could change SettingsManager.h by:

Uncommenting the line:

Code: Select all

setDefault(SERVER, Util::getLocalIp());
This finds the local IP and and inputs it into the box in the settings

And modify the line:

Code: Select all

setDefault(IN_PORT, Util::rand(1025, 32000));
To read:

Code: Select all

setDefault(IN_PORT, 1412);
This will make all client connections go through port 1412

Will this work? Am I missing anything? Should I use a diffrent port for client-client connections?

I've tried testing this, but I can't seem to build it :oops: I'm using VC7.0 and I havn't gotten a firm grip on how to use it (I'm a freshman CS major). Where can I get clear and concise howto?

Gratch06
Posts: 141
Joined: 2003-05-25 01:48
Location: USA

Post by Gratch06 » 2004-04-16 15:52

Well, rather than recompiling the client, I'd just use the Settings Dialogue and choose your port there. client <--> hub connections are over a port of the hub's choosing, but you can set an active mode port to whatever you want (in this 1412).

Since you seem to want an all at once solution, I'd look into distributing DC++ with the configuration xml file included.

vandalman
Posts: 4
Joined: 2004-04-16 14:46

Post by vandalman » 2004-04-16 17:12

What you suggested should do the trick. Is is possible to make a custom install. Would it be possible to get the config file for the DC++ installer? That way I can just tweak the original install to do what I want it to do.

thanks

GargoyleMT
DC++ Contributor
Posts: 3212
Joined: 2003-01-07 21:46
Location: .pa.us

Post by GargoyleMT » 2004-04-16 17:22

We use the NSIS installer - the .NSI script that drives it is in the source zips and in CVS. It's easy to add another file (the default settings) to the script. You don't even need to compile your own DC++ version - you can use the files that come in the ZIP distribution.

So your network admin is allowing 411 outbound globally and 1412 inbound? Is he restricting outbound communications in other ways?

vandalman
Posts: 4
Joined: 2004-04-16 14:46

Post by vandalman » 2004-04-16 17:41

Do i have to specify the users ip to go through the firewall? Can I just specify the port to use?
GargoyleMT wrote:So your network admin is allowing 411 outbound globally and 1412 inbound? Is he restricting outbound communications in other ways?
I'm getting together a solution to a problem. Once I get everything working, I'll send him what I want. Right now everything is locked down. We where using vpn to go around the firewall, but they caught onto that quickly and limited it. I was planning on asking him to open up traffic both ways on the ports, would you recommend something else?

GargoyleMT
DC++ Contributor
Posts: 3212
Joined: 2003-01-07 21:46
Location: .pa.us

Post by GargoyleMT » 2004-04-16 18:09

Opening traffic both ways on the ports will only let you download from other users who are also listening on port 1412. DC++ uses a random port, to avoid the opposite situation - where specific ports are blocked, but everything else is free.

Sorry, but DC++ isn't designed to be used behind a restrictive outbound firewall.

If there's enough demand, set up an internal DC hub instead. Many colleges seem to have done this.

vandalman
Posts: 4
Joined: 2004-04-16 14:46

Post by vandalman » 2004-04-16 19:13

GargoyleMT wrote:Opening traffic both ways on the ports will only let you download from other users who are also listening on port 1412.
That is why I'm creating a custom install. It will be set up on port 1412 by default. My version will be used and so everyone will be listing on port 1412.

Joris
Posts: 1
Joined: 2004-05-02 09:08

Post by Joris » 2004-05-27 15:00

If you have trouble with restrictive outbound access, I'm trying to add a customization to DC++ to have all outbound data access (for uploading that is) to use a single fixed port.

I'm trying to get this working over a firewall. On the LAN this seems to cause not a single issue, but on the Internet (going through the MS ISA Server) it doesn't work correctly. A single connection is set up correctly, but the firewall seems to drop packets after this. Even though FTP does work.
Unfortunally the microsoft.public ISA Server newsgroup doesn't know this problem either, they are system admins, not developers.

Perhaps this solutions does work for you behind a restrictive firewall.

Contact me at joris <dot> dobbelsteen <youarenotspamming?> <at> <mail> <dot> <com>

Locked