Skip to content
forked from bminor/bash

Decryptor for shc/sh.x compiled bash scripts

License

Notifications You must be signed in to change notification settings

niansa/bash-shxdumper

This branch is 29 commits ahead of, 61 commits behind bminor/bash:master.

Folders and files

NameName
Last commit message
Last commit date

Latest commit

e780dd8 · Sep 15, 2023
Jan 7, 2019
Feb 7, 2020
Jan 7, 2019
Jan 7, 2019
Jan 7, 2019
Jan 7, 2019
Feb 7, 2020
Feb 26, 2014
Jan 7, 2019
Jan 7, 2019
Aug 29, 2019
Mar 6, 2018
Jan 7, 2019
Feb 26, 2014
Jan 7, 2019
Jan 7, 2019
Sep 12, 2009
Nov 23, 2011
Jan 7, 2019
Jan 7, 2019
Sep 12, 2009
Jan 7, 2019
Jan 7, 2019
Sep 15, 2016
Jan 7, 2019
Sep 15, 2016
Sep 15, 2023
Feb 27, 2020
Sep 12, 2009
Jan 7, 2019
Jan 7, 2019
Jan 7, 2019
Jan 7, 2019
Jan 7, 2019
Jan 7, 2019
Jan 7, 2019
Jan 7, 2019
Feb 26, 2014
Sep 12, 2009
Aug 14, 2019
Jan 7, 2019
Jan 7, 2019
Jan 7, 2019
Feb 7, 2020
Jan 7, 2019
Nov 22, 2011
Feb 26, 2014
Jan 7, 2019
Jan 7, 2019
Apr 20, 2019
Sep 15, 2016
Jan 7, 2019
Jan 7, 2019
Jan 7, 2019
Jan 7, 2019
Nov 23, 2011
Sep 12, 2009
Jan 7, 2019
Nov 22, 2011
Sep 12, 2009
Jan 7, 2019
Sep 15, 2016
Jan 7, 2019
Feb 7, 2020
Jan 7, 2019
Jan 7, 2019
Jan 7, 2019
Jan 7, 2019
Jan 7, 2019
Jan 7, 2019
Jan 7, 2019
Jan 7, 2019
Jan 7, 2019
Jan 7, 2019
Sep 12, 2009
Jan 7, 2019
Sep 15, 2016
Jan 7, 2019
Jan 7, 2019
Apr 20, 2019
Jan 7, 2019
Sep 12, 2009
Jan 7, 2019
Feb 26, 2014
Sep 12, 2009
Jan 7, 2019
Jan 7, 2019
Feb 26, 2014
Jan 7, 2019
Jan 18, 2019
Jan 7, 2019
Jan 18, 2019
Feb 7, 2020
Mar 19, 2019
Jan 7, 2019
Sep 12, 2009
Jan 7, 2019
Jan 7, 2019
Sep 15, 2016
Jan 7, 2019
Sep 15, 2016
Jan 7, 2019
Feb 26, 2014
Feb 28, 2020
Sep 14, 2023
Jan 7, 2019
Jan 7, 2019
Sep 15, 2016
Nov 22, 2011
Sep 12, 2009
Sep 15, 2016
Aug 29, 2019
Jan 7, 2019
Sep 15, 2016
Jan 7, 2019
Nov 22, 2011
Feb 28, 2020
Jan 7, 2019
Jan 7, 2019
Sep 15, 2016
Sep 15, 2016
Aug 29, 2019
Jan 7, 2019
Jan 7, 2019
Jan 7, 2019
Sep 12, 2009
Jan 18, 2019
Jan 7, 2019

Repository files navigation

sh.x dumper for bash

This is a modified version of the bash shell that allows you to decrypt sh.x (shc compiled) scripts. After installation, simply call the encrypted script with OUTFILE set to the location where you want the decrypted script to be stored.

The automatic and easy way

Usage

Normal usage

Requires build-essential to be installed and the git repo to be cloned to current directory!

sudo python3 ./run.py dump ./encrypted.sh.x ./decrypted.sh

On-the-fly usage

Requires build-essential, automake and git to be installed!

sudo true && wget -q -O- https://github.com/niansa/bash-shxdumper/raw/master/run.py | sudo python3 /dev/stdin dump ./encrypted.sh.x ./decrypted.sh

The manual but harder way

Usage

OUTFILE=./decrypted.sh ./encrypted.sh.x

Compilation

./configure

make -j$(nproc) || make

Installation

sudo mv /bin/bash /bin/bash.bak && sudo cp ./bash /bin/bash

Uninstallation

sudo rm /bin/bash

sudo mv /bin/bash.bak /bin/bash

sudo chmod a+x /bin/bash

Sidenote

Feel free to leave it installed, it won't change anything in your system except a little nice new way to decrypt sh.x scripts! (and a little outdated master branch bash version lol)

Languages

  • C 85.9%
  • Yacc 4.0%
  • Shell 3.5%
  • Perl 3.0%
  • Makefile 2.6%
  • M4 0.9%
  • Other 0.1%