Matthias Andreas Benkard | 7b2a3a1 | 2021-08-16 10:57:25 +0200 | [diff] [blame] | 1 | FROM alpine:3.13 |
Matthias Andreas Benkard | b382b10 | 2021-01-02 15:32:21 +0100 | [diff] [blame] | 2 | LABEL maintainer "Andre Peters <andre.peters@servercow.de>" |
| 3 | |
| 4 | WORKDIR /app |
| 5 | |
| 6 | #RUN addgroup -S olefy && adduser -S olefy -G olefy \ |
Matthias Andreas Benkard | 7b2a3a1 | 2021-08-16 10:57:25 +0200 | [diff] [blame] | 7 | RUN apk add --virtual .build-deps gcc musl-dev python3-dev libffi-dev openssl-dev cargo \ |
| 8 | && apk add --update --no-cache python3 py3-pip openssl tzdata libmagic \ |
Matthias Andreas Benkard | b382b10 | 2021-01-02 15:32:21 +0100 | [diff] [blame] | 9 | && pip3 install --upgrade pip \ |
| 10 | && pip3 install --upgrade asyncio python-magic \ |
| 11 | && pip3 install --upgrade https://github.com/HeinleinSupport/oletools/archive/master.zip \ |
| 12 | && apk del .build-deps |
| 13 | # && sed -i 's/decompress_stream(bytearray(compressed_code))/bytes2str(decompress_stream(bytearray(compressed_code)))/g' /usr/lib/python3.8/site-packages/oletools/olevba.py |
| 14 | |
| 15 | ADD https://raw.githubusercontent.com/HeinleinSupport/olefy/master/olefy.py /app/ |
| 16 | |
| 17 | RUN chown -R nobody:nobody /app /tmp |
| 18 | |
| 19 | USER nobody |
| 20 | |
| 21 | CMD ["python3", "-u", "/app/olefy.py"] |