Skip to main content
danielm49702136
Participating Frequently
February 24, 2026
Question

obfuscate/protect Lightroom plugins

  • February 24, 2026
  • 1 reply
  • 46 views

Dear,

I would like to know how to obfuscate or protect Lua Lightroom plugins. The SDK manual tells just to compile, but with well known decompilers I can recover the source code without any problem.
I have tried Hercules-Obfuscator, and some online obfuscators, but they do corrupt the code. They brake the code in: 

  • Changing the names of table’s keys that Lightroom need to know (for instance “LrPluginName” in Info.Lua
  • Changing names of exported functions/variables in one file and then it can not be recognized in another one. If I make a file “helpers”  that returns “{ onefunc(), anotherfunc()}” the obfuscators I tryed change the exported names and can not call them from another file with requiere(‘helper’)  and  helpers.onefunc()
  • Probably other parts

 

I have tried turning on and off hercules options, but failed to be able to run the plugin

 

Is there any way to protect the code?

    1 reply

    johnrellis
    Legend
    February 25, 2026

    Compiling is the easiest and most reliable way to obfuscate source code, and that’s what I use. My experience with the decompilers is that, though they can expose the gist of what your code does, they’re aren’t that reliable. I’ve never tried any true obfuscators.

     

    Friedl, one of the most prolific plugin developers (now semi-retired), uses a song-and-dance routine to encode the bulk of his plugins’ compiled modules.