Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/defold/extension-prometheus

Lua obfuscation using Prometheus
https://github.com/defold/extension-prometheus

Last synced: 4 months ago
JSON representation

Lua obfuscation using Prometheus

Awesome Lists containing this project

README

        

# extension-prometheus
Lua obfuscation using [Prometheus](https://github.com/levno-710/Prometheus). This extension hooks into the [Lua builder plugin system in bob](https://github.com/defold/defold/blob/dev/com.dynamo.cr/com.dynamo.cr.bob/src/com/dynamo/bob/pipeline/LuaBuilder.java#L243-L252).

## Installation
To use this library in your Defold project you need to [make a fork of this repository](https://github.com/defold/extension-prometheus/fork) and then add the repository archive URL to your `game.project` dependencies. Example (replace `%YOUR_ORG%` with your GitHub user or organisation):

https://github.com/%YOUR_ORG%/extension-prometheus/archive/master.zip

## Prometheus config
The extension will look for a [Prometheus configuration](https://levno-710.gitbook.io/prometheus/getting-started/writing-a-custom-config-file) file named `prometheus.lua` in the project root.

## Example

```lua
local test = require("main.test")

function init(self)
print("hello")
test.greet("Bob")
end
```

```lua
return(function(...)local W={"LGVa";"1OD91aRxhfwx";"dc2A1cU=","ho04hfL="}local function a(E)return W[E+50784]end for E,a in ipairs({{1,4},{1;3},{4,4}})do while a[1]=E or Y(R,P+1,P+1)~="="then x(g,o(F((l%65536)/256)))end break end P=P+1 end a[W]=D(g)end end end local E=require(a(-50783))function init(W)print(a(-50782))E[a(-50781)](a(-50780))end end)(...)
```

## Prometheus source code
Prometheus source code is packaged into `pluginPrometheusSource.jar` and unpacked using `getResourceAsStream()` to a temporary folder while bob is running.