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

Enhancement: Use Public IP as the Target IP #104

Closed
mikep11 opened this issue Apr 7, 2018 · 5 comments
Closed

Enhancement: Use Public IP as the Target IP #104

mikep11 opened this issue Apr 7, 2018 · 5 comments

Comments

@mikep11
Copy link

mikep11 commented Apr 7, 2018

I notice in the reports that the target IP is showing my private IP address. Wouldn't it be more helpful to show the public IP that is being attacked?

Or is there a setting I missed?

@gebhard73
Copy link
Contributor

This is a feature which Johannes has started implementing some months ago (using the dshield IP lookup API). Hopefully this is still in the pipeline ;-)

@bgant
Copy link
Contributor

bgant commented May 7, 2018

It looks like /etc/dshield.ini has placeholders for this future work (honeypotip= and replacehoneypotip=).

In the meantime, I inserted three lines in the /srv/dshield/dshield.pl file after rsyslog is restarted and before the /var/log/dshield.log.old file is opened for parsing. The lines just lookup and replace my internal private IP with my external IP before the log is parsed:

`/etc/init.d/rsyslog restart`;
my $privateip=`hostname -I | tr -d ' \n'`;
my $internetip=`curl --silent http://ipecho.net/plain`;
`sed -i 's/DST=$privateip/DST=$internetip/g' /var/log/dshield.log.old`;
open(F,'/var/log/dshield.log.old');

@jullrich
Copy link
Contributor

jullrich commented May 7, 2018

thanks for the solution. I will try to add that. We had some issues with hosts running IPv6 in which case the IPv6 address was reported. But with curl (or wget) I should be able to force IPv4. will try that.

@mikep11
Copy link
Author

mikep11 commented Sep 8, 2018

The solution by @bgant no longer works - it looks like dshield.pl is no longer called.
Has this feature been implemented and I need to enable it somewhere?

@jullrich
Copy link
Contributor

jullrich commented Nov 6, 2019

added the public IP of the honeypot to the configuration (and may be used later). I am using our own API for it to avoid dependency issues.

@jullrich jullrich closed this as completed Nov 6, 2019
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

No branches or pull requests

4 participants