Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Getting around ISP sendmail (port 25) block...
View unanswered posts
View posts from last 24 hours

Goto page 1, 2  Next  
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
Zarathustra[H]
Guru
Guru


Joined: 30 Dec 2002
Posts: 389
Location: Cambridge, MA, USA

PostPosted: Sun Jun 01, 2003 11:39 pm    Post subject: Getting around ISP sendmail (port 25) block... Reply with quote

Hi.

As many of you know, a lot of ISP's (Including Verizon which I use) are trying to force their users to use their own SMTP server, which will only accept mail with the ISP email account in the "from" field.

This really pisses me off, and I am trying to find a way to get around it. I'm thinking of trying to either set up sendmail and have it tunnel through an external free proxy server, OR just tunnel through the free proxy server to an external SMTP server.

Problem is, I dont have a clue how to do this...

Anyone know where I can find more information on this subject?

Thanks,
Matt
_________________
----
Athlon 64 3000+ / 1Gb Kingston Hyperx PC3500 / MSI K8N Neo / Geforce 6800GT
----
Back to top
View user's profile Send private message
xedx
Tux's lil' helper
Tux's lil' helper


Joined: 23 May 2003
Posts: 93

PostPosted: Mon Jun 02, 2003 3:19 am    Post subject: ? Reply with quote

How bout running sendmail on a different port.
Check the docs :)

btw use qmail or postfix
you are endangering yourself using sendmail...
_________________
--+//+
Back to top
View user's profile Send private message
CinqueX
n00b
n00b


Joined: 26 Jan 2003
Posts: 58

PostPosted: Mon Jun 02, 2003 3:27 am    Post subject: install iptables... Reply with quote

#------------Verizon SMTP Server work-around---------------------

$IPTABLES -A INPUT -p tcp --dport 9999 -j ACCEPT
$IPTABLES -t nat -A PREROUTING -i eth0 -p tcp --dport 9999 -j REDIRECT --to-port 25

This iptables rule will listen on port 9999 and redirect your requests to your local mail server. $IPTABLES is usually /sbin/iptables. eth0 is your external interface facing the internet.

Regards,
Cinque
Back to top
View user's profile Send private message
joshdr77
Apprentice
Apprentice


Joined: 03 Jan 2003
Posts: 180

PostPosted: Mon Jun 02, 2003 3:31 am    Post subject: Reply with quote

hi, i have s imular problem, my ISP blocks traffic on port 80, and my school blocks all traffic on non-standard ports.....is there a way to work around this???

so i can get into my website from school...thanks
Back to top
View user's profile Send private message
xedx
Tux's lil' helper
Tux's lil' helper


Joined: 23 May 2003
Posts: 93

PostPosted: Mon Jun 02, 2003 3:34 am    Post subject: ? Reply with quote

Quote:

hi, i have s imular problem, my ISP blocks traffic on port 80, and my school blocks all traffic on non-standard ports.....is there a way to work around this???

so i can get into my website from school...thanks



u can use CinqueX's iptables snip or have ur httpd run on
a different port
:)
Back to top
View user's profile Send private message
joshdr77
Apprentice
Apprentice


Joined: 03 Jan 2003
Posts: 180

PostPosted: Mon Jun 02, 2003 3:55 am    Post subject: Reply with quote

i dont really understand how this all worls.

my ISP blocks port 80

i set my webserver to port 80

and put in that code into my ip tables

and some how it works?

im confused?
Back to top
View user's profile Send private message
xedx
Tux's lil' helper
Tux's lil' helper


Joined: 23 May 2003
Posts: 93

PostPosted: Mon Jun 02, 2003 3:58 am    Post subject: Reply with quote

joshdr77 wrote:
i dont really understand how this all worls.

my ISP blocks port 80

i set my webserver to port 80

and put in that code into my ip tables

and some how it works?

im confused?



that's portforwarding :)
_________________
--+//+
Back to top
View user's profile Send private message
joshdr77
Apprentice
Apprentice


Joined: 03 Jan 2003
Posts: 180

PostPosted: Mon Jun 02, 2003 4:02 am    Post subject: Reply with quote

yes, i know that, but if all traffic is blocked on port 80, how does my firewall know there is incoming traffic on port 80 and to port forwad all that traffic to another port.... :?

