-
Notifications
You must be signed in to change notification settings - Fork 9
/
Dockerfile
48 lines (42 loc) · 1.33 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
FROM ubuntu:22.04
ENV DEBIAN_FRONTEND=noninteractive
RUN apt -y update && apt -y upgrade && apt install -y --no-install-recommends \
build-essential \
cmake \
gcc-multilib \
git \
python3-dev \
# Binary Ninja deps https://docs.binary.ninja/guide/troubleshooting/index.html#headless-ubuntu
libgl1-mesa-glx \
libfontconfig1 \
libxrender1 \
libegl1-mesa \
libxi6 \
libnspr4 \
libsm6 \
libpython2.7 \
libdbus-1-3 \
libxkbcommon-x11-0 \
# others
virtualenv \
unzip \
astyle \
graphviz \
# plotting ascii graphs for debug purposes
libgraph-easy-perl \
z3
# set up binaryninja
COPY BinaryNinja.zip /tmp/BinaryNinja.zip
RUN unzip /tmp/BinaryNinja.zip -d /opt/ && rm /tmp/BinaryNinja.zip && mkdir -p /root/.binaryninja/
# set up binaryninja license
COPY license.txt /root/.binaryninja/license.dat
# set up pydec
RUN mkdir -p /opt/dewolf && test -f /opt/dewolf/install_api.py || ln -s /opt/binaryninja/scripts/install_api.py /opt/dewolf/install_api.py
# update binja and cache this docker image
COPY . /opt/dewolf
RUN cd /opt/dewolf & make -f /opt/dewolf/Makefile.venv venv VENV_PATH=/opt/dewolf/.venv PREFIX=/opt/dewolf
RUN mkdir -p /root/.binaryninja/plugins/
WORKDIR /opt/dewolf
# activate venv for docker exec
ENV VIRTUAL_ENV=/opt/dewolf/.venv
ENV PATH="$VIRTUAL_ENV/bin:$PATH"