Operating System - HP-UX
1849992 Members
3864 Online
104049 Solutions
New Discussion

How to determine if mountd is running on reserved ports?

 
Duke Nguyen
Occasional Advisor

How to determine if mountd is running on reserved ports?

rpcinfo returns the following info:
/etc/rc.config.d # rpcinfo -p |grep mountd
100005 1 udp 49213 mountd
100005 3 udp 49213 mountd
100005 1 tcp 49163 mountd
100005 3 tcp 49163 mountd

Are these ports reserved? I am NOT using the "-p" option when starting mountd.

I was told that these ports are unreserved and cound pose a security risk. I've read on another post that these ports are privileged ports and root can only access these ports...can someone please confirm for me?

Thanks.
7 REPLIES 7
G. Vrijhoeven
Honored Contributor

Re: How to determine if mountd is running on reserved ports?

Hi Duke,

If you read man rpcinfo:

-p Run from unreserved ports.The option restores old default behavior on HP-UX. .....

So if you start mountd without the -p option you run on reserved ports.

Hope this will help,

Gideon
harry d brown jr
Honored Contributor

Re: How to determine if mountd is running on reserved ports?

Download "lsof" from:
http://hpux.cs.utah.edu/hppd/hpux/Sysadmin/lsof-4.55/

and it will tell you what application has what sockets open, plus its one kick-butt tool for other things as well!


live free or die
harry
Live Free or Die
Duke Nguyen
Occasional Advisor

Re: How to determine if mountd is running on reserved ports?

Is it true that ports greater than 1023 are all reserved ports? And that only root can access reserved ports on the local machine?
harry d brown jr
Honored Contributor

Re: How to determine if mountd is running on reserved ports?

No. Typically we like to say that reserved root ports are less than 1023, but this is not always the case, ie: WEB servers using ports 80 and 443.

live free or die
harry
Live Free or Die
Duke Nguyen
Occasional Advisor

Re: How to determine if mountd is running on reserved ports?

Thanks Harry...but I'm a little confused right now.
If mountd is NOT being started with the "-p" option, then how come mountd uses ports in the 49213 range? Shouldn't mountd use reserved ports under 1023 since the "-p" is not being used?
James R. Ferguson
Acclaimed Contributor

Re: How to determine if mountd is running on reserved ports?

Hi Duke:

RFC 1700 defines "well-known" or "assigned" ports as those in the range 0-1023. Ports in the range 1024-65535 are known as "registered" ports. That is, their usage is not controlled, but their intended use is officially documented.

Prior to HP-UX 10.30, port numbers were chosen from the range 1024 to 5000 whenever a program let the system allocate ???anonoymously??? (bind to port number zero). Starting with HP-UX 10.30, the "anonymous" range moved to 49152-65535, by default.

In 11.x releases, the maximum automatically assigned port number can be changed with the ???tcp_largest_anon_port??? and ???udp_largest_anon_port??? using ???ndd???

Regards!

...JRF...
Duke Nguyen
Occasional Advisor

Re: How to determine if mountd is running on reserved ports?

Does mountd running on ports 49213 range cause a security concern? If so, would running mountd with the "-p" option make mountd use a port below 1023? Thanks in advance.