more of a port curiousity question

This is a discussion on more of a port curiousity question within the Tech Board forums, part of the Community Boards category; I have always wondered why automatically assigned ports in BSD sockets range from 1024 to 5000... can anyone tell me ...

  1. #1
    Registered User
    Join Date
    Apr 2007
    Posts
    32

    more of a port curiousity question

    I have always wondered why automatically assigned ports in BSD sockets range from 1024 to 5000... can anyone tell me why is this?

  2. #2
    and the hat of wrongness Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    32,344
    http://www.iana.org/assignments/port-numbers
    0 to 1023 are reserved.
    Your OS probably treats the range you observe as a pool of ports to use, so it picks the next free one in that range.

    This isn't a C question, moved.
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.
    I support http://www.ukip.org/ as the first necessary step to a free Europe.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Concurrent chat, Sockets
    By jakemott in forum Linux Programming
    Replies: 6
    Last Post: 11-29-2008, 04:41 PM
  2. Question on Accessing parallel port
    By Luciferek in forum C++ Programming
    Replies: 6
    Last Post: 06-16-2008, 05:36 PM
  3. multiplexing
    By kaijuu in forum C Programming
    Replies: 0
    Last Post: 03-29-2008, 06:47 AM
  4. brace-enclosed error
    By jdc18 in forum C++ Programming
    Replies: 53
    Last Post: 05-03-2007, 05:49 PM
  5. DOS, Serial, and Touch Screen
    By jon_nc17 in forum A Brief History of Cprogramming.com
    Replies: 0
    Last Post: 01-08-2003, 03:59 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21