Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game. |
| Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
 |
GNU/Linux Basic Guide
This 255-page guide will provide you with the keys to understand the philosophy of free software, teach you how to use and handle it, and give you the tools required to move easily in the world of GNU/Linux. Many users and administrators will be taking their first steps with this GNU/Linux Basic guide and it will show you how to approach and solve the problems you encounter.
Click Here to receive this Complete Guide absolutely free. |
|
 |
09-14-2012, 12:40 AM
|
#1
|
|
Member
Registered: Aug 2012
Location: Chiang Mai, Thailand
Distribution: Kubuntu 12.10 x86_64
Posts: 190
Rep:
|
Make a closed-source C Program for Windows, Mac and Linux/Unix.
I am helping my family doing some bisuness, and the software is for sale. But, I will show some parts of the program to the forums. The question is, how do I hide the source code?
So people don't copy and distribute it for free.
This is the first time for me making a closed-source software.
|
|
|
|
09-14-2012, 01:36 AM
|
#2
|
|
Member
Registered: Jul 2004
Location: Chennai, India
Distribution: UBUNTU 5.10 since Jul-18,2006 on Intel 820 DC
Posts: 543
Rep:
|
If it is pure html or html with embedded javascript then what you say may be true.
However if it is server based, then what gets rendered in the browser is only the result. ie. source code isn't shown. Likewise for javascript in "included" files (<SCRIPT LANGUAGE=javascript SRC="<yoursourcegoeshere>")
If the project is not web based, then whats the problem?
OK
|
|
|
|
09-14-2012, 03:09 AM
|
#3
|
|
Senior Member
Registered: Oct 2011
Location: Budapest
Distribution: Debian/GNU/Linux, AIX
Posts: 1,079
|
Relax, nobody will steal your code.
|
|
|
|
09-14-2012, 04:07 AM
|
#4
|
|
Member
Registered: Oct 2004
Distribution: Debian Squeeze x86_64
Posts: 935
Rep:
|
But they may reverse engineer it and steal your soul.
No honestly if you provide only the compiled program there is a low chance anyone "stealing" the source code.
But like with everything if you give something to someone you never can be sure what he will do with it. And can not be prevented with any means. Beside locking him up and erasing his memory and feelings afterwards so he can't even remember a single bit *pun intended*.
But I would not think about such malice there are more nice people than evil people. Just make a decent price and people will refrain from illegal stuff like sharing or distributing it through dark channel.
|
|
|
|
09-14-2012, 08:06 AM
|
#5
|
|
Senior Member
Registered: Feb 2004
Location: SE Tennessee, USA
Distribution: Gentoo, LFS
Posts: 4,579
|
Since I do this sort of thing professionally, I can advise ... and I'm not going to say perhaps what you expect from someone who is posting "here."
What you would need to be able to do is to build installers for each environment ... appropriate to each environment ... and to thoroughly validate and test your program in all of them, and to maintain that for every customer going forward. ("Virtual machines," run by purchased software such as VMWare on whatever host-environment most suits you, and externally connected hard-drives, are ideal for this, because you do need isolated environments but you don't need a room full of computers.)
Important: This represents an ongoing expense-item that you will need to factor into the ongoing cost of your product. You need to sell the product with mandatory periodic maintenance fees, which you should handle by means of, say, a PayPal "subscription" that collects money several times each year. You need to thoroughly plan-out the maintenance and support equation.
Only the Linux environments can be expected to support "open-source" installations. Neither OS/X nor certainly Windows users customarily have any sort of language-compiler on their systems. Furthermore, even the preponderance of Linux users really don't care whether the product that runs their family business is "open source" or not: they want a drop-dead easy, guaranteed-to-work installation process, and a toll-free telephone number (hint: use Skype instead) to call if it does not.
Environments can be subtle. Both Apple and Microsoft right now are making rather big changes to their systems, partly to steer them in the direction of portable devices which they fear are taking hold. Those differences can be problematic for you.
Seriously consider whether you really want to support all three environments at once. Poll your potential customers to find out. Do an inventory of the competition and see where they have chosen to concentrate their efforts. People who really like your product just might go and purchase "whatever computer you tell them to" just to use your product on it. The name of the game is profitability, and "dissipation" is a good way to lose those profits. In other words, move in the directions that your paying clients tell you to.
A business-plan will be very important at these early stages, for your family (your "internal clients") and for you ("the IT manager"). Really test those waters, really work-out the thing on paper, "discover every thing that might possibly bite you in the asterisk before it has a chance to do so, so that it never does." Engage every business stakeholder: you, your family, maybe some potential customers. "Forewarned is forearmed."
Last edited by sundialsvcs; 09-14-2012 at 08:08 AM.
|
|
|
|
09-14-2012, 08:22 AM
|
#6
|
|
Member
Registered: Aug 2012
Location: Chiang Mai, Thailand
Distribution: Kubuntu 12.10 x86_64
Posts: 190
Original Poster
Rep:
|
i just found out. I think I will use base64 to encode and the installer will decode. thanks.
|
|
|
|
09-14-2012, 08:50 AM
|
#7
|
|
Member
Registered: Oct 2004
Distribution: Debian Squeeze x86_64
Posts: 935
Rep:
|
base64 encoding is in now way a secure encryption. (Nearly) Every programming language holds a function to decode that.
|
|
|
|
09-14-2012, 01:27 PM
|
#8
|
|
Member
Registered: Apr 2010
Location: USA
Distribution: Debian, Ubuntu, Fedora, RedHat, DSL, Puppy, CentOS, Knoppix
Posts: 732
Rep: 
|
C, really using C?
If you are programming in anything that compiles down to an executable (or executable and specific libs) you simply hide the source and only allow installation of your executable and libs. This easily gives the end users access ONLY to your product, but not to the source code.
While it is possible to reverse-engineer software from the executable, it is not something most people could handle.
If you share a machine with some of these people, consider doing your development work in a TRUECRYPT folder so that all of your source will be encrypted and only available to someone who knows your password. And do NOT share that password!
|
|
|
|
09-14-2012, 04:10 PM
|
#9
|
|
Senior Member
Registered: Nov 2005
Distribution: Debian
Posts: 2,056
|
Quote:
Originally Posted by AnanthaP
However if it is server based, then what gets rendered in the browser is only the result. ie. source code isn't shown. Likewise for javascript in "included" files (<SCRIPT LANGUAGE=javascript SRC="<yoursourcegoeshere>")
|
Not true for the javascript case: the code is executed on the browser so the code must be downloadable by the browser.
Quote:
|
Originally Posted by suttiwit
I think I will use base64 to encode and the installer will decode.
|
huh? 
|
|
|
|
09-15-2012, 07:15 PM
|
#10
|
|
Member
Registered: Jul 2004
Location: Chennai, India
Distribution: UBUNTU 5.10 since Jul-18,2006 on Intel 820 DC
Posts: 543
Rep:
|
Quote:
Quote:
Originally Posted by AnanthaP
However if it is server based, then what gets rendered in the browser is only the result. ie. source code isn't shown. Likewise for javascript in "included" files (<SCRIPT LANGUAGE=javascript SRC="<yoursourcegoeshere>")
Not true for the javascript case: the code is executed on the browser so the code must be downloadable by the browser.
|
You are right. It is executed in the front-end (browser). They are 2 different things.
What I meant to say was that the contents of the included scripts aren't visible in the "view source" option of the browser.
OJ
|
|
|
|
09-16-2012, 11:33 AM
|
#11
|
|
Senior Member
Registered: Nov 2005
Distribution: Debian
Posts: 2,056
|
Quote:
Originally Posted by AnanthaP
What I meant to say was that the contents of the included scripts aren't visible in the "view source" option of the browser.
|
In Firefox, the src attribute is a clickable link that leads to the script's source. At any rate, anyone who can view the source of the web page can also view the source of included javascript files.
|
|
|
|
| Thread Tools |
Search this Thread |
|
|
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
All times are GMT -5. The time now is 02:38 AM.
|
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|