ill try to set it up now....but i dont think it work...
Back to top
View user's profile Send private message
xedx
Tux's lil' helper
Tux's lil' helper


Joined: 23 May 2003
Posts: 93

PostPosted: Mon Jun 02, 2003 4:24 am    Post subject: Reply with quote

joshdr77 wrote:
yes, i know that, but if all traffic is blocked on port 80, how does my firewall know there is incoming traffic on port 80 and to port forwad all that traffic to another port.... :?

ill try to set it up now....but i dont think it work...



ofcourse that wont work if you want it that way.
the iptables rule is only applicable if you dont want to change
your httpd config
:)
Back to top
View user's profile Send private message
joshdr77
Apprentice
Apprentice


Joined: 03 Jan 2003
Posts: 180

PostPosted: Mon Jun 02, 2003 4:29 am    Post subject: Reply with quote

LOL, i think we have lost track of my problem, i know i have..

my isp blocks all traffic on port 80 - in going and out going - think - all i know is that when i have a webserver running on that port...i cant get into..

but i run my website on port 8002 joshdr.pointclark.net:8002

at school they block all traffic from non standard ports...i cant get to port 8002.........i cant into into my site....

is there a way around this so i can access my site from home.....ill change ne config which needs to be done :) thanks
Back to top
View user's profile Send private message
joshdr77
Apprentice
Apprentice


Joined: 03 Jan 2003
Posts: 180

PostPosted: Mon Jun 02, 2003 4:30 am    Post subject: Reply with quote

LOL, i think we have lost track of my problem, i know i have..

my isp blocks all traffic on port 80 - in going and out going - think - all i know is that when i have a webserver running on that port...i cant get into..

but i run my website on port 8002 joshdr.pointclark.net:8002

at school they block all traffic from non standard ports...i cant get to port 8002.........i cant into into my site....

is there a way around this so i can access my site from home.....ill change ne config which needs to be done :) thanks
Back to top
View user's profile Send private message
Zarathustra[H]
Guru
Guru


Joined: 30 Dec 2002
Posts: 389
Location: Cambridge, MA, USA

PostPosted: Mon Jun 02, 2003 4:31 am    Post subject: Re: install iptables... Reply with quote

CinqueX wrote:
#------------Verizon SMTP Server work-around---------------------

$IPTABLES -A INPUT -p tcp --dport 9999 -j ACCEPT
$IPTABLES -t nat -A PREROUTING -i eth0 -p tcp --dport 9999 -j REDIRECT --to-port 25


Thank you...

Which brings back another problem.. I cant get IPTABLES to compile for the life of me. One or more of the modules it uses fails every time I try to compile the kernel with it enabled.

I get an error 2... :( I'm going to have to do more research on that...
_________________
----
Athlon 64 3000+ / 1Gb Kingston Hyperx PC3500 / MSI K8N Neo / Geforce 6800GT
----
Back to top
View user's profile Send private message
xedx
Tux's lil' helper
Tux's lil' helper


Joined: 23 May 2003
Posts: 93

PostPosted: Mon Jun 02, 2003 4:55 am    Post subject: Reply with quote

joshdr77 wrote:
LOL, i think we have lost track of my problem, i know i have..

my isp blocks all traffic on port 80 - in going and out going - think - all i know is that when i have a webserver running on that port...i cant get into..

but i run my website on port 8002 joshdr.pointclark.net:8002

at school they block all traffic from non standard ports...i cant get to port 8002.........i cant into into my site....

is there a way around this so i can access my site from home.....ill change ne config which needs to be done :) thanks


Look for a way to find out all allowed ports...
or try a higher port no.

:)
Back to top
View user's profile Send private message
xedx
Tux's lil' helper
Tux's lil' helper


Joined: 23 May 2003
Posts: 93

PostPosted: Mon Jun 02, 2003 4:57 am    Post subject: Re: install iptables... Reply with quote

Zarathustra[H] wrote:
CinqueX wrote:
#------------Verizon SMTP Server work-around---------------------

$IPTABLES -A INPUT -p tcp --dport 9999 -j ACCEPT
$IPTABLES -t nat -A PREROUTING -i eth0 -p tcp --dport 9999 -j REDIRECT --to-port 25


Thank you...

