write-ups-challenges-2019-2020/call_me_maybe/Dockerfile

18 lines
312 B
Docker
Raw Permalink Normal View History

2022-11-24 21:43:03 +00:00
FROM ubuntu
RUN mkdir /src
WORKDIR /src
COPY call_me_maybe.c .
RUN apt-get update && \
apt-get install -y build-essential
RUN gcc -fno-stack-protector -o call_me_maybe call_me_maybe.c
RUN cp /src/call_me_maybe /
RUN rm -r /src
RUN chmod +x /call_me_maybe
RUN useradd ctf
USER ctf
CMD ["/call_me_maybe"]