Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

added basic canary webhook implementation #10

Open
wants to merge 6 commits into
base: main
Choose a base branch
from

Conversation

divine-architect
Copy link

@divine-architect divine-architect commented Feb 2, 2025

This PR aims to add canary webhooks support to the DICOMHawk honeypot server.
Steps to reproduce have been added in the README.md

It utilizes a .env file to store the canary url.

Planned roadmap:

  • Specify what kind of request was made when the alert is sent
  • Lure the attacker via a nested honeypot --> and trigger another webhook for more info.

Please do let me know if any other changes are to be made!

@divine-architect divine-architect changed the title added basic canary webhooks implementation added basic canary webhook implementation Feb 2, 2025
@naxatra2
Copy link

naxatra2 commented Feb 3, 2025

I think we can also add in this to include event type, attacker IP, server IP, and timestamp. Is it a good idea ? otherwise logging will not seem useful ?

@divine-architect
Copy link
Author

hey valid points, however these are taken care of by the canary webhook which logs in the IP and other such info

attached is an example
censored_image

@naxatra2
Copy link

naxatra2 commented Feb 3, 2025

Ohh, I didn't think about it that way. nicee

@divine-architect
Copy link
Author

Ohh, I didn't think about it that way. nicee

no worries, the only issue with this method is that since the dicom server itself triggers the canary token webhook, we cannot get the actual ip of the attacker, instead we get the IP of the server. I tried thinking around it, i.e. injecting the canary token URL into the dicom payload as an unused private tag, however that didn't work.

We could possibly setup a virtual directory and setup webhooks to check if triggered, but I believe that's out of scope for this tool.

@divine-architect
Copy link
Author

divine-architect commented Feb 3, 2025

I realised normal http triggers for the canary token won't work with DICOM, and embedding tokens in a .dcm file has a low success rate of trigger unless a http request is made. Hence this approach let's you alert about intrusion in the honeypot server.

It uses smtp to send an email with the client/attackers IP, port, etc.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants