For example, any conversation bound for an FTP application uses the standard port number 21. Conversations that do not involve an application with a well-known port number are, instead, assigned port numbers that are randomly selected from within a specific range. These port numbers are used as source and destination addresses in the TCP segment. Numbers 255-1023 are assigned to companies for marketable applications. Numbers above 1023 are unregulated.
End systems use port numbers to select the proper application.
Originating source port numbers, usually some numbers larger than 1023, are dynamically assigned by the source host.