4 Replies - 656 Views - Last Post: 07 April 2011 - 09:55 AM

#1 creativecoding  Icon User is offline

  • Hash != Encryption
  • member icon


Reputation: 926
  • View blog
  • Posts: 3,204
  • Joined: 19-January 10

Using "official" ports

Posted 06 April 2011 - 08:30 PM

Is it illegal to use "official" ports? I am learning some stuff in c# that uses ports for data transfer, and while looking on wikipedia for port numbers, I saw that they have "official" ports and "unofficial" ports registered with the IANA (lol people who manage internet numbers). So would it be illegal to use these official ports? Will I have to register my own port for a program if I decide to publish it?
Is This A Good Question/Topic? 0
  • +

Replies To: Using "official" ports

#2 Amrykid  Icon User is offline

  • 4+1=Moo
  • member icon

Reputation: 148
  • View blog
  • Posts: 1,589
  • Joined: 16-December 08

Re: Using "official" ports

Posted 06 April 2011 - 08:50 PM

View Postcreativecoding, on 06 April 2011 - 10:30 PM, said:

Is it illegal to use "official" ports? I am learning some stuff in c# that uses ports for data transfer, and while looking on wikipedia for port numbers, I saw that they have "official" ports and "unofficial" ports registered with the IANA (lol people who manage internet numbers). So would it be illegal to use these official ports? Will I have to register my own port for a program if I decide to publish it?

No, its not illegal. Several programs use the same port just like several programs uses the same file extension.
Was This Post Helpful? 0
  • +
  • -

#3 Sethro117  Icon User is offline

  • Still the sexiest mofo.
  • member icon

Reputation: 236
  • View blog
  • Posts: 2,378
  • Joined: 14-January 09

Re: Using "official" ports

Posted 06 April 2011 - 10:36 PM

Its not illegal, thats why they're there. However since they are more well known the chances of getting attacked also increase so proper security is a must.
Was This Post Helpful? 0
  • +
  • -

#4 AdaHacker  Icon User is offline

  • Resident Curmudgeon

Reputation: 452
  • View blog
  • Posts: 811
  • Joined: 17-June 08

Re: Using "official" ports

Posted 07 April 2011 - 08:13 AM

View Postcreativecoding, on 06 April 2011 - 10:30 PM, said:

So would it be illegal to use these official ports? Will I have to register my own port for a program if I decide to publish it?

No and no. In fact, if you look at the list of port number, you'll see that it says they "SHOULD NOT" be used without registration. In this context, "SHOULD NOT" is actually a technical term used in RFCs and is defined here:

Quote

4. SHOULD NOT This phrase, or the phrase "NOT RECOMMENDED" mean that
there may exist valid reasons in particular circumstances when the
particular behavior is acceptable or even useful, but the full
implications should be understood and the case carefully weighed
before implementing any behavior described with this label.


So really, registration is just a recommendation. There is no requirement to do it or to not reuse registered ports. In fact, you'll find that many people freely disregard port registration for pretty much everything outside the "Well Known Ports" range, i.e. ports higher than 1024. In other words, don't worry about it.
Was This Post Helpful? 0
  • +
  • -

#5 baavgai  Icon User is offline

  • Dreaming Coder
  • member icon

Reputation: 5761
  • View blog
  • Posts: 12,574
  • Joined: 16-October 07

Re: Using "official" ports

Posted 07 April 2011 - 09:55 AM

Then again, there's no real reason to use an "official" port. Port 7 means every network scan will probably want to say hi to you. Port 138 on a windows network is usually pretty noisy.

Do you really want other network devices knocking on your door when you're just trying to write code?
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1