How to protect code?

Ye' old general discussion board. Basically, for everything that isn't covered elsewhere. Come here to shoot the breeze, shoot your mouth off, or whatever suits your fancy.
This forum is not for asking programming related questions.

Moderator: General Moderators

Post Reply
User avatar
SmokyBarnable
Forum Contributor
Posts: 105
Joined: Wed Nov 01, 2006 5:44 pm

How to protect code?

Post by SmokyBarnable »

I wrote an application that works with a popular shopping cart. How do I protect my code and make sure it is still usable by anyone. Do I need something like a php encoder?
User avatar
John Cartwright
Site Admin
Posts: 11470
Joined: Tue Dec 23, 2003 2:10 am
Location: Toronto
Contact:

Post by John Cartwright »

Either host your code on your server, and provide it as a service or use an encoder. The problem with encoding it that it requires the server to have the neccesary decoder installed as well, which typically limits your user base.
User avatar
SmokyBarnable
Forum Contributor
Posts: 105
Joined: Wed Nov 01, 2006 5:44 pm

Post by SmokyBarnable »

so if I understand you correctly, part of my application would not be secure but it could call to my server for functionality?
User avatar
John Cartwright
Site Admin
Posts: 11470
Joined: Tue Dec 23, 2003 2:10 am
Location: Toronto
Contact:

Post by John Cartwright »

I'm not sure if I understood what you just said. Could you rephrase please.
User avatar
SmokyBarnable
Forum Contributor
Posts: 105
Joined: Wed Nov 01, 2006 5:44 pm

Post by SmokyBarnable »

If I host the code on my server how would I allow the customer to access it?
User avatar
Chris Corbyn
Breakbeat Nuttzer
Posts: 13098
Joined: Wed Mar 24, 2004 7:57 am
Location: Melbourne, Australia

Post by Chris Corbyn »

SmokyBarnable wrote:If I host the code on my server how would I allow the customer to access it?
I'm still not understanding. PHP code can never be seen by anyone unless they have access to your web server directly (i.e. direct access to the server via FTP or something). PHP is executed at the server and all the end-user sees is the result. If you're hosting code on your server all you have to do is give your customers the address of the page.

If you're referring to selling the code you wrote to other PHP developers to use in their own applications but you'd rather be closed-source, then yes you can encode it but you cut out a huge chunk of the market since the other developers need special software to run the code. PHP is by it's very nature an open-source language. I know it's personal opinion but I'm seeing way too many people trying to make it closed source these days which kind of ruins to whole community spirit of the language. Keeping the source visible to other developers who will use the code promotoes good development because nobody wants to release code against their name if it's not well written.
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Post by feyd »

Not to mention all the encoders have counterparts.

You're better off with a quality license.
User avatar
SmokyBarnable
Forum Contributor
Posts: 105
Joined: Wed Nov 01, 2006 5:44 pm

Post by SmokyBarnable »

I created a plug-in or a module for a popular shopping cart. So it would be part of their shopping cart. If I used the license method do I need to write something in the code that would call my server from time to time to see if the license is valid? How would I disable the application if the license is not valid?

Thanks.
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Post by feyd »

SmokyBarnable wrote:I created a plug-in or a module for a popular shopping cart. So it would be part of their shopping cart. If I used the license method do I need to write something in the code that would call my server from time to time to see if the license is valid? How would I disable the application if the license is not valid?

Thanks.
I'm not talking about software usage license. I'm talking licensing agreements; signed pieces of paper (or their digital equivalents.)
Post Reply