Re: How to close the unnecessary Ports
From: Winged (Winged_at_nofollow.com)
Date: 10/02/05
- Next message: Hairy One Kenobi: "Re: How to close the unnecessary Ports"
- Previous message: Imhotep: "Re: VoIP wiretapping rules to be considered"
- In reply to: Nick: "How to close the unnecessary Ports"
- Next in thread: Hairy One Kenobi: "Re: How to close the unnecessary Ports"
- Reply: Hairy One Kenobi: "Re: How to close the unnecessary Ports"
- Reply: Nick: "Re: How to close the unnecessary Ports"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Date: Sat, 01 Oct 2005 18:10:50 -0500
Nick wrote:
> Hi
>
> As there are over 65000 ports in the TCP/IP stack, which ones are the most
> necessary ports for a homeuser and how to close the rest of the ports? My PC
> is connected to internet via a router and a cable modem. I run ZA firewall
> and BHODemon 2.0 thanks to the help from Mr.Lipman. Here is a ports link I
> found online:
> http://www.iss.net/security_center/advice/Exploits/Ports/default.htm
>
> Thanks in advance!
> Nick
>
>
There are two, (generally speaking) types of port ranges on your
computer. The server port range is generally considered ports below
1024. Most home users (generally) do not need to receive inbound
connections from the Internet over these ports unless they are hosting a
server.
The ephemeral ports 1024-65565 are considered (generally) response ports.
TCP/IPv4 connection consists of two endpoints, and each endpoint
consists of an IP address and a port number. Therefore, when a client
user connects to a server computer, an established connection can be
thought of as the 4-tuple of (server IP, server port, client IP, client
port). Usually three of the four are readily known -- client machine
uses its own IP address and when connecting to a remote service, the
server machine's IP address and service port number are required.
What is not immediately evident is that when a connection is established
that the client side of the connection uses a port number. Unless a
client program explicitly requests a specific port number, the port
number used is an ephemeral port number. Ephemeral ports are temporary
ports assigned by a machine's IP stack, and are assigned from a
designated range of ports for this purpose. When the connection
terminates, the ephemeral port is available for reuse, although most IP
stacks won't reuse that port number until the entire pool of ephemeral
ports have been used. So, if the client program reconnects, it will be
assigned a different ephemeral port number for its side of the new
connection.
Similarly, for UDP/IP, when a datagram is sent by a client from an
unbound port number, an ephemeral port number is assigned automatically
so the receiving end can reply to the sender.
I assume you are refer to MS systems as port restrictions on Nix systems
are pretty straight forward.
To restrict what ephemeral ports windows will use to listen on:
http://support.microsoft.com/default.aspx?scid=kb;en-us;300083
The server ports typically should be completely blocked from Internet
exposure on most home systems. Additionally running services should be
reduced to a bare minimum of what is required on the system.
A good list of service definitions and what you need is here:
http://www.ss64.com/ntsyntax/services.html
http://inside.bard.edu/~winig/BlackViper.doc
A final step is needed. You should block all ports at your firewall not
required. Most home users will want to block all inbound connections
below 1024. Additionally you should only allow inbound connections to
those ports you set following the MS procedure above, and block other
communication.
Without knowing a bit more about your firewall choices or your explicit
requirements it is a bit difficult to provide precise guidance.
Hopefully you will find something here that has answered your question.
Winged
- Next message: Hairy One Kenobi: "Re: How to close the unnecessary Ports"
- Previous message: Imhotep: "Re: VoIP wiretapping rules to be considered"
- In reply to: Nick: "How to close the unnecessary Ports"
- Next in thread: Hairy One Kenobi: "Re: How to close the unnecessary Ports"
- Reply: Hairy One Kenobi: "Re: How to close the unnecessary Ports"
- Reply: Nick: "Re: How to close the unnecessary Ports"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Relevant Pages
|