Which brings back another problem.. I cant get IPTABLES to compile for the life of me. One or more of the modules it uses fails every time I try to compile the kernel with it enabled.

I get an error 2... :( I'm going to have to do more research on that...


what error would that be?
maybe i have already encountered it...
:)
_________________
--+//+
Back to top
View user's profile Send private message
CinqueX
n00b
n00b


Joined: 26 Jan 2003
Posts: 58

PostPosted: Mon Jun 02, 2003 5:21 am    Post subject: try this.. Reply with quote

I have heard others report similar troubles.. their answer was to re-emerge gentoo-sources. They go to your /usr/src/linux/ dir, back up your .config and do a make mrproper. Copy your .config back to the kernel dir, make your menuconfig and try to compile.
Make sure you do a emerge iptables again.

Good luck.
Back to top
View user's profile Send private message
Diezel
l33t
l33t


Joined: 04 Feb 2003
Posts: 600
Location: Karjaa, Finland

PostPosted: Mon Jun 02, 2003 6:45 am    Post subject: Re: install iptables... Reply with quote

CinqueX wrote:
#------------Verizon SMTP Server work-around---------------------

$IPTABLES -A INPUT -p tcp --dport 9999 -j ACCEPT
$IPTABLES -t nat -A PREROUTING -i eth0 -p tcp --dport 9999 -j REDIRECT --to-port 25

This iptables rule will listen on port 9999 and redirect your requests to your local mail server. $IPTABLES is usually /sbin/iptables. eth0 is your external interface facing the internet.

Regards,
Cinque

Call me stupid(I am) but I really don't see how this works around the problem. If my ISP blocks port 25, no SMTP server can connect to my SMTP server or am I wrong. Doesn't SMTP's allways try to make the connection through port 25?
Correct me if I'm wron because if I am it's like christmas eve for me. I have Sennmail ready to fire up because I confed it last winter but becaus of the ISP I had to give up.

Cheers
_________________
A bus station is where a bus stops, a train station is where a train stops. On
my desk I have a work station..
Nixadmins.net
FLUG member 473
Back to top
View user's profile Send private message
CinqueX
n00b
n00b


Joined: 26 Jan 2003
Posts: 58

PostPosted: Mon Jun 02, 2003 7:29 am    Post subject: an explanation.. Reply with quote

ISP's typically block SMTP traffic IN to anything but their own SMTP server in an effort to prevent you as a spammer from sending out email to open-relays, and spam friendly mail servers from their IP block.

For this reason, if you do host your own email server, you will be blocked from connecting to them remotely through their packet filtering.

Most mail-admins do not want to have change their default SMTP port from 25, this makes it non-standard, and a pain in the a** for your users to connect to. The solution is to set up a dummy listening port (in this case 9999) that will accept connections and forward them locally on to port 25.

Verizon will likely not be filtering requests to 9999 (its not a popular service port), so requests to 9999 still get through their filters to the email server listening on port 25. Users who don't have this fascist ISP policy can still connect to your server on the standard port.

That was longer than I had intended.. but I hope it helped.

C.
Back to top
View user's profile Send private message
fragbert
Tux's lil' helper
Tux's lil' helper


Joined: 18 Apr 2003
Posts: 75
Location: Dallas, TX

PostPosted: Mon Jun 02, 2003 7:29 am    Post subject: Re: install iptables... Reply with quote

mahellma wrote:
Call me stupid(I am) but I really don't see how this works around the problem. If my ISP blocks port 25, no SMTP server can connect to my SMTP server or am I wrong. Doesn't SMTP's allways try to make the connection through port 25?


First of all, no, you are not stupid. :P All forwarded SMTP traffic will go to port 25, and there is nothing you can do about it. When a relay server forwards a message, it will check the DNS MX record for the @hostname... portion, and use what it finds there. The MX record cannot specify the port (or even the IP address directly). Basically there is no simple way of hosting your own publicly accessible e-mail server if your ISP is blocking traffic over port 25.



Michael
Back to top
View user's profile Send private message
Diezel
l33t
l33t


Joined: 04 Feb 2003
Posts: 600
Location: Karjaa, Finland

PostPosted: Mon Jun 02, 2003 7:32 am    Post subject: Re: install iptables... Reply with quote

fragbert wrote:
Basically there is no simple way of hosting your own publicly accessible e-mail server if your ISP is blocking traffic over port 25.
Michael


