PHP – Choosing the Right License for a Private Project

licensingPHP

The project in which work is private for commercial purposes and not its source code is distributed to anyone. Only the functional application shown consumers through a website.

It has the following structure:

  • The source code is written in PHP, the only part where third-party code is used when using Composer and PHPUnit.
  • HTML, CSS, Javascript technologies are used (with free third-party libraries)
  • Server-side MySQL server, PHP, and Memcached is used.
  • And the server is not a shared hosting, is a VPS.

We do not want anyone to see our source code, but if for any reason our code is stolen or otherwise obtained, we want to have a license that does not allow disclosure of any kind.

My questions are:

Is this type of project with third-party code and private code compatible?

Is it possible to license these works?

Best Answer

The simple answer is "don't license your code." Instead, place a copyright statement on your code (which you should have done anyway) and add a statement to the effect that no one is allowed to use your code.


Here's the longer answer:

We do not want anyone to see our source code, but if for any reason our code is stolen or otherwise obtained, we want to have a license that does not allow disclosure of any kind.

If someone steals your code, they're not terribly interested in how you may have licensed that code. They wanted it and stole it, there's nothing a license will do to prevent them from using it as they please based upon the fact that they stole your code.

More broadly, a license is there to give permission to others in order to use code that you created. The license dictates the terms that others have to follow, and specifies how they may use your code.

As you don't want anyone using your code then you shouldn't put a license on it.

Related Topic