403Webshell
Server IP : 162.144.4.212  /  Your IP : 216.73.217.95
Web Server : Apache
System : Linux gator2125.hostgator.com 5.14.0-687.15.1.el9_8.x86_64 #1 SMP PREEMPT_DYNAMIC Thu Jun 11 08:51:45 EDT 2026 x86_64
User : cozeellc ( 2980)
PHP Version : 8.3.33
Disable Function : NONE
MySQL : OFF |  cURL : ON |  WGET : ON |  Perl : ON |  Python : OFF |  Sudo : ON |  Pkexec : ON
Directory :  /proc/self/root/etc/cron.daily/

Upload File :
current_dir [ Writeable] document_root [ Writeable]

 

Command :


[ Back ]     

Current File : /proc/self/root/etc/cron.daily/pull_googlebot_ips.pl
#!/usr/bin/perl
use strict;
use warnings;
use LWP::Simple;
use JSON;

# URL of the JSON file containing Google's IP ranges
my $url = "https://www.gstatic.com/ipranges/goog.json";

my $json_content = get($url);
die "Failed to retrieve the JSON file from $url" unless defined $json_content;
my $decoded_json = decode_json($json_content);

my @ranges;
foreach my $prefix (@{$decoded_json->{prefixes}}) {
    push @ranges, $prefix->{ipv4Prefix} if $prefix->{ipv4Prefix};
    push @ranges, $prefix->{ipv6Prefix} if $prefix->{ipv6Prefix};
}

die "No ip ranges returned" unless scalar @ranges > 1;
open(my $fh, '>', '/etc/httpd/modsecurity.d/googlebot_ips.txt') or die "Could not open file 'googlebot_ips.txt' $!";
foreach my $range (@ranges){
    print $fh "$range\n";
}
close $fh;

Youez - 2016 - github.com/yon3zu
LinuXploit