This is how I reasond it also. Thanks...
_________________
A bus station is where a bus stops, a train station is where a train stops. On
my desk I have a work station..
Nixadmins.net
FLUG member 473
Back to top
View user's profile Send private message
CinqueX
n00b
n00b


Joined: 26 Jan 2003
Posts: 58

PostPosted: Mon Jun 02, 2003 8:10 am    Post subject: Re: install iptables... Reply with quote

mahellma wrote:
fragbert wrote:
Basically there is no simple way of hosting your own publicly accessible e-mail server if your ISP is blocking traffic over port 25.
Michael


This is how I reasond it also. Thanks...


That premise is flawed. The question is whether your ISP blocks incoming traffic TO port 25 (to prevent you from hosting an email server) OR blocking OUTGOING traffic to foreign SMTP servers.

Either way, MX records have nothing to do with it.

C.
Back to top
View user's profile Send private message
Diezel
l33t
l33t


Joined: 04 Feb 2003
Posts: 600
Location: Karjaa, Finland

PostPosted: Mon Jun 02, 2003 8:26 am    Post subject: Reply with quote

The outgoing trafic works fine, but nbothing comes in so that kind of kills the eager to set up an mail server :(
_________________
A bus station is where a bus stops, a train station is where a train stops. On
my desk I have a work station..
Nixadmins.net
FLUG member 473
Back to top
View user's profile Send private message
joshdr77
Apprentice
Apprentice


Joined: 03 Jan 2003
Posts: 180

PostPosted: Mon Jun 02, 2003 8:38 am    Post subject: Reply with quote

Hey

to get back to my problem.........Im with OptusNet........in australia......i think that they block incoming traffic to port 80, and not sure abut out going, but it is probably block to...

is there anyway to get a webserver working on port 80 if it is blocked...

im running my server on [url]http://joshdr.pointclark.net:8002/[img] as u can see port 8002......but at school all ports are blocked...

u tried to help me b4, one of you, but u didnt quite understand what im asking.....

i want to be able to run web traffic on port 80......is there any way at all to do this? thanks[/img][/url]
Back to top
View user's profile Send private message
Diezel
l33t
l33t


Joined: 04 Feb 2003
Posts: 600
Location: Karjaa, Finland

PostPosted: Mon Jun 02, 2003 9:14 am    Post subject: Reply with quote

EDIT= Sorry DIDN'T read the question properly.
_________________
A bus station is where a bus stops, a train station is where a train stops. On
my desk I have a work station..
Nixadmins.net
FLUG member 473


Last edited by Diezel on Tue Jun 03, 2003 5:39 am; edited 1 time in total
Back to top
View user's profile Send private message
Zarathustra[H]
Guru
Guru


Joined: 30 Dec 2002
Posts: 389
Location: Cambridge, MA, USA

PostPosted: Mon Jun 02, 2003 2:51 pm    Post subject: Reply with quote

Hey I'm still working on the IPTABLES problem.. The make mrproper didnt work for me... :(

Meanwhile..

I have decided, against your warnings (sorry) to use sendmail after all, as my preferred email client (evolution) can interface sendmail directly.

Problem I am having thouhg, is that only root can access sendmail for some silly reason...

Code:

matt@localhost matt $ sendmail
bash: sendmail: command not found
matt@localhost matt $ su
Password:
root@localhost matt # sendmail
^C
root@localhost matt #


Does anyone know why this is, or how to fix it?

Thanks,
Matt
_________________
----
Athlon 64 3000+ / 1Gb Kingston Hyperx PC3500 / MSI K8N Neo / Geforce 6800GT
----
Back to top
View user's profile Send private message
uzik
Apprentice
Apprentice


Joined: 17 Apr 2003
Posts: 257

PostPosted: Mon Jun 02, 2003 4:13 pm    Post subject: Reply with quote

joshdr77 wrote:
hi, i have s imular problem, my ISP blocks traffic on port 80, and my school blocks all traffic on non-standard ports.....is there a way to work around this???

so i can get into my website from school...thanks


This can't be right... They're block everything? Why connect you at
all if everything is blocked? Are you sure they just aren't blocking
'proscribed' web sites instead of all web traffic?
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Goto page 1, 2  Next
Page 1 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum