mirror of
https://github.com/telekom-security/tpotce.git
synced 2025-07-02 01:27:27 -04:00
add h0neytr4p honeypot
This commit is contained in:
30
docker/h0neytr4p/Dockerfile
Normal file
30
docker/h0neytr4p/Dockerfile
Normal file
@ -0,0 +1,30 @@
|
||||
FROM golang:1.21-alpine AS builder
|
||||
WORKDIR /app
|
||||
#
|
||||
RUN apk -U add git openssl
|
||||
RUN git clone https://github.com/t3chn0m4g3/h0neytr4p -b v0.32 /app
|
||||
RUN go mod download
|
||||
RUN go mod tidy
|
||||
RUN go build -o /app/main
|
||||
RUN openssl req \
|
||||
-nodes \
|
||||
-x509 \
|
||||
-sha512 \
|
||||
-newkey rsa:4096 \
|
||||
-keyout "app.key" \
|
||||
-out "app.crt" \
|
||||
-days 3650 \
|
||||
-subj '/C=AU/ST=Some-State/O=Internet Widgits Pty Ltd'
|
||||
RUN chmod 444 app.key app.crt
|
||||
#
|
||||
FROM scratch
|
||||
#
|
||||
COPY --from=builder /app/main /opt/h0neytr4p/h0neytr4p
|
||||
COPY --from=builder /app/traps /opt/h0neytr4p/traps
|
||||
COPY --from=builder /app/app.key /opt/h0neytr4p/
|
||||
COPY --from=builder /app/app.crt /opt/h0neytr4p/
|
||||
#
|
||||
WORKDIR /opt/h0neytr4p
|
||||
USER 2000:2000
|
||||
CMD ["-cert=app.crt", "-key=app.key", "-log=log/log.json", "-catchall=false", "-payload=/data/h0neytr4p/payloads/", "-wildcard=true", "-traps=traps/"]
|
||||
ENTRYPOINT ["./h0neytr4p"]
|
22
docker/h0neytr4p/docker-compose.yml
Normal file
22
docker/h0neytr4p/docker-compose.yml
Normal file
@ -0,0 +1,22 @@
|
||||
networks:
|
||||
h0neytr4p_local:
|
||||
|
||||
services:
|
||||
|
||||
# H0neytr4p service
|
||||
h0neytr4p:
|
||||
build: .
|
||||
container_name: h0neytr4p
|
||||
restart: always
|
||||
# cpu_count: 1
|
||||
# cpus: 0.25
|
||||
networks:
|
||||
- h0neytr4p_local
|
||||
ports:
|
||||
- "80:80"
|
||||
- "443:443"
|
||||
image: "dtagdevsec/h0neytr4p:24.04"
|
||||
read_only: true
|
||||
volumes:
|
||||
- $HOME/tpotce/data/h0neytr4p/log/:/opt/h0neytr4p/log/
|
||||
- $HOME/tpotce/data/h0neytr4p/payloads/:/data/h0neytr4p/payloads/
|
Reference in New Issue
Block a user