mirror of
https://github.com/signalwire/freeswitch.git
synced 2025-08-13 01:26:58 +00:00
This commit is contained in:
26
scripts/perl/honeypot.pl
Executable file
26
scripts/perl/honeypot.pl
Executable file
@@ -0,0 +1,26 @@
|
||||
#!/usr/bin/perl
|
||||
#
|
||||
# Add this to conf/dialplan/public but only if you wish to setup a honeypot.
|
||||
#
|
||||
# <X-PRE-PROCESS cmd="exec" data="$${base_dir}/bin/honeypot.pl"/>
|
||||
#
|
||||
|
||||
use Data::Dumper;
|
||||
use LWP::Simple;
|
||||
|
||||
# http://www.infiltrated.net/voipabuse/numberscalled.txt
|
||||
|
||||
my @numberscalled = split(/\n/, get("http://www.infiltrated.net/voipabuse/numberscalled.txt"));
|
||||
|
||||
foreach $number (@numberscalled) {
|
||||
my ($num,$ts) = split(/\t/, $number);
|
||||
|
||||
print "<extension name=\"$num\">\n";
|
||||
print " <condition field=\"destination_number\" expression=\"^$num\$\">\n";
|
||||
print " <action application=\"answer\"/>\n";
|
||||
print " <action application=\"sleep\" data=\"30000\"/>\n";
|
||||
print " </condition>\n";
|
||||
print "</extension>\n";
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user