elceef / dnstwist

Domain name permutation engine for detecting homograph phishing attacks, typo squatting, and brand impersonation
https://dnstwist.it
Apache License 2.0
4.76k stars 761 forks source link

Docker container for `20220120` fails with `ssdeep` in GitHub actions environment #142

Closed olifre closed 2 years ago

olifre commented 2 years ago

After upgrading to the recent 20220120 release, running the container as follows:

docker run --entrypoint /opt/dnstwist/dnstwist.py elceef/dnstwist --ssdeep --debug heise.de

yields exit code 1 (without any messages) when used from within a GitHub actions workflow in a GitHub runner, i.e. I use:

      - name: Check heise.de with dnstwist
        uses: docker://elceef/dnstwist
        with:
          entrypoint: /opt/dnstwist/dnstwist.py
          args: --ssdeep --debug heise.de

in my workflow, and the workflow fails without any output with exit code 1. The same workflow worked without issues with the previous release.

Running dnstwist from git natively inside the GitHub runner does not show this issue. Running the container on a CentOS 7 VM also does not show this issue.

Entering a shell in a GitHub actions runner (e.g. with action upterm), I can reproduce this behaviour, i.e. docker run as outlined above shows exit code 1 without any other output.

Ideas for further debugging are very welcome.

olifre commented 2 years ago

Note: This only happens with the ssdeep flag. Using other flags does not trigger this problem.

elceef commented 2 years ago

I think I traced down the problem. Docker image debian:stable-slim does not contain package ca-certificates by default. Added this package to Dockerfile which should resolve the issue.

olifre commented 2 years ago

Indeed, that does the trick! Many thanks for the quick fix! :+1: