
Research
Security News
The Growing Risk of Malicious Browser Extensions
Socket researchers uncover how browser extensions in trusted stores are used to hijack sessions, redirect traffic, and manipulate user behavior.
github.com/devOpifex/obfuscator
A tool to obfuscate R code by renaming variables, functions, and file names while preserving functionality.
[!WARNING] This tool only obfuscates code and does not encrypt it. Obfuscation is not a security measure and should not be relied upon to protect sensitive code or intellectual property. The obfuscated code can potentially be reverse-engineered. Do not use this tool with the expectation that it makes your code secure to share.
go install github.com/devOpifex/obfuscator@latest
You can also build from source:
git clone https://github.com/devOpifex/obfuscator.git
cd obfuscator
go build
$> obfuscator -h
Usage of obfuscator:
-deobfuscate
Deobfuscate the obfuscated files
-in string
Directory of R files to obfuscate
-key string
Key to obfuscate
-license string
License to prepend to every obfuscated file, e.g.: license
-out string
Directory where to write the obfuscated files
-protect string
Comma separated protected tokens, e.g.: foo,bar
Basic Obfuscation:
obfuscator -in=R -out=obfuscated -key=secret
With License and Protected Tokens:
obfuscator -in=R -out=obfuscated -key=secret -license=license.txt -protect=myFunction,importantVar
Deobfuscation:
obfuscator -deobfuscate -in=obfuscated -out=deobfuscated -key=secret
See obfuscator -h
for more details.
If statements must include curly braces:
if(TRUE) 1 else 0
if(TRUE) {1} else {0}
Lambda functions must include curly braces:
\(x) x + 1
\(x) {x + 1}
Expressions in curly braces outside of standard control structures are not supported:
tryCatch({x + 1})
fn <- \(){x + 1}; tryCatch(fn())
.onLoad
) are not obfuscated__
are not renamed (but their content is still obfuscated).R
extension are processeddo.call()
are not obfuscated - consider alternatives-protect
flag for functions that must maintain their original namesThe obfuscator works by:
You may want to use the Go modules to lex, or parse R code too.
FAQs
Unknown package
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
Socket researchers uncover how browser extensions in trusted stores are used to hijack sessions, redirect traffic, and manipulate user behavior.
Research
Security News
An in-depth analysis of credential stealers, crypto drainers, cryptojackers, and clipboard hijackers abusing open source package registries to compromise Web3 development environments.
Security News
pnpm 10.12.1 introduces a global virtual store for faster installs and new options for managing dependencies with version catalogs.