[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Re: How do I disable (close) ports?



-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Wed, 5 Dec 2001, Rolf Kutz wrote:

> J. Paul Bruns-Bielkowicz (jp@america.eu.org) wrote:
> >
> > I have a restricted services file and a default (open) services file. Some
> > services are disabled, i.e.
> > 9/tcp      open        discard
> > 13/tcp     open        daytime
> > 109/tcp    open        pop-2
> > 987/tcp    open        unknown
> > by commenting them out of /etc/services.
>
> Commenting out things in /etc/services doesn't
> disable anything. If you want to disable services,
> edit /etc/inetd.conf, /etc/hosts.allow,
> /etc/hosts.deny and the scripts in /etc/init.d/,
> but maybe that's what you meant.
>
> Then portscan you maschine to make sure, the ports
> are deactivated.
>
> - Rolf

If you do edit the init.d scripts don't forget to end the processes too.
Also don't just use a port scanner like nmap. have a look at lsof too

lsof -Pan -i tcp -i udp

It's quite useful.


-----BEGIN PGP SIGNATURE-----
Version: PGPfreeware 5.0i for non-commercial use
Charset: noconv

iQA/AwUBPA4PktZK+ucCabUAEQIsCQCg50isGcNUXXF3gFn9OsOa9G1es/cAn1zX
bxOS4dEjRcAfKgK04DrvZkHm
=46SW
-----END PGP SIGNATURE-----



Reply to: