Re: CSocket::Create() - port allocation

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



The change in the ephemeral port allocation postdates the release of VS6. Therefore,
older systems allocate ephemeral ports in the low range; newer systems allocate ephemeral
ports in the new range.
joe

On Fri, 20 Oct 2006 03:05:02 -0700, len <len@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote:

Hi there.

I'm using Visual C++ 6 and have an application that uses CSocket::Create()
to allocate a TCP/IP listening port - with a value of 0 passed in as the port
number so that MFC will take care of the allocation.

When I do this, I find that the ports allocated range from 1024 upwards. Is
this correct? Shouldn't the ports allocated range from 49152 through 65535 in
order to avoid the Registered Ports?

Any info would be appreciated!
Joseph M. Newcomer [MVP]
email: newcomer@xxxxxxxxxxxx
Web: http://www.flounder.com
MVP Tips: http://www.flounder.com/mvp_tips.htm
.



Relevant Pages

  • Re: No more floppy drive
    ... Basically, systems that have AML that claim 0x3f2-0x3f5,0x3f7 are ... correct and we need to only allocate those ports. ...
    (freebsd-current)
  • Re: newbus ioport usage
    ... allocate all ports at boot time, ... attach the second one fail. ...
    (freebsd-arch)
  • Re: Ports 0-1023?
    ... > Is there any point in needing to be root in order to allocate the low ... > simply be used that says a particular UID can allocate a particular range ... > of ports? ... Let's say you don't need to be root anymore. ...
    (Vuln-Dev)
  • Re: Ports 0-1023?
    ... > Is there any point in needing to be root in order to allocate the low ports ... > Could some sort of port ACL simply be used that says a particular UID ...
    (Vuln-Dev)
  • Re: Ports 0-1023?
    ... > Is there any point in needing to be root in order to allocate the low ports ... It's a dangerous situation, ... Imagine a situation, when on your server ...
    (Vuln-Dev)