MappingEncrypt
0.2.4
A custom character encoding module for encrypting PowerShell scripts. PowerShell port of the mapping-encrypt package; uses the same private Cloudflare mapping worker.
Minimum PowerShell version
5.1
Installation Options
Owners
Copyright
(c) 2024 MD Faisal Qureshi. All rights reserved.
Package Details
Author(s)
- MD Faisal Qureshi
Tags
encoding encryption obfuscation mapping cloudflare protect
Functions
ConvertTo-MappingEncoded ConvertFrom-MappingEncoded Protect-MappingScript Unprotect-MappingScript Invoke-MappingPackage
Dependencies
This module has no dependencies.
Release Notes
Encode/decode PowerShell scripts via the shared private Cloudflare mapping worker.
0.2.3 - fixes encoding of scripts containing double-quotes (the generated stub now stores the encoded string in a literal single-quoted string, so tokens containing '$' are preserved).
USAGE
# Install / Upgrade / Uninstall / Reinstall
Install-Module MappingEncrypt # install
Update-Module MappingEncrypt # upgrade to latest
Uninstall-Module MappingEncrypt # uninstall
Invoke-MappingPackage -Action reinstall # reinstall (uninstall + install)
# Encode a script file into a self-decoding stub:
mapping-encode .\my_script.ps1 -o .\encrypted.ps1
# Run the encoded script (it decodes itself at runtime):
pwsh .\encrypted.ps1
# Decode an encrypted script back to source:
mapping-decode .\encrypted.ps1
# String-level helpers:
$enc = ConvertTo-MappingEncoded -Text 'Write-Host "hi"'
$dec = ConvertFrom-MappingEncoded -EncodedString $enc
FileList
- MappingEncrypt.nuspec
- MappingEncrypt.psm1
- MappingEncrypt.psd1
- LICENSE
- README.md