Page 1 of 1

How to block port 389 when ldap is allowed as a service

Posted: 2017/09/11 15:31:25
by ddolecki108
# firewall-cmd --zone=public --list-services
dhcpv6-client ldap ssh ldaps
# firewall-cmd --zone=public --list-ports
9830/tcp


So, I am testing secure ldap and would like to block ldap(port 389), how do I do that without modifying the service?.....

Thanks in advance....

Re: How to block port 389 when ldap is allowed as a service

Posted: 2017/09/11 16:40:57
by hunter86_bg
# firewall-cmd --info-service=ldap
ldap
ports: 389/tcp
protocols:
source-ports:
modules:
destination:
It seems that service "ldap" contains only that port, so you can safely remove it from your configuration:

Code: Select all

firewall-cmd --permanent --remove-service=ldap && firewall-cmd --reload
Note: You can temporarily remove it (skip the "--permanent" and the reload) for a short test.

Re: How to block port 389 when ldap is allowed as a service

Posted: 2017/09/11 17:42:56
by ddolecki108
THANK YOU