I have this project that I am working on which I want to share/sell. but I don’t want people to make changes to my work, or see the source code.
I thought obfuscating might be a good solution, but I basically have to redo most of the logic if I want to use obfuscation now, and yes I am aware that people can always de-obfuscate.
How do other people share or sell their projects while keeping their source code protected? Any help or tips would be appreciated as I am out of Ideas.
You can return a module everytime until the person quits of trying to see the source code.
But the problem is that it would take too much time
Alright, here are two options:
Option
Note: NOT RECOMMENDED
But try this:
Create a module and rename it MainModule and publish it into roblox:
local function sourceCode()
-- your source here
end
local module = {}
return function()
sourceCode()
end
Make another one with the same name and instance and publish it too:
local source = require(*id of the first module in the first step*)
return source
Make the 3rd module (yes, again) and publish it
local source = require(*id of the second module in the second step*)
return source
And you can continue.
NOTE: I DONT RECOMMEND DOING WHAT I JUST TOLD YOU
Or you can’t. If you don’t want that other option, then it’s not gonna be possible to protect, bcs roblox everytime, when you’re in a asset page, there’s a toolbox to show the sources and every instance that published it with
Obfuscating your code for selling or sharing is just a really bad idea.
It will make the code look sketchy and people won’t use it or buy it, I don’t think anyone would like to insert obfuscated code in their games, when they don’t even know what the code exactly does.
There’s no way to “keep your source code safe” while also sharing/selling it, showing the source code is a way to tell everyone that your code is trustable and if they don’t trust it they can check it by themselves.
If your plan to share/sell your code, just don’t think on “Protecting your source code”. Showing the source code is the best way to tell everyone that your job is trustable.
I am aware of the negatives of obfuscation and i am not a big fan of implementing it. There has to be some way to protect my code from theft, but thanks for your advice anyway it is something I do agree with.
Selling your obfuscated code is just hideous and worthless, as doing this is dangerous, as a buyer may think the code has a IP logger(they exist), thus not buying the code. There is another major flaw, if the buyer made a vid about the product’s “harm”, the consumer may not use the software, so it’s just a Lose-Lose situation.
This thread is kinda turning aggressive. This person asked for support with this because they don’t know. We can’t respond like they know the customs of sharing assets.
I am closing the thread, as I am no longer getting useful advice. I think the only option for me is to figure out how to work with licenses to somewhat protect my own work.
Hey, I know you said you are closing this, but I thought I’d offer a solution anyway because people have no idea what they are talking about, obfuscation is a great thing & is used in many cases in a lot of apps.
I haven’t gotten too deep into this, but this app I just found seems like it works really well & should do exactly what you are looking for. Now, it is technically POSSIBLE someone edits your code but they would have to be extremely skilled & it would be relatively hard to do.
Speaking from experience here: Out in the software industry, the bottom line is you can’t. Companies like Google, Apple, and Microsoft would love it if you couldn’t disassemble the object code and translate it back into source code. Yeah, you can obfuscate your code and whatnot, encrypt it even and run it in a virtual machine. But the issue is that if the CPU can execute it, then so can someone who want’s to look at it.
The only true way of protecting your program is not not release it at all. But then what’s the point? There are secured hardware solutions like running the code on a single chip computer such as a microcontroller or digital signal processor, or what game console developers do (Sony PlayStation, Microsoft X-Box, Nintendo) which is to use custom silicon that’s basically a CPU with several MB of flash memory on it. If the program is small enough, and depending on what you are trying to do, you can run it from a smart card chip which is secure by design (This includes the chips on your credit/bank debit cards).
Other than that, the only thing that you can do is to register your code for copyright with the copyright, patent, and trademark office in your country of residence. If someone messes with your code (or steals it), you have the force of law on your side under the Berne Convention (WIPO International Copyright Treaty) to legally go after them, which people have done.
Actually, people do it all the time. Windows, iOS, phone/tablet apps, etc… Any commercial software really. Even Roblox itself (client, studio, server) isn’t open source. Granted, some components are, like the LUA interpreter, but the rest? Nope.
Protecting your source code while sharing or selling your projects is indeed a common concern in the software development world. While it’s nearly impossible to achieve absolute protection, there are a few strategies you can consider to make it more difficult for others to access or modify your code:
License and Legal Protection:
Use licenses: You mentioned licenses, and they can be a valuable tool. Utilize licenses like open-source licenses or commercial licenses to define how others can use your code. Make sure to include a license agreement that outlines what users can and cannot do with your code.
Copyright notices: Include clear copyright notices in your code and project documentation to indicate your ownership of the code.
Obfuscation:
While you mentioned that obfuscation might be a bit challenging for your current project, it’s still an option for making the code harder to read. It won’t provide complete protection, but it can be a deterrent.
Hosting:
Use a cloud-based service to host your project: Hosting your project on a cloud service can provide an extra layer of security by limiting access to your source code. Users will interact with the compiled/obfuscated version rather than the raw source code.
Compiled Code:
Distribute compiled executables or bytecode instead of the raw source code. This makes it more difficult for others to modify the code.
APIs and Services:
Keep sensitive logic on a server: If feasible, you could implement certain parts of your project as server-side logic accessed via APIs. This way, you can protect the critical parts of your application.
Selective Sharing:
Consider sharing only specific parts of your code that are essential for your users while keeping the more sensitive parts hidden.
Professional Assistance:
Consult with a legal professional: If your project is particularly valuable, it might be worth seeking legal advice on how to best protect your intellectual property.
It’s important to recognize that no method can guarantee absolute protection. Determined individuals can find ways to reverse-engineer code, regardless of the measures in place. However, by using a combination of these strategies, you can deter most casual users from accessing or modifying your code.
Ultimately, the choice you make will depend on the nature of your project, your target audience, and your level of comfort with sharing your work. Always ensure you’re in compliance with relevant laws and regulations when sharing or selling your software.
Of course not. But who’s going to do that? I was talking about commercial software you you download or buy in a store. Console games fall into that category too. Of course, if you buy a software company, you get all their assets, including the source code.