Merge remote-tracking branch 'upstream/master'

Merge with upstream
This commit is contained in:
raildex1 2017-04-20 23:18:59 +10:00
commit f211f94e0b
229 changed files with 1313 additions and 311 deletions

View file

@ -1,6 +1,34 @@
language: python
python: 2.7
language: bash
sudo: required
dist: trusty
install: (sudo apt-get update || true) && bin/manage-tools -s setup
script: bin/manage-tools -s test all
services:
- docker
before_install:
- if [ "$DISTRO" = "archlinux" ]; then docker build -t ctftools -f Dockerfile.archlinux .; fi
- if [ "$DISTRO" = "fedora" ]; then docker build -t ctftools -f Dockerfile.fedora .; fi
- if [ "$DISTRO" = "xenial" ]; then docker build -t ctftools -f Dockerfile.xenial .; fi
- if [ "$DISTRO" = "trusty" ]; then docker build -t ctftools -f Dockerfile .; fi
env:
- DISTRO='archlinux' TOOL='afl android-sdk apktool binwalk burpsuite checksec df dirb elfkickers evilize featherduster firmware-mod-kit gdb hashpump hashpump-partialhash honggfuzz jdgui keystone libheap msieve pkcrack pwndbg pwntools python-paddingoracle pyvmmonitor radare2 sqlmap sslsplit testdisk tor-browser unicorn veles virtualsocket xortool xrop yafu zsteg' # estimated 2000 seconds
- DISTRO='archlinux' TOOL='commix cribdrag dirsearch exetractor foresight gef pdf-parser peda peepdf pemcrack rp++ scrdec18 shellnoob ssh_decoder steganabara stegsolve subbrute' # estimated 16 seconds
- DISTRO='archlinux' EXPECTFAIL=1 TOOL='qira taintgrind z3' # estimated 1831 seconds
- DISTRO='archlinux' EXPECTFAIL=1 TOOL='angr barf beef bindead capstone codereason dislocker elfparser gdb-heap hash-identifier hashkill littleblackbox mitmproxy panda pathgrind preeny python-pin reveng ropper shellsploit snowman sonic-visualizer stegdetect villoc wcc xspy' # estimated 764 seconds
# - DISTRO='archlinux' TOOL='qemu' # unknown duration...
- DISTRO='fedora' TOOL='apktool binwalk burpsuite capstone checksec commix cribdrag dirsearch elfkickers evilize exetractor foresight gdb gef jdgui libheap pdf-parser peda peepdf pkcrack python-paddingoracle pyvmmonitor radare2 ropper rp++ scrdec18 shellnoob shellsploit ssh_decoder steganabara stegsolve subbrute unicorn virtualsocket xortool yafu z3' # estimated 1779 seconds
- DISTRO='fedora' EXPECTFAIL=1 TOOL='afl android-sdk angr barf beef bindead codereason df dirb dislocker elfparser featherduster firmware-mod-kit gdb-heap hash-identifier hashkill hashpump hashpump-partialhash honggfuzz keystone littleblackbox mitmproxy msieve panda pathgrind pemcrack preeny pwndbg pwntools python-pin qemu qira reveng snowman sonic-visualizer sqlmap sslsplit stegdetect taintgrind testdisk tor-browser veles villoc wcc xrop xspy zsteg' # estimated 549 seconds
- DISTRO='trusty' TOOL='barf capstone jdgui stegdetect yafu z3' # estimated 1995 seconds
- DISTRO='trusty' TOOL='qemu' # estimated 2160 seconds
- DISTRO='trusty' TOOL='apktool bindead featherduster gdb qira snowman' # estimated 1976 seconds
- DISTRO='trusty' TOOL='afl android-sdk burpsuite codereason df firmware-mod-kit hashkill keystone mitmproxy pwndbg pwntools radare2 unicorn' # estimated 1976 seconds
- DISTRO='trusty' TOOL='binwalk checksec commix cribdrag dirb dirsearch dislocker elfkickers elfparser evilize exetractor foresight gef hash-identifier hashpump hashpump-partialhash honggfuzz libheap littleblackbox msieve pdf-parser peda peepdf pemcrack pkcrack preeny python-paddingoracle python-pin pyvmmonitor ropper rp++ scrdec18 shellnoob shellsploit sqlmap ssh_decoder sslsplit steganabara stegsolve subbrute testdisk tor-browser villoc virtualsocket xortool xspy zsteg' # estimated 374 seconds
- DISTRO='trusty' EXPECTFAIL=1 TOOL='angr panda sonic-visualizer' # estimated 1877 seconds
- DISTRO='trusty' EXPECTFAIL=1 TOOL='beef gdb-heap pathgrind reveng taintgrind veles wcc xrop' # estimated 303 seconds
- DISTRO='xenial' TOOL='qemu' # estimated 1928 seconds
- DISTRO='xenial' TOOL='barf keystone mitmproxy z3' # estimated 1920 seconds
- DISTRO='xenial' TOOL='afl android-sdk angr firmware-mod-kit gdb snowman' # estimated 1985 seconds
- DISTRO='xenial' TOOL='apktool binwalk burpsuite capstone checksec codereason commix cribdrag df dirb dirsearch dislocker elfkickers elfparser evilize exetractor featherduster foresight gef hash-identifier hashpump hashpump-partialhash honggfuzz jdgui libheap littleblackbox msieve pdf-parser peda peepdf pemcrack pkcrack preeny pwndbg python-paddingoracle pyvmmonitor radare2 ropper rp++ scrdec18 shellnoob shellsploit sqlmap ssh_decoder sslsplit steganabara stegsolve subbrute testdisk tor-browser unicorn veles virtualsocket xortool xspy yafu' # estimated 1230 seconds
- DISTRO='xenial' EXPECTFAIL=1 TOOL='beef bindead gdb-heap hashkill panda pathgrind pwntools python-pin qira reveng sonic-visualizer stegdetect taintgrind villoc wcc xrop zsteg' # estimated 457 seconds
script:
- travis_wait 50 ./bin/travis-ci.sh

3
.travis.yml.footer Normal file
View file

@ -0,0 +1,3 @@
script:
- travis_wait 50 ./bin/travis-ci.sh

12
.travis.yml.header Normal file
View file

@ -0,0 +1,12 @@
language: bash
sudo: required
services:
- docker
before_install:
- if [ "$DISTRO" = "archlinux" ]; then docker build -t ctftools -f Dockerfile.archlinux .; fi
- if [ "$DISTRO" = "fedora" ]; then docker build -t ctftools -f Dockerfile.fedora .; fi
- if [ "$DISTRO" = "xenial" ]; then docker build -t ctftools -f Dockerfile.xenial .; fi
- if [ "$DISTRO" = "trusty" ]; then docker build -t ctftools -f Dockerfile .; fi
env:

View file

@ -3,7 +3,7 @@ maintainer yans@yancomm.net
RUN apt-get update && apt-get install -y build-essential libtool g++ gcc \
texinfo curl wget automake autoconf python python-dev git subversion \
unzip virtualenvwrapper
unzip virtualenvwrapper sudo
RUN useradd -m ctf
COPY .git /home/ctf/tools/.git
@ -18,7 +18,8 @@ USER ctf
WORKDIR /home/ctf/tools
RUN git checkout .
RUN bin/manage-tools -s setup
RUN bin/ctf-tools-pip install appdirs
RUN echo "workon ctftools" >> /home/ctf/.bashrc
WORKDIR /home/ctf
ENTRYPOINT bash -i
CMD bash -i

View file

@ -20,7 +20,7 @@ RUN pacman -Syu --noconfirm --needed \
python2-pip python-pip \
unzip python-virtualenvwrapper \
zsh grml-zsh-config \
sudo \
sudo which \
&& pacman -Scc --noconfirm
RUN useradd -m ctf

19
Dockerfile.fedora Normal file
View file

@ -0,0 +1,19 @@
FROM fedora
RUN dnf -y install which sudo git redhat-lsb
RUN useradd -m ctf
COPY .git /home/ctf/tools/.git
RUN chown -R ctf.ctf /home/ctf/tools
RUN echo "ctf ALL=NOPASSWD: ALL" > /etc/sudoers.d/ctf
USER ctf
WORKDIR /home/ctf/tools
RUN git checkout .
RUN bin/manage-tools -s setup
RUN bin/ctf-tools-pip install appdirs
RUN echo "workon ctftools" >> /home/ctf/.bashrc
WORKDIR /home/ctf
CMD bash -i

25
Dockerfile.xenial Normal file
View file

@ -0,0 +1,25 @@
from ubuntu:xenial
maintainer yans@yancomm.net
RUN apt-get update && apt-get install -y build-essential libtool g++ gcc \
texinfo curl wget automake autoconf python python-dev git subversion \
unzip virtualenvwrapper sudo
RUN useradd -m ctf
COPY .git /home/ctf/tools/.git
RUN chown -R ctf.ctf /home/ctf/tools
RUN echo "ctf ALL=NOPASSWD: ALL" > /etc/sudoers.d/ctf
RUN apt-get update
RUN apt-get -y install git virtualenvwrapper
USER ctf
WORKDIR /home/ctf/tools
RUN git checkout .
RUN bin/manage-tools -s setup
RUN bin/ctf-tools-pip install appdirs
RUN echo "workon ctftools" >> /home/ctf/.bashrc
WORKDIR /home/ctf
CMD bash -i

