Linux - SecurityThis forum is for all security related questions.
Questions, tips, system compromises, firewalls, etc. are all included here.
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
I recently decided to port scan my penguin and I saw lots of open ports. This lead to a small port closing spree, I edited inetd.conf and one or two startup scripts. The TCP ports were relatively easy to close, but I have no clue how to close the open UDP ports ! Where are the services that open these ports, are they started by the kernel
As root on the box, "netstat -anp", trace PID for opened port to running binary of process. Shut down using init scripts and remove package from system if not used *now*. If no running process for given port, check firewall for policy and port blockings, also see ICMP (error messages in case of UDP port).
thanks unSpawn I did what you said and it helped me see where the rpc-portmap service was coming from, but I better add that I used Network Security Scanner from a win based platform to scan the ports, now the linux port scanner that I just recently tried does not respond in the same way at all, in fact it only reports two open udp ports, sun-rpc and time, which corresponds much better to what I left open.
This has lead me to think that the port scanner I was using is completely buggy.
No, that ain't completely true. Port scanners like Nmap and NSS rely on return traffic to determine which ports are open. They look up the port in a static list (like /etc/services) to determine the service running. If you need to verify an app/daemon running on a port, use a protocol-specific scanner that does banner grabbing or Nessus or netcat to the port yourself.
Haven't got a clue wrt NSS as it's Wintendo and I don't (want to have to) handle that. It's only the protocol/port/common name triplet that the list is searched for. The list itself doesn't affect the amount of ports shown or their state. Basically what affects state is the commandline switches you use to scan and the "intelligence" of the scanner to interprete the return traffic.