dingopride / iredmail

Automatically exported from code.google.com/p/iredmail
0 stars 0 forks source link

Firewall Script with different ssh port #28

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. change the port of sshd
2. reload sshd
3. install the server

What is the expected output? What do you see instead?
The new port installed in the script and instead in /etc/default/iptables
you will find empty at multiport line and 22 at the specific ssh port

What version of the product are you using? On what operating system?
5.1 on debian lenny

Original issue reported on code.google.com by antonio....@gmail.com on 3 Jan 2010 at 6:56

GoogleCodeExporter commented 9 years ago
Was the port number corrent in iRedMail-x.y.z/samples/iptables.rules after 
installation?

Original comment by michaelb...@gmail.com on 4 Jan 2010 at 4:56

GoogleCodeExporter commented 9 years ago
I mean I have sshd on port 222 and the script detected it but didn't put in the 
iptables, was an empty space.. I'm sure 'cause I installed it twice and had the 
same 
problem

Original comment by antonio....@gmail.com on 4 Jan 2010 at 2:03

GoogleCodeExporter commented 9 years ago
iRedMail detects SSHD port from /etc/ssh/sshd_config (Port 22), if you don't 
have this in sshd_config, iredmail 
may not detect correctly.

Original comment by michaelb...@gmail.com on 4 Jan 2010 at 2:09

GoogleCodeExporter commented 9 years ago
No no it was detected very well and I have  /etc/ssh/sshd_config configured on 
port 
222
but the line in /etc/default/iptables was:

# http/https, smtp/smtps, pop3/pop3s, imap/imaps, ssh
-A INPUT -p tcp -m multiport --dport 80,443,25,465,110,995,143,993,587,465, -j 
ACCEPT
and the script was not running 'cause of the "," before -j ACCEPT

by hand I added 222 at the end

# http/https, smtp/smtps, pop3/pop3s, imap/imaps, ssh
-A INPUT -p tcp -m multiport --dport 80,443,25,465,110,995,143,993,587,465,222 
-j 
ACCEPT

Original comment by antonio....@gmail.com on 5 Jan 2010 at 9:41

GoogleCodeExporter commented 9 years ago
Fixed.

Original comment by michaelb...@gmail.com on 16 Mar 2011 at 3:28