From ec0453039dfe0a0c85101eafd23b246c85f0c3c5 Mon Sep 17 00:00:00 2001 From: raildex1 Date: Mon, 24 Apr 2017 01:23:21 +1000 Subject: [PATCH 1/8] Updates to Installs, should fix a few tools especially on 14.04 --- apktool/install | 4 ++-- dirb/install | 2 +- gdb/install | 2 +- msieve/install | 2 +- panda/install | 43 +++++++++++++++++++++++---------------- panda/install-root-ubuntu | 12 +++++++++++ panda/uninstall | 3 +++ pdf-parser/install | 4 ++-- pwntools/install | 1 + qemu/install | 4 ++-- reveng/install | 7 ++++--- taintgrind/install | 4 ++-- xrop/install | 2 +- yafu/install | 2 +- 14 files changed, 59 insertions(+), 33 deletions(-) create mode 100755 panda/install-root-ubuntu create mode 100755 panda/uninstall diff --git a/apktool/install b/apktool/install index 56e81a8..071520a 100755 --- a/apktool/install +++ b/apktool/install @@ -1,8 +1,8 @@ #!/bin/bash -ex mkdir bin wget https://raw.githubusercontent.com/iBotPeaches/Apktool/master/scripts/linux/apktool -wget https://bitbucket.org/iBotPeaches/apktool/downloads/apktool_2.2.0.jar -mv apktool_2.2.0.jar bin/apktool.jar +wget https://bitbucket.org/iBotPeaches/apktool/downloads/apktool_2.2.2.jar +mv apktool_2.2.2.jar bin/apktool.jar mv apktool bin/ chmod 755 bin/apktool chmod 755 bin/apktool.jar diff --git a/dirb/install b/dirb/install index a12cb85..bb0f981 100755 --- a/dirb/install +++ b/dirb/install @@ -1,7 +1,7 @@ #!/bin/bash -ex mkdir bin -wget -O dirb.tar.gz http://downloads.sourceforge.net/project/dirb/dirb/2.22/dirb222.tar.gz +wget -O dirb.tar.gz https://downloads.sourceforge.net/project/dirb/dirb/2.22/dirb222.tar.gz tar -xf dirb.tar.gz chmod -R a+X dirb222/ diff --git a/gdb/install b/gdb/install index 74b7a88..add8630 100755 --- a/gdb/install +++ b/gdb/install @@ -1,7 +1,7 @@ #!/bin/bash -ex set -e -o pipefail -curl https://ftp.gnu.org/gnu/gdb/gdb-7.12.tar.gz | tar xz +curl https://ftp.gnu.org/gnu/gdb/gdb-7.12.1.tar.gz | tar xz cd gdb-7.12 # move to ctftools virtual env diff --git a/msieve/install b/msieve/install index cdab3d5..527bf71 100755 --- a/msieve/install +++ b/msieve/install @@ -1,7 +1,7 @@ #!/bin/bash -ex mkdir bin -wget -O msieve.tar.gz "http://downloads.sourceforge.net/project/msieve/msieve/Msieve v1.53/msieve153_src.tar.gz" +wget -O msieve.tar.gz "https://downloads.sourceforge.net/project/msieve/msieve/Msieve v1.53/msieve153_src.tar.gz" tar -xf msieve.tar.gz cd msieve-* diff --git a/panda/install b/panda/install index abde86f..8d0ce5e 100755 --- a/panda/install +++ b/panda/install @@ -1,32 +1,41 @@ #!/bin/bash -ex -[ -e panda ] || git clone --depth 1 https://github.com/moyix/panda +[ -e panda ] || git clone --recursive https://github.com/panda-re/panda -curl -O http://ragestorm.net/distorm/distorm3.3-package.zip -rm -rf distorm3 -unzip distorm3.3-package.zip -make -C distorm3/make/linux -j -mkdir -p lib -cp distorm3/make/linux/*.so distorm3/*.a lib -mkdir -p include -cp distorm3/include/*.h include +# git includes submodules hence recursive ctf-tools-pip install -U pycparser -sed -i -e "s|/usr/local|$PWD|" panda/qemu/build.sh -export QEMU_CFLAGS="-I $PWD/include -L $PWD/lib" -export QEMU_CXXFLAGS="-I $PWD/include -L $PWD/lib" +git clone git://git.code.sf.net/p/libdwarf/code libdwarf-code + +# move to ctftools virtual env +source ctf-tools-venv-activate + +pushd libdwarf-code +./configure --enable-shared +make -j$(nproc) +mkdir -p ../include +mkdir -p ../lib +cp libdwarf/libdwarf.h ../include +cp libdwarf/dwarf.h ../include +cp libdwarf/libdwarf.so ../lib +popd + +#sed -i -e "s|/usr/local|$PWD|" panda/build.sh +export QEMU_CFLAGS="-I $PWD/include" +export QEMU_CXXFLAGS="-I $PWD/include" #export LDFLAGS="-L $PWD/lib" -cd panda/qemu -./build.sh +mkdir -p panda/build +cd panda/build +../build.sh "$@" cd ../../ # link binaries mkdir -p bin cd bin -ln -s ../panda/qemu/i386-softmmu/qemu-system-i386 ./panda-qemu-system-i386 -ln -s ../panda/qemu/arm-softmmu/qemu-system-arm ./panda-qemu-system-arm -ln -s ../panda/qemu/x86_64-softmmu/qemu-system-x86_64 ./panda-qemu-system-x86_64 +ln -s ../panda/build/i386-softmmu/qemu-system-i386 ./panda-qemu-system-i386 +ln -s ../panda/build/arm-softmmu/qemu-system-arm ./panda-qemu-system-arm +ln -s ../panda/build/x86_64-softmmu/qemu-system-x86_64 ./panda-qemu-system-x86_64 for i in ../panda/scripts/*.py do ln -s $i ./panda-$(basename $i) diff --git a/panda/install-root-ubuntu b/panda/install-root-ubuntu new file mode 100755 index 0000000..c93b0c9 --- /dev/null +++ b/panda/install-root-ubuntu @@ -0,0 +1,12 @@ +#!/bin/bash -ex +set -eu -o pipefail + +apt-get update +apt-get -y build-dep qemu +apt-get -y install software-properties-common +add-apt-repository -y ppa:phulin/panda +apt-get update +apt-get -y install nasm libssl-dev libpcap-dev libelf-dev \ + libc++-dev llvm-3.3-dev clang-3.3 libprotoc-dev \ + protobuf-c-compiler protobuf-compiler libprotobuf-c0-dev pkg-config \ + libglib2.0-dev libcapstone-dev libdwarf-dev python-pycparser diff --git a/panda/uninstall b/panda/uninstall new file mode 100755 index 0000000..2e4b074 --- /dev/null +++ b/panda/uninstall @@ -0,0 +1,3 @@ +#!/bin/bash -ex + +ctf-tools-pip uninstall -y pycparser || true diff --git a/pdf-parser/install b/pdf-parser/install index 99748ec..a024560 100755 --- a/pdf-parser/install +++ b/pdf-parser/install @@ -1,7 +1,7 @@ #!/bin/bash -ex -wget https://didierstevens.com/files/software/pdf-parser_V0_6_4.zip -unzip pdf-parser_V0_6_4.zip +wget https://didierstevens.com/files/software/pdf-parser_V0_6_7.zip +unzip pdf-parser_V0_6_7.zip mkdir -p bin mv pdf-parser.py bin/pdf-parser chmod 755 bin/pdf-parser diff --git a/pwntools/install b/pwntools/install index 36a31cb..0f20bd3 100755 --- a/pwntools/install +++ b/pwntools/install @@ -1,4 +1,5 @@ #!/bin/bash -ex git clone --depth=1 https://github.com/Gallopsled/pwntools.git +ctf-tools-pip install --upgrade appdirs ctf-tools-pip install --upgrade -e pwntools diff --git a/qemu/install b/qemu/install index 7f4063b..f876dd9 100755 --- a/qemu/install +++ b/qemu/install @@ -1,8 +1,8 @@ #!/bin/bash -ex set -e -o pipefail -curl http://download.qemu-project.org/qemu-2.8.0.tar.bz2 | tar xvj -cd qemu-2.8.0 +curl http://download.qemu-project.org/qemu-2.8.1.tar.bz2 | tar xvj +cd qemu-2.8.1 source ctf-tools-venv-activate ./configure "--prefix=$(dirname $PWD)" "--python=$(which python)" diff --git a/reveng/install b/reveng/install index 71e3a8e..525e4a8 100755 --- a/reveng/install +++ b/reveng/install @@ -1,11 +1,12 @@ #!/bin/bash -ex -curl http://jaist.dl.sourceforge.net/project/reveng/1.4.4/reveng-1.4.4.tar.gz | tar xz -cd reveng-1.4.4 +wget https://downloads.sourceforge.net/project/reveng/1.5.1/reveng-1.5.1.tar.gz +tar -xf reveng-1.5.1.tar.gz +cd reveng-1.5.1 sed -i -e "s/^#define BMP_BIT.*/#define BMP_BIT 64/" config.h sed -i -e "s/^#define BMP_SUB.*/#define BMP_SUB 32/" config.h make -j $(nproc) cd .. mkdir -p bin -cp reveng-1.4.4/reveng bin +cp reveng-1.5.1/reveng bin diff --git a/taintgrind/install b/taintgrind/install index d0c7988..28826ee 100755 --- a/taintgrind/install +++ b/taintgrind/install @@ -2,8 +2,8 @@ INST_DIR=$PWD -curl http://valgrind.org/downloads/valgrind-3.11.0.tar.bz2 | tar xj -cd valgrind-3.11.0 +curl http://valgrind.org/downloads/valgrind-3.12.0.tar.bz2 | tar xj +cd valgrind-3.12.0 ./autogen.sh ./configure --prefix=$INST_DIR make -j $(nproc) diff --git a/xrop/install b/xrop/install index 4adfdb9..3d7f47c 100755 --- a/xrop/install +++ b/xrop/install @@ -8,5 +8,5 @@ cd .. mkdir bin cd bin -ln -s ../xrop +ln -s ../xrop/xrop cd .. diff --git a/yafu/install b/yafu/install index 982b9fb..9b71ccf 100755 --- a/yafu/install +++ b/yafu/install @@ -3,7 +3,7 @@ mkdir yafu mkdir bin cd yafu -wget "https://downloads.sourceforge.net/project/yafu/1.34/yafu-1.34.zip?r=http%3A%2F%2Fsourceforge.net%2Fprojects%2Fyafu%2F&ts=1446080941&use_mirror=skylineservers" -O yafu.zip +wget "https://downloads.sourceforge.net/project/yafu/1.34/yafu-1.34.zip" -O yafu.zip unzip yafu.zip chmod 755 yafu mv yafu ../bin From 8000c4af36d702f1990e79a27f8afa583984c8ac Mon Sep 17 00:00:00 2001 From: raildex1 Date: Mon, 24 Apr 2017 02:23:23 +1000 Subject: [PATCH 2/8] fixed typo --- panda/install | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/panda/install b/panda/install index 8d0ce5e..a199ce5 100755 --- a/panda/install +++ b/panda/install @@ -13,7 +13,7 @@ source ctf-tools-venv-activate pushd libdwarf-code ./configure --enable-shared -make -j$(nproc) +make -j $(nproc) mkdir -p ../include mkdir -p ../lib cp libdwarf/libdwarf.h ../include From c8e7076645158eb8fc02a532cfa7dd708de781af Mon Sep 17 00:00:00 2001 From: raildex1 Date: Tue, 25 Apr 2017 02:34:41 +1000 Subject: [PATCH 3/8] Fixed xrop --- xrop/install | 2 +- xrop/install-root-debian | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) create mode 100755 xrop/install-root-debian diff --git a/xrop/install b/xrop/install index 3d7f47c..5704e7d 100755 --- a/xrop/install +++ b/xrop/install @@ -8,5 +8,5 @@ cd .. mkdir bin cd bin -ln -s ../xrop/xrop +ln -s ../xrop/xrop . cd .. diff --git a/xrop/install-root-debian b/xrop/install-root-debian new file mode 100755 index 0000000..8155ca5 --- /dev/null +++ b/xrop/install-root-debian @@ -0,0 +1,5 @@ +#!/bin/bash -ex + +apt-get update +apt-get install -y zlib1g-dev + From 66a86d9c2213cc1b49c200e7ca21e5d4d610bf77 Mon Sep 17 00:00:00 2001 From: raildex1 Date: Tue, 25 Apr 2017 02:39:22 +1000 Subject: [PATCH 4/8] Fixed xrop 2 --- xrop/install | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xrop/install b/xrop/install index 5704e7d..14c1b2e 100755 --- a/xrop/install +++ b/xrop/install @@ -6,7 +6,7 @@ git submodule update --init --recursive make -j 1 # Watch out!! -j $(nproc) makes the build fail cd .. -mkdir bin +mkdir -p bin cd bin ln -s ../xrop/xrop . cd .. From 81ca264d23b973ccb9804f5a649d80753cde8a7b Mon Sep 17 00:00:00 2001 From: raildex1 Date: Tue, 25 Apr 2017 04:29:51 +1000 Subject: [PATCH 5/8] Update install-root-ubuntu Removed build-dep due to 16.04 failing with it. --- panda/install-root-ubuntu | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/panda/install-root-ubuntu b/panda/install-root-ubuntu index c93b0c9..097b374 100755 --- a/panda/install-root-ubuntu +++ b/panda/install-root-ubuntu @@ -2,7 +2,7 @@ set -eu -o pipefail apt-get update -apt-get -y build-dep qemu +#apt-get -y build-dep qemu apt-get -y install software-properties-common add-apt-repository -y ppa:phulin/panda apt-get update From 90135d43d2cbcbf1e52af9eadc229c9f0310c476 Mon Sep 17 00:00:00 2001 From: raildex1 Date: Tue, 25 Apr 2017 04:54:44 +1000 Subject: [PATCH 6/8] Update install Fixed qemu url --- qemu/install | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/qemu/install b/qemu/install index f876dd9..d106486 100755 --- a/qemu/install +++ b/qemu/install @@ -1,7 +1,7 @@ #!/bin/bash -ex set -e -o pipefail -curl http://download.qemu-project.org/qemu-2.8.1.tar.bz2 | tar xvj +curl http://download.qemu.org/qemu-2.8.1.tar.bz2 | tar xvj cd qemu-2.8.1 source ctf-tools-venv-activate From 979c17118cd25b0a89d58eb8edbe52f12a00cc68 Mon Sep 17 00:00:00 2001 From: raildex1 Date: Tue, 25 Apr 2017 05:39:37 +1000 Subject: [PATCH 7/8] Shellsploit Changed git url Original author has 'quit' Github or something. Luckily have likely the last version that was on Github. --- shellsploit/install | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/shellsploit/install b/shellsploit/install index c6c8f92..9d7e6dc 100755 --- a/shellsploit/install +++ b/shellsploit/install @@ -1,6 +1,6 @@ #!/bin/bash -ex -git clone https://github.com/b3mb4m/shellsploit-framework.git +git clone https://github.com/raildex1/shellsploit-framework.git cd shellsploit-framework set +e From ffc65617480d1865e310dbda2ead2342d9d1fa47 Mon Sep 17 00:00:00 2001 From: raildex1 Date: Tue, 25 Apr 2017 05:53:29 +1000 Subject: [PATCH 8/8] Update install Forgot the .1 --- gdb/install | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gdb/install b/gdb/install index add8630..74fd3b8 100755 --- a/gdb/install +++ b/gdb/install @@ -2,7 +2,7 @@ set -e -o pipefail curl https://ftp.gnu.org/gnu/gdb/gdb-7.12.1.tar.gz | tar xz -cd gdb-7.12 +cd gdb-7.12.1 # move to ctftools virtual env source ctf-tools-venv-activate