Adding jphide analyzer
This commit is contained in:
+19
-1
@@ -5,13 +5,26 @@ FROM python:3.14-slim AS builder
|
||||
|
||||
# Install wget only to download OpenStego
|
||||
RUN apt-get update && apt-get install -y --no-install-recommends \
|
||||
wget \
|
||||
wget git build-essential \
|
||||
&& rm -rf /var/lib/apt/lists/*
|
||||
|
||||
# Download OpenStego
|
||||
RUN wget https://github.com/syvaidya/openstego/releases/download/openstego-0.8.6/openstego_0.8.6-1_all.deb \
|
||||
-O /tmp/openstego.deb
|
||||
|
||||
# Builder stage - add after other tool compilations
|
||||
RUN git clone https://github.com/h3xx/jphs.git /tmp/jphs
|
||||
RUN cd /tmp/jphs/jpeg-8a && ./configure && make
|
||||
RUN cd /tmp/jphs && sed -i 's/open(seekfilename,O_WRONLY|O_TRUNC|O_CREAT)/open(seekfilename,O_WRONLY|O_TRUNC|O_CREAT, 0644)/' jpseek.c
|
||||
RUN cd /tmp/jphs \
|
||||
&& sed -i 's/^LIBS = .*/JPEG_OBJS = $(filter-out jpeg-8a\/cjpeg.o jpeg-8a\/djpeg.o jpeg-8a\/jpegtran.o jpeg-8a\/rdjpgcom.o jpeg-8a\/wrjpgcom.o,$(wildcard jpeg-8a\/\*.o))/' Makefile \
|
||||
&& sed -i 's/^LDFLAGS = .*/LDFLAGS =/' Makefile \
|
||||
&& sed -i 's/^jphide: \(.*\)$/jphide: \1 $(JPEG_OBJS)/' Makefile \
|
||||
&& sed -i 's/^jpseek: \(.*\)$/jpseek: \1 $(JPEG_OBJS)/' Makefile
|
||||
RUN cd /tmp/jphs && make all
|
||||
RUN cd /tmp/jphs && cp jphide jpseek /usr/local/bin/
|
||||
RUN rm -rf /tmp/jphs
|
||||
|
||||
# ==========================
|
||||
# Stage 2 : Image runtime minimale
|
||||
# ==========================
|
||||
@@ -21,6 +34,7 @@ WORKDIR /app
|
||||
|
||||
# Install runtime + stego tools
|
||||
RUN apt-get update && apt-get install -y --no-install-recommends \
|
||||
expect \
|
||||
default-jre \
|
||||
file \
|
||||
ruby \
|
||||
@@ -48,5 +62,9 @@ COPY aperisolve/ /app/aperisolve/
|
||||
# Install Python dependencies
|
||||
RUN pip install --no-cache-dir -r /app/aperisolve/requirements.txt
|
||||
|
||||
# Copy jphide binaries
|
||||
COPY --from=builder /usr/local/bin/jphide /usr/local/bin/jphide
|
||||
COPY --from=builder /usr/local/bin/jpseek /usr/local/bin/jpseek
|
||||
|
||||
# Commande de lancement
|
||||
CMD ["gunicorn", "-w", "8", "-b", "0.0.0.0:5000", "--access-logfile", "-", "--error-logfile", "-", "--log-level", "info", "--capture-output", "aperisolve.utils.wsgi:application"]
|
||||
|
||||
Reference in New Issue
Block a user