View file

@ -4,16 +4,16 @@
This is a collection of setup scripts to create an install of various security research tools.
Of course, this isn't a hard problem, but it's really nice to have them in one place that's easily deployable to new machines and so forth.
The install-scripts for these tools are checked regularly, the results can be found on [the build status page](_buildstatus/index.md).
Installers for the following tools are included:
| Category | Tool | Description |
|----------|------|-------------|
| binary | [afl](http://lcamtuf.coredump.cx/afl/) | State-of-the-art fuzzer. | <!--tool--> <!--test-->
| binary | [afl](http://lcamtuf.coredump.cx/afl/) | State-of-the-art fuzzer. | <!--tool--> <!--times-out-->
| binary | [angr](http://angr.io) | Next-generation binary analysis engine from Shellphish. | <!--tool--> <!--no-test-->
| binary | [barf](https://github.com/programa-stic/barf-project) | Binary Analysis and Reverse-engineering Framework. | <!--tool--><!--times-out-->
| binary | [bindead](https://bitbucket.org/mihaila/bindead/wiki/Home) | A static analysis tool for binaries. | <!--tool--><!--failing-->
| binary | [binjitsu](https://github.com/binjitsu/binjitsu) | Useful CTF utilities. pwntools fork. | <!--tool--><!--no-test-->
| binary | [checksec](https://github.com/slimm609/checksec.sh) | Check binary hardening settings. | <!--tool--><!--test-->
| binary | [codereason](https://github.com/trailofbits/codereason) | Semantic Binary Code Analysis Framework. | <!--tool--><!--failing-->
| binary | [crosstool-ng](http://crosstool-ng.org/) | Cross-compilers and cross-architecture tools. | <!--tool--><!--no-test-->
@ -22,24 +22,28 @@ Installers for the following tools are included:
| binary | [elfparser](http://www.elfparser.com/) | Quickly determine the capabilities of an ELF binary through static analysis. | <!--tool--><!--test-->
| binary | [evilize](http://www.mathstat.dal.ca/~selinger/md5collision/) | Tool to create MD5 colliding binaries | <!--tool--><!--test-->
| binary | [gdb](http://www.gnu.org/software/gdb/) | Up-to-date gdb with python2 bindings. | <!--tool--><!--failing-->
| binary | [gdb-heap](https://fedorahosted.org/gdb-heap/) | gdb extension for debugging heap issues. | <!--tool--><!--test-->
| binary | [gef](https://github.com/hugsy/gef) | Enhanced environment for gdb. | <!--tool--><!--no-test-->
| binary | [hongfuzz](https://github.com/google/honggfuzz) | A general-purpose, easy-to-use fuzzer with interesting analysis options. | <!--tool--><!--test-->
| binary | [libheap](https://github.com/cloudburst/libheap) | gdb python library for examining the glibc heap (ptmalloc) | <!--tool--><!--no-test-->
| binary | [miasm](https://github.com/cea-sec/miasm) | Reverse engineering framework in Python. | <!--tool--> <!--test-->
| binary | [panda](https://github.com/moyix/panda) | Platform for Architecture-Neutral Dynamic Analysis. | <!--tool--><!--no-test-->
| binary | [pathgrind](https://github.com/codelion/pathgrind) | Path-based, symbolically-assisted fuzzer. | <!--tool--><!--test-->
| binary | [pathgrind](https://github.com/codelion/pathgrind) | Path-based, symbolically-assisted fuzzer. | <!--tool--><!--failing-->
| binary | [peda](https://github.com/longld/peda) | Enhanced environment for gdb. | <!--tool--><!--test-->
| binary | [preeny](https://github.com/zardus/preeny) | A collection of helpful preloads (compiled for many architectures!). | <!--tool--><!--no-test-->
| binary | [pwndbg](https://github.com/zachriggle/pwndbg) | Enhanced environment for gdb. Especially for pwning. | <!--tool--><!--no-test-->
| binary | [pwntools](https://github.com/Gallopsled/pwntools) | Useful CTF utilities. | <!--tool--><!--no-test-->
| binary | [python-pin](https://github.com/blankwall/Python_Pin) | Python bindings for pin. | <!--tool--><!--test-->
| binary | [qemu](http://qemu.org) | Latest version of qemu! | <!--tool--><!--times-out-->
| binary | [qira](http://qira.me) | Parallel, timeless debugger. | <!--tool--><!--test-->
| binary | [qira](http://qira.me) | Parallel, timeless debugger. | <!--tool--><!--times-out-->
| binary | [radare2](http://www.radare.org/) | Some crazy thing crowell likes. | <!--tool--><!--test-->
| binary | [ropper](https://github.com/sashs/Ropper) | Another gadget finder. | <!--tool--><!--test-->
| binary | [rp++](https://github.com/0vercl0k/rp) | Another gadget finder. | <!--tool--><!--test-->
| binary | [rr](http://rr-project.org) | Record and Replay Debugging Framework | <!--tool--><!--test-->
| binary | [shellnoob](https://github.com/reyammer/shellnoob) | Shellcode writing helper. | <!--tool--><!--test-->
| binary | [shellsploit](https://github.com/b3mb4m/shellsploit-framework) | Shellcode development kit. | <!--tool--><!--test-->
| binary | [snowman](https://github.com/yegord/snowman) | Cross-architecture decompiler. | <!--tool--><!--test-->
| binary | [taintgrind](https://github.com/wmkhoo/taintgrind) | A valgrind taint analysis tool. | <!--tool--><!--test-->
| binary | [taintgrind](https://github.com/wmkhoo/taintgrind) | A valgrind taint analysis tool. | <!--tool--><!--failing-->
| binary | [villoc](https://github.com/wapiflapi/villoc) | Visualization of heap operations. | <!--tool--><!--test-->
| binary | [virtualsocket](https://github.com/antoniobianchi333/virtualsocket) | A nice library to interact with binaries. | <!--tool--><!--test-->
| binary | [wcc](https://github.com/endrazine/wcc) | The Witchcraft Compiler Collection is a collection of compilation tools to perform binary black magic on the GNU/Linux and other POSIX platforms. | <!--tool--><!--no-test-->
@ -53,6 +57,7 @@ Installers for the following tools are included:
| forensics | [scrdec](https://gist.github.com/bcse/1834878) | A decoder for encoded Windows Scripts. | <!--tool--><!--test-->
| forensics | [testdisk](http://www.cgsecurity.org/wiki/TestDisk) | Testdisk and photorec for file recovery. | <!--tool--><!--test-->
| crypto | [cribdrag](https://github.com/SpiderLabs/cribdrag) | Interactive crib dragging tool (for crypto). | <!--tool--><!--test-->
| crypto | [fastcoll](https://www.win.tue.nl/hashclash/) | An md5sum collision generator. | <!--tool--><!--test-->
| crypto | [foresight](https://github.com/ALSchwalm/foresight) | A tool for predicting the output of random number generators. To run, launch "foresee". | <!--tool--><!--test-->
| crypto | [featherduster](https://github.com/nccgroup/featherduster) | An automated, modular cryptanalysis tool. | <!--tool--><!--no-test-->
| crypto | [hashkill](https://github.com/gat3way/hashkill) | Hash cracker. | <!--tool--><!--test-->
@ -80,8 +85,23 @@ Installers for the following tools are included:
| stego | [steganabara](http://www.caesum.com/handbook/stego.htm) | Another image steganography solver. | <!--tool--><!--test-->
| stego | [stegdetect](http://www.outguess.org/) | Steganography detection/breaking tool. | <!--tool--><!--test-->
| stego | [stegsolve](http://www.caesum.com/handbook/stego.htm) | Image steganography solver. | <!--tool--><!--test-->
| stego | [zsteg](https://github.com/zed-0xff/zsteg) | detect stegano-hidden data in PNG & BMP. | <!--tool--><!--no-test-->
| android | [apktool](https://ibotpeaches.github.io/Apktool/) | Dissect, dis-assemble, and re-pack Android APKs | <!--tool--><!--test-->
| android | [android-sdk](http://developer.android.com/sdk) | The android SDK (adb, emulator, etc). | <!--tool--><!--no-test-->
| misc | [xspy](http://git.kali.org/gitweb/?p=packages/xspy.git;a=summary) | Tiny tool to spy on X sessions. | <!--tool--><!--test-->
| misc | [z3](https://github.com/Z3Prover/z3) | Theorem prover from Microsoft Research. | <!--tool--><!--times-out-->
| misc | [jdgui](http://jd.benow.ca/) | Java decompiler. | <!--tool--><!--test-->
| misc | [veles](https://codisec.com/veles/) | Binary data analysis and visulalization tool. | <!--tool--><!--test-->
There are also a couple of installers for useful libraries included. Currently
only the python bindings for these libraries are installed.
| Category | Library | Description |
|----------|---------|-------------|
| binary | [capstone](http://www.capstone-engine.org) | Multi-architecture disassembly framework. | <!--tool--><!--test-->
| binary | [keystone](http://www.keystone-engine.org) | Lightweight multi-architecture assembler framework. | <!--tool--><!--test-->
| binary | [unicorn](http://www.unicorn-engine.org) | Multi-architecture CPU emulator framework. | <!--tool--><!--test-->
| binary | [lief](https://lief.quarkslab.com/) | Library to Instrument Executable Formats. | <!--tool--><!--test-->
There are also some installers for non-CTF stuff to break the monotony!
@ -149,6 +169,12 @@ docker run -it ctf-tools
The built image will have ctf-tools cloned and ready to go, but you will still need to install the tools themselves (see above).
Alternatively, you can also pull ctf-tools (with some tools preinstalled) from dockerhub:
```bash
docker run -it zardus/ctf-tools
```
## Vagrant
You can build a Vagrant VM with:
@ -198,7 +224,7 @@ Good luck!
# See Also
There's a curated list of CTF tools, but without installers, here: https://github.com/apsdehal/awesome-ctf.
There's a curated list of CTF tools, but without installers, here: https://github.com/apsdehal/aWEsoMe-cTf.
There's a Vagrant config with a lot of the bigger frameworks here: https://github.com/thebarbershopper/epictreasure.
@ -211,6 +237,7 @@ They're not included in ctf-tools, but are included here as notes for the author
|----------|---------|-------------|---------|
| forensics | [foremost](http://foremost.sourceforge.net/) | File carver. | `foremost` | <!--deb-tool-->
| dsniff | [dsniff](http://www.monkey.org/~dugsong/dsniff/) | Grabs passwords and other data from pcaps/network streams. | dsniff | <!--deb-tool-->
| stego | [pngtools](https://launchpad.net/ubuntu/+source/pngtools) | PNG's analysis tool. | <!--deb-tool-->
## Tools with unofficial Debian/Ubuntu repos or debs

BIN
_buildstatus/fail.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

93
_buildstatus/index.md Normal file
View file

@ -0,0 +1,93 @@
| archlinux | fedora | trusty | xenial
----- | ----- | ----- | ----- | -----
![success](success.png) | 54 | 37 | 73 | 67
![fail](fail.png) | 29 | 47 | 11 | 17
![unknown](unknown.png) | 1 | 0 | 0 | 0
total | 84 | 84 | 84 | 84
| archlinux | fedora | trusty | xenial
----- | ----- | ----- | ----- | -----
afl | ![success](success.png) | ![fail](fail.png) | ![success](success.png) | ![success](success.png)
android-sdk | ![success](success.png) | ![fail](fail.png) | ![success](success.png) | ![success](success.png)
angr | ![fail](fail.png) | ![fail](fail.png) | ![fail](fail.png) | ![success](success.png)
apktool | ![success](success.png) | ![success](success.png) | ![success](success.png) | ![success](success.png)
barf | ![fail](fail.png) | ![fail](fail.png) | ![success](success.png) | ![success](success.png)
beef | ![fail](fail.png) | ![fail](fail.png) | ![fail](fail.png) | ![fail](fail.png)
bindead | ![fail](fail.png) | ![fail](fail.png) | ![success](success.png) | ![fail](fail.png)
binwalk | ![success](success.png) | ![success](success.png) | ![success](success.png) | ![success](success.png)
burpsuite | ![success](success.png) | ![success](success.png) | ![success](success.png) | ![success](success.png)
capstone | ![fail](fail.png) | ![success](success.png) | ![success](success.png) | ![success](success.png)
checksec | ![success](success.png) | ![success](success.png) | ![success](success.png) | ![success](success.png)
codereason | ![fail](fail.png) | ![fail](fail.png) | ![success](success.png) | ![success](success.png)
commix | ![success](success.png) | ![success](success.png) | ![success](success.png) | ![success](success.png)
cribdrag | ![success](success.png) | ![success](success.png) | ![success](success.png) | ![success](success.png)
df | ![success](success.png) | ![fail](fail.png) | ![success](success.png) | ![success](success.png)
dirb | ![success](success.png) | ![fail](fail.png) | ![success](success.png) | ![success](success.png)
dirsearch | ![success](success.png) | ![success](success.png) | ![success](success.png) | ![success](success.png)
dislocker | ![fail](fail.png) | ![fail](fail.png) | ![success](success.png) | ![success](success.png)
elfkickers | ![success](success.png) | ![success](success.png) | ![success](success.png) | ![success](success.png)
elfparser | ![fail](fail.png) | ![fail](fail.png) | ![success](success.png) | ![success](success.png)
evilize | ![success](success.png) | ![success](success.png) | ![success](success.png) | ![success](success.png)
exetractor | ![success](success.png) | ![success](success.png) | ![success](success.png) | ![success](success.png)
featherduster | ![success](success.png) | ![fail](fail.png) | ![success](success.png) | ![success](success.png)
firmware-mod-kit | ![success](success.png) | ![fail](fail.png) | ![success](success.png) | ![success](success.png)
foresight | ![success](success.png) | ![success](success.png) | ![success](success.png) | ![success](success.png)
gdb | ![success](success.png) | ![success](success.png) | ![success](success.png) | ![success](success.png)
gdb-heap | ![fail](fail.png) | ![fail](fail.png) | ![fail](fail.png) | ![fail](fail.png)
gef | ![success](success.png) | ![success](success.png) | ![success](success.png) | ![success](success.png)
hash-identifier | ![fail](fail.png) | ![fail](fail.png) | ![success](success.png) | ![success](success.png)
hashkill | ![fail](fail.png) | ![fail](fail.png) | ![success](success.png) | ![fail](fail.png)
hashpump | ![success](success.png) | ![fail](fail.png) | ![success](success.png) | ![success](success.png)
hashpump-partialhash | ![success](success.png) | ![fail](fail.png) | ![success](success.png) | ![success](success.png)
honggfuzz | ![success](success.png) | ![fail](fail.png) | ![success](success.png) | ![success](success.png)
jdgui | ![success](success.png) | ![success](success.png) | ![success](success.png) | ![success](success.png)
keystone | ![success](success.png) | ![fail](fail.png) | ![success](success.png) | ![success](success.png)
libheap | ![success](success.png) | ![success](success.png) | ![success](success.png) | ![success](success.png)
littleblackbox | ![fail](fail.png) | ![fail](fail.png) | ![success](success.png) | ![success](success.png)
mitmproxy | ![fail](fail.png) | ![fail](fail.png) | ![success](success.png) | ![success](success.png)
msieve | ![success](success.png) | ![fail](fail.png) | ![success](success.png) | ![success](success.png)
panda | ![fail](fail.png) | ![fail](fail.png) | ![fail](fail.png) | ![fail](fail.png)
pathgrind | ![fail](fail.png) | ![fail](fail.png) | ![fail](fail.png) | ![fail](fail.png)
pdf-parser | ![success](success.png) | ![success](success.png) | ![success](success.png) | ![success](success.png)
peda | ![success](success.png) | ![success](success.png) | ![success](success.png) | ![success](success.png)
peepdf | ![success](success.png) | ![success](success.png) | ![success](success.png) | ![success](success.png)
pemcrack | ![success](success.png) | ![fail](fail.png) | ![success](success.png) | ![success](success.png)
pkcrack | ![success](success.png) | ![success](success.png) | ![success](success.png) | ![success](success.png)
preeny | ![fail](fail.png) | ![fail](fail.png) | ![success](success.png) | ![success](success.png)
pwndbg | ![success](success.png) | ![fail](fail.png) | ![success](success.png) | ![success](success.png)
pwntools | ![success](success.png) | ![fail](fail.png) | ![success](success.png) | ![fail](fail.png)
python-paddingoracle | ![success](success.png) | ![success](success.png) | ![success](success.png) | ![success](success.png)
python-pin | ![fail](fail.png) | ![fail](fail.png) | ![success](success.png) | ![fail](fail.png)
pyvmmonitor | ![success](success.png) | ![success](success.png) | ![success](success.png) | ![success](success.png)
qemu | ![unknown](unknown.png) | ![fail](fail.png) | ![success](success.png) | ![success](success.png)
qira | ![fail](fail.png) | ![fail](fail.png) | ![success](success.png) | ![fail](fail.png)
radare2 | ![success](success.png) | ![success](success.png) | ![success](success.png) | ![success](success.png)
reveng | ![fail](fail.png) | ![fail](fail.png) | ![fail](fail.png) | ![fail](fail.png)
ropper | ![fail](fail.png) | ![success](success.png) | ![success](success.png) | ![success](success.png)
rp++ | ![success](success.png) | ![success](success.png) | ![success](success.png) | ![success](success.png)
scrdec18 | ![success](success.png) | ![success](success.png) | ![success](success.png) | ![success](success.png)
shellnoob | ![success](success.png) | ![success](success.png) | ![success](success.png) | ![success](success.png)
shellsploit | ![fail](fail.png) | ![success](success.png) | ![success](success.png) | ![success](success.png)
snowman | ![fail](fail.png) | ![fail](fail.png) | ![success](success.png) | ![success](success.png)
sonic-visualizer | ![fail](fail.png) | ![fail](fail.png) | ![fail](fail.png) | ![fail](fail.png)
sqlmap | ![success](success.png) | ![fail](fail.png) | ![success](success.png) | ![success](success.png)
ssh_decoder | ![success](success.png) | ![success](success.png) | ![success](success.png) | ![success](success.png)
sslsplit | ![success](success.png) | ![fail](fail.png) | ![success](success.png) | ![success](success.png)
steganabara | ![success](success.png) | ![success](success.png) | ![success](success.png) | ![success](success.png)
stegdetect | ![fail](fail.png) | ![fail](fail.png) | ![success](success.png) | ![fail](fail.png)
stegsolve | ![success](success.png) | ![success](success.png) | ![success](success.png) | ![success](success.png)
subbrute | ![success](success.png) | ![success](success.png) | ![success](success.png) | ![success](success.png)
taintgrind | ![fail](fail.png) | ![fail](fail.png) | ![fail](fail.png) | ![fail](fail.png)
testdisk | ![success](success.png) | ![fail](fail.png) | ![success](success.png) | ![success](success.png)
tor-browser | ![success](success.png) | ![fail](fail.png) | ![success](success.png) | ![success](success.png)
unicorn | ![success](success.png) | ![success](success.png) | ![success](success.png) | ![success](success.png)
veles | ![success](success.png) | ![fail](fail.png) | ![fail](fail.png) | ![success](success.png)
villoc | ![fail](fail.png) | ![fail](fail.png) | ![success](success.png) | ![fail](fail.png)
virtualsocket | ![success](success.png) | ![success](success.png) | ![success](success.png) | ![success](success.png)
wcc | ![fail](fail.png) | ![fail](fail.png) | ![fail](fail.png) | ![fail](fail.png)
xortool | ![success](success.png) | ![success](success.png) | ![success](success.png) | ![success](success.png)
xrop | ![success](success.png) | ![fail](fail.png) | ![fail](fail.png) | ![fail](fail.png)
xspy | ![fail](fail.png) | ![fail](fail.png) | ![success](success.png) | ![success](success.png)
yafu | ![success](success.png) | ![success](success.png) | ![success](success.png) | ![success](success.png)
z3 | ![fail](fail.png) | ![success](success.png) | ![success](success.png) | ![success](success.png)
zsteg | ![success](success.png) | ![fail](fail.png) | ![success](success.png) | ![fail](fail.png)

BIN
_buildstatus/success.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

BIN
_buildstatus/unknown.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 633 B

View file

@ -1,4 +1,4 @@
#!/bin/bash -e
#!/bin/bash -ex
#
# AFL

View file

@ -1,4 +1,4 @@
#!/bin/bash
#!/bin/bash -ex
set -eu -o pipefail
pacman -Syu --noconfirm --needed bison qemu

View file

@ -1,5 +1,13 @@
#!/bin/bash
#!/bin/bash -ex
set -eu -o pipefail
apt-get -y build-dep qemu
case "$(lsb_release -cs)" in
xenial)
apt-get -y install bison libtool-bin
;;
*)
apt-get -y install bison
;;
esac

View file

@ -1,4 +1,4 @@
#!/bin/bash -e
#!/bin/bash -ex
[ -e android-sdk_r24.4.1-linux.tgz ] || wget https://dl.google.com/android/android-sdk_r24.4.1-linux.tgz
[ -e android-sdk-linux ] || tar xfz android-sdk_r24.4.1-linux.tgz

View file

@ -1,4 +1,4 @@
#!/bin/bash
#!/bin/bash -ex
set -eu -o pipefail
pacman -Syu --noconfirm --needed jre7-openjdk jdk7-openjdk

View file

@ -1,4 +1,12 @@
#!/bin/bash
#!/bin/bash -ex
set -eu -o pipefail
case "$(lsb_release -cs)" in
xenial)
# need to overwrite because of an ubuntu packaging error(!)
apt-get -y -o Dpkg::Options::="--force-overwrite" install openjdk-9-jre openjdk-9-jdk
;;
*)
apt-get -y install openjdk-7-jre openjdk-7-jdk
;;
esac

View file

@ -1,13 +1,14 @@
#!/bin/bash -e
#!/bin/bash -ex
[ -e $VIRTUAL_ENV/lib/python2.7/site-packages/PyQt4 ] || ln -s /usr/lib/python2.7/dist-packages/PyQt4 $VIRTUAL_ENV/lib/python2.7/site-packages/
[ -e $VIRTUAL_ENV/lib/python2.7/site-packages/sip.so ] || ln -s /usr/lib/python2.7/dist-packages/sip.so $VIRTUAL_ENV/lib/python2.7/site-packages/
[ -e $VIRTUAL_ENV/lib/python2.7/site-packages/pygraphviz ] || ln -s /usr/lib/pymodules/python2.7/pygraphviz $VIRTUAL_ENV/lib/python2.7/site-packages/
source ctf-tools-venv-activate
#[ -e $VIRTUAL_ENV/lib/python2.7/site-packages/PyQt4 ] || ln -s /usr/lib/python2.7/dist-packages/PyQt4 $VIRTUAL_ENV/lib/python2.7/site-packages/
#[ -e $VIRTUAL_ENV/lib/python2.7/site-packages/sip.so ] || ln -s /usr/lib/python2.7/dist-packages/sip.so $VIRTUAL_ENV/lib/python2.7/site-packages/
#[ -e $VIRTUAL_ENV/lib/python2.7/site-packages/pygraphviz ] || ln -s /usr/lib/pymodules/python2.7/pygraphviz $VIRTUAL_ENV/lib/python2.7/site-packages/
git clone --depth 1 https://github.com/angr/angr-dev
cd angr-dev
./setup.sh
cd ..
GIT_ASKPASS=echo angr-dev/setup.sh -w -r https://git:@github.com/salls angrop
rm -rf angr-dev/wheels
mkdir -p bin
cd bin

View file

@ -1,8 +1,8 @@
#!/bin/bash
#!/bin/bash -ex
set -eu -o pipefail
# for angr
apt-get -y install virtualenvwrapper python2.7-dev build-essential libxml2-dev libxslt1-dev git libffi-dev cmake libreadline-dev libtool debootstrap debian-archive-keyring libglib2.0-dev libpixman-1-dev
apt-get -y install virtualenvwrapper python2.7-dev build-essential libxml2-dev libxslt1-dev git libffi-dev cmake libreadline-dev libtool debootstrap debian-archive-keyring libglib2.0-dev libpixman-1-dev libqt4-dev graphviz-dev binutils-multiarch nasm libc6:i386 libgcc1:i386 libstdc++6:i386 libtinfo5:i386 zlib1g:i386
# for angr-management
apt-get -y install python-qt4 python-sip python-pygraphviz

View file

@ -1,8 +1,8 @@
#!/bin/bash -e
#!/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.0.2.jar
mv apktool_2.0.2.jar bin/apktool.jar
wget https://bitbucket.org/iBotPeaches/apktool/downloads/apktool_2.2.0.jar
mv apktool_2.2.0.jar bin/apktool.jar
mv apktool bin/
chmod 755 bin/apktool
chmod 755 bin/apktool.jar

2
apktool/install-root-archlinux Normal file → Executable file
View file

@ -1,4 +1,4 @@
#!/bin/bash
#!/bin/bash -ex
set -eu -o pipefail
pacman -Syu --noconfirm --needed jre8-openjdk

View file

@ -1,4 +1,4 @@
#!/bin/bash
#!/bin/bash -ex
set -eu -o pipefail
apt-get install -y default-jre

View file

@ -1,7 +1,12 @@
#!/bin/bash
#!/bin/bash -ex
# it's z3!
pip install https://github.com/zardus/z3/archive/pypy-and-setup.zip
ctf-tools-pip install https://github.com/zardus/z3/archive/pypy-and-setup.zip
set +e
source ${VIRTUALENVWRAPPER_SCRIPT}
workon ctftools
set -e
# pybfd can't be installed with pip
git clone --depth 1 https://github.com/Groundworkstech/pybfd
@ -9,11 +14,16 @@ cd pybfd/
python setup.py install
cd ..
# install pyasmjit
git clone --depth 1 https://github.com/programa-stic/pyasmjit.git
cd pyasmjit
python setup.py install
cd ..
# install barf
git clone --depth 1 https://github.com/programa-stic/barf-project
cd barf-project/
pip install -e pyasmjit/
pip install -e barf/
python setup.py install
cd ..
mkdir -p bin

View file

@ -1,4 +1,4 @@
#!/bin/bash
#!/bin/bash -ex
set -eu -o pipefail
apt-get -y install binutils-multiarch-dev

View file

@ -1,4 +1,4 @@
#!/bin/bash
#!/bin/bash -ex
pip uninstall -y barf pyasmjit
ctf-tools-pip uninstall -y barf pyasmjit
rm -f $VIRTUAL_ENV/bin/BARFgadgets

View file

@ -1,4 +1,4 @@
#!/bin/bash
#!/bin/bash -ex
git clone --depth 1 https://github.com/beefproject/beef

View file

@ -1,4 +1,4 @@
#!/bin/bash -e
#!/bin/bash -ex
pacman -Syu --noconfirm --needed \
ruby python2 ruby-bundler \

View file

@ -1,8 +1,8 @@
#!/bin/bash -e
#!/bin/bash -ex
echo "Need to get ruby with RVM... Unsupported for now"
exit 1
apt-get install build-essential openssl libreadline6 \
apt-get -y install build-essential openssl libreadline6 \
libreadline6-dev zlib1g zlib1g-dev libssl-dev \
libyaml-dev libsqlite3-0 libsqlite3-dev sqlite3 \
libxml2-dev libxslt1-dev autoconf libc6-dev \

View file

@ -2,42 +2,8 @@
set -e -o pipefail
#set -x
# let's stick with python 2 as default
PY_VERSION=2
# check this scripts file ending
if [[ "$0" =~ pip3 ]]; then
PY_VERSION=3
fi
if [[ "$0" =~ pip2 ]]; then
PY_VERSION=2
fi
PY_INTERPRETER=$(which "python$PY_VERSION" || which python)
CTF_TOOLS_VE="ctftools"
if [[ $PY_VERSION -eq 3 ]]; then
CTF_TOOLS_VE="${CTF_TOOLS_VE}3"
fi
if [[ -z "${WORKON_HOME+x}" ]]; then
export WORKON_HOME="$HOME/.virtualenvs"
fi
if [[ ! -d "$WORKON_HOME" ]]; then
mkdir -p "$WORKON_HOME"
fi
VE_DIR="$WORKON_HOME/$CTF_TOOLS_VE"
if [[ ! -d "$VE_DIR" || ! -e "$VE_DIR/bin/activate" ]]; then
echo "#### Creating python$PY_VERSION virtualenv '$CTF_TOOLS_VE' ####" >&2
virtualenv --system-site-packages -p "$PY_INTERPRETER" "$VE_DIR"
fi
if [[ -z "${VIRTUAL_ENV+x}" || "$VIRTUAL_ENV" != "$VE_DIR" ]]; then
if [[ -n "${VIRTUAL_ENV+x}" ]]; then
deactivate
fi
source "$VE_DIR/bin/activate"
fi
# http://stackoverflow.com/questions/59895/can-a-bash-script-tell-which-directory-it-is-stored-in
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
source $DIR/ctf-tools-venv-activate
exec pip "$@"

45
bin/ctf-tools-venv-activate Executable file
View file

@ -0,0 +1,45 @@
#!/bin/bash
# check this scripts file ending
if [[ "$0" =~ pip3 ]]; then
PY_VERSION=3
fi
if [[ "$0" =~ pip2 ]]; then
PY_VERSION=2
fi
if [[ -z "${PY_VERSION+x}" ]]; then
# if not defined otherwise let's stick with python 2 as default
PY_VERSION=2
fi
PY_INTERPRETER=$(which "python$PY_VERSION" || which python)
if [[ -z "${CTF_TOOLS_VE+x}" ]]; then
CTF_TOOLS_VE="ctftools"
if [[ $PY_VERSION -eq 3 ]]; then
CTF_TOOLS_VE="${CTF_TOOLS_VE}3"
fi
fi
if [[ -z "${WORKON_HOME+x}" ]]; then
export WORKON_HOME="$HOME/.virtualenvs"
fi
if [[ ! -d "$WORKON_HOME" ]]; then
mkdir -p "$WORKON_HOME"
fi
VE_DIR="$WORKON_HOME/$CTF_TOOLS_VE"
if [[ ! -d "$VE_DIR" || ! -e "$VE_DIR/bin/activate" ]]; then
echo "#### Creating python$PY_VERSION virtualenv '$CTF_TOOLS_VE' ####" >&2
virtualenv --system-site-packages -p "$PY_INTERPRETER" "$VE_DIR"
fi
if [[ -z "${VIRTUAL_ENV+x}" || "$VIRTUAL_ENV" != "$VE_DIR" ]]; then
if [[ -n "${VIRTUAL_ENV+x}" ]]; then
source ${VIRTUAL_ENV}/bin/activate
deactivate
fi
source "$VE_DIR/bin/activate"
fi

8
bin/ctf-tools-venv-activate3 Executable file
View file

@ -0,0 +1,8 @@
#!/bin/bash
export PY_VERSION=3
export CTF_TOOLS_VE="ctftools3"
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
source "$DIR/ctf-tools-venv-activate"

View file

@ -5,10 +5,12 @@ set -eu -o pipefail
function usage()
{
cat <<END
Usage: $(basename $0) [-s] (list|setup|install|uninstall|bin|search) tool
Usage: $(basename $0) [-sv] (list|setup|install|uninstall|bin|search) tool
Where:
-s allow running things with sudo (i.e., to install debs)
-v verbose mode. print log while installing
-f force certain actions (such as installing over an installed tool)
tool the name of the tool. if "all", does the action on all tools
Actions:
@ -32,14 +34,16 @@ function tool_log()
function detect_distribution()
{
if which pacman 2>&1 >/dev/null; then
if which pacman >/dev/null 2>&1; then
echo "archlinux"
elif which apt-get 2>&1 >/dev/null; then
if lsb_release -a | grep -i ubuntu 2>&1 >/dev/null; then
elif which apt-get >/dev/null 2>&1; then
if lsb_release -a 2>/dev/null | grep -i ubuntu >/dev/null 2>&1; then
echo "ubuntu"
else
echo "debian"
fi
elif which dnf >/dev/null 2>&1; then
echo "fedora"
else
echo ""
fi
@ -48,7 +52,7 @@ function detect_distribution()
function base_build_setup_debian()
{
PACKAGE_REQS="build-essential libtool g++ gcc texinfo curl wget automake autoconf python python-dev git subversion unzip virtualenvwrapper"
PACKAGE_REQS="build-essential libtool g++ gcc texinfo curl wget automake autoconf python python-dev git subversion unzip virtualenvwrapper lsb-release"
PACKAGE_COUNT=$(echo $PACKAGE_REQS | tr ' ' '\n' | wc -l)
if [ $(dpkg -l $PACKAGE_REQS | grep "^ii" | wc -l) -ne $PACKAGE_COUNT ]
then
@ -108,6 +112,19 @@ EOF
}
function base_build_setup_fedora()
{
PACKAGE_REQS="libtool gcc gcc-c++ clang cmake texinfo curl wget automake autoconf python python-devel git subversion unzip python-virtualenvwrapper redhat-rpm-config"
if [ "$ALLOW_SUDO" -eq 1 ]; then
sudo dnf -y install $PACKAGE_REQS
else
TOOL=SETUP tool_log "Please install the following packages: $PACKAGE_REQS"
fi
# TODO: check whether we have to explicitly enable i386 package support
}
function base_build_setup()
{
case "$1" in
@ -120,6 +137,9 @@ function base_build_setup()
base_build_setup_arch
export VIRTUALENVWRAPPER_PYTHON=/usr/bin/python3
;;
"fedora")
base_build_setup_fedora
;;
*)
TOOL=SETUP tool_log "Cannot detect or unsupported distribution"
esac
@ -137,8 +157,15 @@ function base_build_setup()
echo "set -x PATH $PWD/bin \$PATH " >> ~/.config/fish/config.fish
fi
if [[ ! -e "$PWD/bin/ctf-tools-pip3" ]]; then
ln -s "$PWD/bin/ctf-tools-pip" "$PWD/bin/ctf-tools-pip3"
fi
# create the py2 virtualenv
"$PWD/bin/ctf-tools-pip" freeze 2>&1 >/dev/null
# create the py3 virtualenv
"$PWD/bin/ctf-tools-pip3" freeze 2>&1 >/dev/null
}
@ -155,6 +182,12 @@ do
-s)
export ALLOW_SUDO=1
;;
-f)
export FORCE=1
;;
-v)
export VERBOSE_OUTPUT=1
;;
*)
usage
exit
@ -164,6 +197,9 @@ do
done
[[ -z ${ALLOW_SUDO+x} ]] && export ALLOW_SUDO=0
[[ -z ${FORCE+x} ]] && export FORCE=0
[[ -z ${VERBOSE_OUTPUT+x} ]] && export VERBOSE_OUTPUT=0
export EXPECTFAIL=${EXPECTFAIL:-0}
if [[ $# -ge 1 ]]; then
ACTION="$1"
@ -202,18 +238,27 @@ case $ACTION in
;;
bin)
cd bin
if [ -d ../$TOOL/bin ]; then
ln -sf ../$TOOL/bin/* .
tool_log "bin symlinks updated"
fi
cd ..
;;
install)
cd $TOOL
if git status --ignored . | egrep -q 'Untracked|Ignored'
if [ "$FORCE" -eq 0 ] && git status --ignored . | egrep -q 'Untracked|Ignored'
then
tool_log "appears to already be installed. Uninstall first?"
exit 0
fi
# the first line in all install and uninstall scripts should have the -e flag, otherwise fail
if [ $(for i in install* uninstall test; do if [ -e "$i" ]; then head -1 "$i"; fi; done | sort | uniq | grep -v '^#!/bin/bash -ex$' | wc -l) -ne 0 ];
then
tool_log "not all install/uninstall/test scripts start with '#!/bin/bash -ex', which is a must for accurate testing."
exit 1
fi
tool_log "starting install, logging to $PWD/install.log"
rm -f install.log
@ -241,8 +286,16 @@ case $ACTION in
fi
# execute install script
if env DISTRI=$DISTRI ./install >>install.log 2>&1
then
set +e
if [ "$VERBOSE_OUTPUT" -eq 1 ]; then
DISTRI=$DISTRI ./install 2>&1 | tee -a install.log
else
DISTRI=$DISTRI ./install >>install.log 2>&1
fi
INSTALL_FAILED=$?
set -e
if [ "$INSTALL_FAILED" -eq 0 ]; then
tool_log "install finished"
else
tool_log "INSTALL FAILED"
@ -283,21 +336,34 @@ case $ACTION in
cat README.md | grep "<\!--tool-->" | sed "s/<\!--[^-]*-->//g" | grep -i "$TOOL"
;;
test)
if ! cat README.md | grep "<\!--tool-->" | grep "| \[$TOOL\](" | grep -q -- "--test--"
if [ "$FORCE" -eq 0 ] && ! cat README.md | grep "<\!--tool-->" | grep "| \[$TOOL\](" | grep -q -- "--test--"
then
tool_log "Tests not enabled."
if [ "$EXPECTFAIL" -eq "1" ]; then exit 1; fi
else
$0 install $TOOL
if (
if ! $0 install $TOOL; then exit 1; fi
cd $TOOL
cd $TOOL || exit 1
if [ -f ./test ]
then
tool_log "Running test script."
./test
if ! ./test
then
tool_log "$TOOL test failed!"
exit 1
fi
tool_log "test script succeeded!"
else
tool_log "Install succeeded. No test script!"
fi
exit 0
);
then
if [ "$EXPECTFAIL" -eq "1" ]; then exit 1; else exit 0; fi
else
if [ "$EXPECTFAIL" -eq "1" ]; then exit 0; else exit 1; fi
fi
fi
;;
*)

View file

@ -0,0 +1,13 @@
FROM ubuntu:xenial
RUN apt-get update
RUN apt-get -y install python-software-properties software-properties-common build-essential git python-pip ipython vim
RUN apt-add-repository ppa:brightbox/ruby-ng
RUN apt-get update
RUN apt-get -y install ruby2.1 ruby2.1-dev ruby-switch
RUN ruby-switch --set ruby2.1
RUN gem install travis -v 1.8.8 --no-rdoc --no-ri
RUN pip install binpacking
WORKDIR /gitdata

View file

@ -0,0 +1,23 @@
#!/bin/bash
tmpfile=$(mktemp)
# Fetch data
(
for i in $(travis show --skip-completion-check --no-interactive | grep '^#' | awk '{print $1}' | tr "#" " ");
do
travis logs --skip-completion-check --no-interactive "$i" | grep '^\[ACCOUNTING\]=====\[' | cut -d' ' -f2-5
done
) > $tmpfile
# generate travis-ci data
(
cat /gitdata/.travis.yml.header
/gitdata/bin/travis-ci-status/make_binpacked_travis_ci_conf.py $tmpfile
cat /gitdata/.travis.yml.footer
) > /gitdata/.travis.yml
# generate build status data
/gitdata/bin/travis-ci-status/make_build_status_md.py $tmpfile > /gitdata/_buildstatus/index.md
rm -f $tmpfile

View file

@ -0,0 +1,17 @@
#!/bin/bash
dockerimage=ctf-tools-travisbuildcheck
gitdir=$(git rev-parse --show-toplevel)
if ! docker history $dockerimage &> /dev/null;
then
echo "Docker image \"$dockerimage\" does not exist. Run"
echo
echo " docker build -t $dockerimage ."
echo
echo "first, then retry this command."
exit 1
fi
docker run --rm -v $gitdir:/gitdata -ti $dockerimage /gitdata/bin/travis-ci-status/fetch_latest_timingdata.inside-docker.sh

View file

@ -0,0 +1,53 @@
#!/usr/bin/env python
import binpacking, sys, pprint
MAXBINDURATION = 2000 # seconds
def parseOutput(fn):
lines = [l.strip() for l in open(fn).readlines()]
out = {}
for l in lines:
[distro, tool, success, duration] = l.split(" ")
if not distro in out:
out[distro] = {}
out[distro][tool] = {
"success": success == "SUCCEEDED",
"duration": int(duration)
}
return out
def printBins(timingdata, distro, expectfail):
inputs = dict([(t, v["duration"]) for (t, v) in timingdata[distro].items() if v["success"] != expectfail])
bins = binpacking.to_constant_volume(inputs, MAXBINDURATION)
for b in bins:
tools = " ".join(sorted(b.keys()))
duration = sum(b.values())
if expectfail:
print("- DISTRO='{}' EXPECTFAIL=1 TOOL='{}' # estimated {} seconds".format(distro, tools, duration))
else:
print("- DISTRO='{}' TOOL='{}' # estimated {} seconds".format(distro, tools, duration))
def getToolsFromTimingdata(timingdata):
out = {}
for d, dd in timingdata.items():
for t, td in dd.items():
out[t] = 1
return out.keys()
if __name__ == "__main__":
timingdata = parseOutput(sys.argv[1])
distros = sorted(timingdata.keys()) # all distros seen during previous build
tools = sorted(getToolsFromTimingdata(timingdata)) # all tools seen during previous build
for distro in distros:
printBins(timingdata, distro, False)
printBins(timingdata, distro, True)
# no timing data, assume the build took too long for this tool on this distro
nodata = [t for t in tools if t not in timingdata[distro]]
for tool in nodata:
print("# - DISTRO='{}' TOOL='{}' # unknown duration...".format(distro, tool))

View file

@ -0,0 +1,44 @@
#!/usr/bin/env python
from make_binpacked_travis_ci_conf import *
if __name__ == "__main__":
timingdata = parseOutput(sys.argv[1])
distros = sorted(timingdata.keys()) # all distros seen during previous build
tools = sorted(getToolsFromTimingdata(timingdata)) # all tools seen during previous build
fulltable = []
summarytable = []
fulltable += [" | ".join([""] + distros)]
fulltable += [" | ".join(["-----"] * (1+len(distros)))]
summary = {}
for tool in tools:
parts = []
for distro in distros:
val = "unknown"
if tool in timingdata[distro]:
val = "success" if timingdata[distro][tool]["success"] else "fail"
parts += [val]
if distro not in summary:
summary[distro] = {
"unknown": 0,
"success": 0,
"fail": 0,
"total": 0,
}
summary[distro][val] += 1
summary[distro]["total"] += 1
fulltable += [" | ".join([tool] + ["![{0}]({0}.png)".format(x) for x in parts])]
summarytable += [" | ".join([""] + distros)]
summarytable += [" | ".join(["-----"] * (1+len(distros)))]
for x in ["success", "fail", "unknown"]:
summarytable += [" | ".join(["![{0}]({0}.png)".format(x)] + ["{}".format(summary[d][x]) for d in distros])]
for x in ["total"]:
summarytable += [" | ".join([x] + ["{}".format(summary[d][x]) for d in distros])]
print("\n".join(summarytable))
print("")
print("\n".join(fulltable))

64
bin/travis-ci.sh Executable file
View file

@ -0,0 +1,64 @@
#!/bin/bash -e
export EXPECTFAIL=${EXPECTFAIL:-0}
function flipstatus() {
if [ $EXPECTFAIL -eq 0 ];
then
echo $1
else
case $1 in
FAILED)
echo SUCCEEDED
;;
SUCCEEDED)
echo FAILED
;;
*)
echo $1
;;
esac
fi
}
starttime=$SECONDS
failed=""
for t in $TOOL;
do
set +e
toolstarttime=$SECONDS
echo "[-] TOOL $t TEST STARTED: $((SECONDS - starttime)) seconds since start of script."
if ! docker run -e EXPECTFAIL="$EXPECTFAIL" -e TOOL="$t" --rm ctftools bash -ic 'manage-tools -s -f -v test $TOOL';
then
failed="$failed$t "
echo "[ACCOUNTING]=====[ $DISTRO $t $(flipstatus FAILED) $((SECONDS - toolstarttime)) ]"
else
echo "[ACCOUNTING]=====[ $DISTRO $t $(flipstatus SUCCEEDED) $((SECONDS - toolstarttime)) ]"
fi
echo "[-] TOOL $t TEST ENDED: $((SECONDS - toolstarttime)) seconds, $((SECONDS - starttime)) seconds since start of script."
set -e
done
if [ "$failed" != "" ];
then
echo "==================================================="
failcount=$(echo "$failed" | wc -w)
totalcount=$(echo "$TOOL" | wc -w)
if [ "$EXPECTFAIL" -eq "1" ];
then
echo "ERROR: $failcount/$totalcount tools succeeded while they were expected to fail: $failed"
else
echo "ERROR: $failcount/$totalcount tools failed while they should have succeeded: $failed"
fi
echo "==================================================="
exit 1
fi
if [ "$EXPECTFAIL" -eq "1" ];
then
echo "DONE: $totalcount tools failed as expected."
else
echo "DONE: $totalcount tools succeeded as expected."
fi
exit 0

View file

@ -1,10 +1,11 @@
#!/bin/bash -e
#!/bin/bash -ex
INST_DIR="$PWD"
[ -e bindead ] || git clone --depth 1 https://bitbucket.org/mihaila/bindead.git
cd bindead
JAVA_HOME=/usr/lib/jvm/java-7-openjdk-amd64/jre ./build.sh
mvn install
cd ..
[ -e p9 ] || git clone --depth 1 https://bitbucket.org/mihaila/p9.git

View file

@ -1,4 +1,11 @@
#!/bin/bash
#!/bin/bash -ex
set -eu -o pipefail
case "$(lsb_release -cs)" in
xenial)
apt-get -o Dpkg::Options::="--force-overwrite" -y install maven libprotobuf-dev openjdk-9-jre openjdk-9-jdk
;;
*)
apt-get -y install maven libprotobuf-dev openjdk-7-jre openjdk-7-jdk
;;
esac

View file

@ -1,5 +0,0 @@
#!/bin/bash -e
#ctf-tools-pip install --upgrade 'git+https://github.com/binjitsu/binjitsu.git'
git clone --depth=1 'https://github.com/binjitsu/binjitsu.git'
ctf-tools-pip install --upgrade -e binjitsu

View file

@ -1,3 +0,0 @@
#!/bin/bash -e
pacman -Syu --noconfirm --needed binutils openssl libffi

View file

@ -1,6 +0,0 @@
#!/bin/bash -e
apt-get -y install software-properties-common
apt-add-repository -y ppa:pwntools/binutils
apt-get update
apt-get -y install binutils-.*-linux-gnu libffi-dev libssl-dev

View file

@ -1,3 +0,0 @@
#!/bin/bash -e
ctf-tools-pip uninstall -y binjitsu || true

View file

@ -1,7 +1,7 @@
#!/bin/bash -e
#!/bin/bash -ex
git clone --depth 1 https://github.com/devttys0/binwalk.git
pip install -e binwalk
ctf-tools-pip install -e binwalk
mkdir -p bin
ln -s $VIRTUAL_ENV/bin/binwalk bin

View file

@ -1,4 +1,4 @@
#!/bin/bash -e
#!/bin/bash -ex
wget -O ./burp.jar 'https://portswigger.net/DownloadUpdate.ashx?Product=Free'
chmod 755 ./burp.jar

View file

@ -1,4 +1,4 @@
#!/bin/bash
#!/bin/bash -ex
set -eu -o pipefail
pacman -Syu --noconfirm --needed jre7-openjdk

View file

@ -1,4 +1,11 @@
#!/bin/bash
#!/bin/bash -ex
set -eu -o pipefail
case "$(lsb_release -cs)" in
xenial)
apt-get -o Dpkg::Options::="--force-overwrite" -y install openjdk-9-jre
;;
*)
apt-get -y install openjdk-7-jre
;;
esac

4
capstone/install Executable file
View file

@ -0,0 +1,4 @@
#!/bin/bash -ex
ctf-tools-pip install --no-use-wheel -U capstone
ctf-tools-pip3 install --no-use-wheel -U capstone

33
capstone/test Executable file
View file

@ -0,0 +1,33 @@
#!/bin/bash -ex
PY_TEST_FILE=$(mktemp)
cat << END > $PY_TEST_FILE
from capstone import *
import sys
CODE = b"\x55\x48\x8b\x05\xb8\x13\x00\x00"
addresses = [0x1000, 0x1001]
md = Cs(CS_ARCH_X86, CS_MODE_64)
for idx, i in enumerate(md.disasm(CODE, 0x1000)):
if i.address != addresses[idx]:
sys.exit(1)
sys.exit(0)
END
source ${VIRTUALENVWRAPPER_SCRIPT}
set +e
workon ctftools
set -e
python $PY_TEST_FILE
deactivate
set +e
workon ctftools3
set -e
python $PY_TEST_FILE
deactivate
rm $PY_TEST_FILE

4
capstone/uninstall Executable file
View file

@ -0,0 +1,4 @@
#!/bin/bash -ex
ctf-tools-pip uninstall -y capstone || true
ctf-tools-pip3 uninstall -y capstone || true

View file

@ -1,4 +1,4 @@
#!/bin/bash -e
#!/bin/bash -ex
git clone --depth 1 https://github.com/slimm609/checksec.sh
mkdir bin

View file

@ -1,8 +1,10 @@
#!/bin/bash -e
#!/bin/bash -ex
git clone --depth 1 https://github.com/trailofbits/codereason
cd codereason
find . -type f -exec sed -i 's:/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain::g' {} \;
./install_vex.sh
# This step fails in travis-ci because of CMake 3.2 not finding Boost, while docker has CMake 2.8 which finds Boost just fine
./make.sh
cd ..

View file

@ -1,4 +1,5 @@
#!/bin/bash
#!/bin/bash -ex
set -eu -o pipefail
apt-get -y install build-essential gcc g++ make cmake libboost-dev libprotobuf-dev protobuf-compiler libboost-thread-dev libboost-system-dev libboost-filesystem-dev libboost-program-options-dev libboost-date-time-dev libboost-regex-dev
apt-get -y install build-essential gcc g++ make cmake libboost-dev libprotobuf-dev protobuf-compiler libboost-thread-dev libboost-system-dev libboost-filesystem-dev libboost-program-options-dev libboost-date-time-dev libboost-regex-dev libboost-all-dev

View file

@ -1,4 +1,4 @@
#!/bin/bash
#!/bin/bash -ex
git clone --depth 1 https://github.com/stasinopoulos/commix.git
mkdir bin

View file

@ -1,4 +1,4 @@
#!/bin/bash -e
#!/bin/bash -ex
git clone --depth 1 https://github.com/SpiderLabs/cribdrag

View file

@ -1,4 +1,4 @@
#!/bin/bash -e
#!/bin/bash -ex
FILE=cross2-20130826.tgz
INSTALL_DIR=$PWD

View file

@ -1,4 +1,4 @@
#!/bin/bash -e
#!/bin/bash -ex
mkdir -p src
[ -e crosstool-ng ] || git clone --depth 1 https://github.com/crosstool-ng/crosstool-ng.git

View file

@ -1,3 +1,3 @@
#!/bin/bash -e
#!/bin/bash -ex
pacman -Syu --noconfirm gperf flex bison help2man gawk ncurses

View file

@ -1,3 +1,3 @@
#!/bin/bash -e
#!/bin/bash -ex
apt-get install -y gperf flex bison help2man gawk libncurses5-dev

View file

@ -1,4 +1,4 @@
#!/bin/bash
#!/bin/bash -ex
[ -e x-tools ] && chmod -R u+w x-tools
rm -rf crosstools-ng

View file

@ -1,6 +1,6 @@
#!/bin/bash
#!/bin/bash -ex
wget -O - http://www.bay12games.com/dwarves/df_42_02_linux.tar.bz2 | tar xj
wget -O - http://www.bay12games.com/dwarves/df_43_05_linux.tar.bz2 | tar xj
mkdir -p bin
cat <<END > bin/dwarf_fortress

View file

@ -1,4 +1,4 @@
#!/bin/bash
#!/bin/bash -ex
set -eu -o pipefail
apt-get -y install libasound2:i386 libasyncns0:i386 libatk1.0-0:i386 libc6:i386 libcaca0:i386 libcairo2:i386 libdatrie1:i386 libdbus-1-3:i386 libdrm2:i386 libexpat1:i386 libffi6:i386 libflac8:i386 libfontconfig1:i386 libfreetype6:i386 libgdk-pixbuf2.0-0:i386 libgl1-mesa-glx:i386 libglapi-mesa:i386 libglib2.0-0:i386 libglu1-mesa:i386 libgraphite2-3:i386 libgtk2.0-0:i386 libharfbuzz0b:i386 libjbig0:i386 libjpeg-turbo8:i386 libjson-c2:i386 liblzma5:i386 libncursesw5:i386 libogg0:i386 libpango-1.0-0:i386 libpangocairo-1.0-0:i386 libpangoft2-1.0-0:i386 libpcre3:i386 libpixman-1-0:i386 libpng12-0:i386 libpulse0:i386 libsdl1.2debian:i386 libsdl-image1.2:i386 libsdl-ttf2.0-0:i386 libselinux1:i386 libslang2:i386 libsndfile1:i386 libthai0:i386 libtiff5:i386 libtinfo5:i386 libvorbis0a:i386 libvorbisenc2:i386 libwebp5:i386 libwrap0:i386 libx11-6:i386 libx11-xcb1:i386 libxau6:i386 libxcb1:i386 libxcb-dri2-0:i386 libxcb-dri3-0:i386 libxcb-glx0:i386 libxcb-present0:i386 libxcb-render0:i386 libxcb-shm0:i386 libxcb-sync1:i386 libxcomposite1:i386 libxcursor1:i386 libxdamage1:i386 libxdmcp6:i386 libxext6:i386 libxfixes3:i386 libxi6:i386 libxinerama1:i386 libxrandr2:i386 libxrender1:i386 libxshmfence1:i386 libxxf86vm1:i386 zlib1g:i386

View file

@ -1,11 +1,11 @@
#!/bin/bash -e
#!/bin/bash -ex
mkdir bin
wget -O dirb.tar.gz https://sourceforge.net/projects/dirb/files/latest/download
wget -O dirb.tar.gz http://downloads.sourceforge.net/project/dirb/dirb/2.22/dirb222.tar.gz
tar -xf dirb.tar.gz
chmod -R a+X dirb222/
cd dirb*
cd dirb222
chmod a+x configure
./configure
make

View file

@ -1,4 +1,4 @@
#!/bin/bash
#!/bin/bash -ex
set -eu -o pipefail
pacman -Syu --noconfirm --needed curl gnutls

View file

@ -1,4 +1,4 @@
#!/bin/bash
#!/bin/bash -ex
set -eu -o pipefail
apt-get -y install libcurl4-gnutls-dev

View file

@ -1,4 +1,4 @@
#!/bin/bash
#!/bin/bash -ex
mkdir bin
git clone --depth 1 https://github.com/maurosoria/dirsearch.git

View file

@ -1,14 +1,18 @@
#!/bin/bash
#!/bin/bash -ex
wget http://www.hsc.fr/ressources/outils/dislocker/download/dislocker.tar.bz2
tar xjf dislocker.tar.bz2
cd dislocker/src
sed 's?override LDFLAGS.*?& -Wl,-rpath,'`pwd`'?' < Makefile > Makefile.tmp && mv Makefile.tmp Makefile
wget -O dislocker.tar.gz https://github.com/Aorimn/dislocker/archive/v0.7.1.tar.gz
tar xf dislocker.tar.gz
DISLOCKERDIR=$(ls -d dislocker-*)
cd $DISLOCKERDIR
cmake .
make -j $(nproc)
cd ../..
cd ..
mkdir bin
cd bin
ln -s ../dislocker/src/dislocker-bek .
ln -s ../dislocker/src/dislocker-file .
ln -s ../dislocker/src/dislocker-fuse .
ln -s ../dislocker/src/dislocker-metadata .
ls -l ../$DISLOCKERDIR/src/
ln -s ../$DISLOCKERDIR/src/dislocker-bek .
ln -s ../$DISLOCKERDIR/src/dislocker-file .
ln -s ../$DISLOCKERDIR/src/dislocker-fuse .
ln -s ../$DISLOCKERDIR/src/dislocker-metadata .

View file

@ -1,4 +1,4 @@
#!/bin/bash
#!/bin/bash -ex
set -eu -o pipefail
pacman -Syu --noconfirm --needed mbedtls fuse

View file

@ -1,4 +1,11 @@
#!/bin/bash
#!/bin/bash -ex
set -eu -o pipefail
apt-get -y install libfuse-dev libpolarssl-dev
case "$(lsb_release -cs)" in
xenial)
apt-get -y install gcc cmake make libfuse-dev libmbedtls-dev ruby-dev
;;
*)
apt-get -y install gcc cmake make libfuse-dev libpolarssl-dev ruby-dev
;;
esac

View file

@ -1,7 +1,7 @@
#!/bin/bash -e
#!/bin/bash -ex
git clone --depth 1 https://github.com/BR903/ELFkickers
cd ELFkickers
make -j
make -j $(nproc)
cd ..
mv ELFkickers/bin ./bin

View file

@ -1,4 +1,4 @@
#!/bin/bash -e
#!/bin/bash -ex
wget http://www.elfparser.com/release/elfparser_x86_64_1.4.0.deb
dpkg -x elfparser_x86_64_1.4.0.deb .

View file

@ -1,4 +1,4 @@
#!/bin/bash
#!/bin/bash -ex
set -eu -o pipefail
apt-get install -y libqt5widgets5

View file

@ -1,4 +1,4 @@
#!/bin/bash -e
#!/bin/bash -ex
wget http://www.mscs.dal.ca/~selinger/md5collision/downloads/evilize-0.2.tar.gz
tar zvxf evilize-0.2.tar.gz

View file

@ -1,4 +1,4 @@
#!/bin/bash -e
#!/bin/bash -ex
git clone --depth 1 https://github.com/kholia/exetractor-clone.git

9
fastcoll/install Executable file
View file

@ -0,0 +1,9 @@
#!/bin/bash -ex
[ -e fastcoll ] || git clone https://github.com/upbit/clone-fastcoll fastcoll
cd fastcoll
make
cd ..
mkdir bin
cp fastcoll/fastcoll bin

View file

@ -1,4 +1,4 @@
#!/bin/bash -e
#!/bin/bash -ex
git clone --depth=1 https://github.com/nccgroup/featherduster.git
ctf-tools-pip install --upgrade -e featherduster

View file

@ -0,0 +1,5 @@
#!/bin/bash -ex
set -eu -o pipefail
apt-get -y install libgmp3-dev libncurses5-dev

View file

@ -1,4 +1,4 @@
#!/bin/bash -e
#!/bin/bash -ex
ctf-tools-pip uninstall -y featherduster || true

View file

@ -1,4 +1,4 @@
#!/bin/bash -e
#!/bin/bash -ex
git clone --depth 1 https://github.com/mirror/firmware-mod-kit.git
cd firmware-mod-kit/src

View file

@ -1,4 +1,4 @@
#!/bin/bash
#!/bin/bash -ex
set -eu -o pipefail
pacman -Syu --noconfirm --needed zlib xz python2-magic

View file

@ -1,4 +1,4 @@
#!/bin/bash
#!/bin/bash -ex
set -eu -o pipefail
apt-get -y install liblzma-dev python-magic zlib1g-dev

View file

@ -1,3 +1,3 @@
#!/bin/bash -e
#!/bin/bash -ex
ctf-tools-pip3 install --upgrade 'git+https://github.com/ALSchwalm/foresight.git'

View file

@ -1,3 +1,3 @@
#!/bin/bash -e
#!/bin/bash -ex
ctf-tools-pip3 uninstall -y foresight || true

22
gdb-heap/install Executable file
View file

@ -0,0 +1,22 @@
#!/bin/bash -ex
git clone --depth=1 http://git.fedorahosted.org/git/gdb-heap.git || true
cd gdb-heap
# make sure gdbinit exists
touch ~/.gdbinit
if ! grep "init-gdb-heap" ~/.gdbinit; then
cat >> ~/.gdbinit <<EOF
####
# added by ctf-tools
define init-gdb-heap
python import sys; sys.path.append("$PWD"); import heap
end
document init-gdb-heap
Initializes the gdb-heap extension (https://fedorahosted.org/gdb-heap/)
end
####
EOF
fi

3
gdb-heap/install-root-debian Executable file
View file

@ -0,0 +1,3 @@
#!/bin/bash -ex
apt-get install -y libc6-dbg

4
gdb-heap/install-root-fedora Executable file
View file

@ -0,0 +1,4 @@
#!/bin/bash -ex
dnf install -y dnf-plugins-core
dnf debuginfo-install -y glibc

View file

@ -1,7 +1,12 @@
#!/bin/bash
#!/bin/bash -ex
set -e -o pipefail
curl https://ftp.gnu.org/gnu/gdb/gdb-7.11.tar.gz | tar xz
cd gdb-7.11
./configure --prefix=$(dirname $PWD) --with-python=python2 --enable-targets=all
curl https://ftp.gnu.org/gnu/gdb/gdb-7.12.tar.gz | tar xz
cd gdb-7.12
# move to ctftools virtual env
source ctf-tools-venv-activate
./configure --prefix=$(dirname $PWD) --with-python=$(which python) --enable-targets=all
make -j $(nproc)
make install

View file

@ -1,4 +1,4 @@
#!/bin/bash
#!/bin/bash -ex
set -eu -o pipefail
pacman -Syu --needed --noconfirm texinfo

View file

@ -1,4 +1,4 @@
#!/bin/bash
#!/bin/bash -ex
set -eu -o pipefail
apt-get -y install texinfo

3
gdb/install-root-fedora Executable file
View file

@ -0,0 +1,3 @@
#!/bin/bash -ex
dnf install -y texinfo

View file

@ -1,4 +1,4 @@
#!/bin/bash
#!/bin/bash -ex
set -eu -o pipefail
git clone --depth 1 https://github.com/hugsy/gef.git
@ -11,6 +11,8 @@ EOF
chmod +rx bin/gdb-gef
cd gef
# make sure gdbinit exists
touch ~/.gdbinit
if ! grep "init-gef" ~/.gdbinit; then
cat >> ~/.gdbinit <<EOF

View file

@ -1,4 +1,4 @@
#!/bin/bash -e
#!/bin/bash -ex
wget https://storage.googleapis.com/google-code-archive-downloads/v2/code.google.com/hash-identifier/Hash_ID_v1.1.py
chmod 755 Hash_ID_v1.1.py

View file

@ -1,3 +1,3 @@
#!/bin/bash -e
#!/bin/bash -ex
apt-get -y install tofrodos

View file

@ -1,4 +1,4 @@
#!/bin/bash -e
#!/bin/bash -ex
PREFIX=$PWD

View file

@ -0,0 +1,3 @@
#!/bin/bash -ex
pacman -Syu --noconfirm --needed openssl

3
hashkill/install-root-debian Executable file
View file

@ -0,0 +1,3 @@
#!/bin/bash -ex
apt-get install -y libssl-dev pkg-config

View file

@ -1,4 +1,4 @@
#!/bin/bash -e
#!/bin/bash -ex
git clone --depth 1 https://github.com/mheistermann/HashPump-partialhash.git
cd HashPump-partialhash

View file

@ -1,4 +1,4 @@
#!/bin/bash
#!/bin/bash -ex
set -eu -o pipefail
pacman -Syu --noconfirm --needed openssl

Some files were not shown because too many files have changed in this diff Show more