V1rus Private
User / IP
:
216.73.217.108
Host / Server
:
190.92.174.125 / aerosofthealthcare.com
System
:
Linux s3739.bom1.stableserver.net 4.18.0-513.24.1.lve.2.el8.x86_64 #1 SMP Fri May 24 12:42:50 UTC 2024 x86_64
Cmd
|
Upload
|
Mass Deface
|
Create
|
Sym
:
/
lib64
/
nagios
/
plugins
/
Viewing: check_backups.php
#!/usr/local/bin/php <?php $decoded = json_decode(shell_exec('sudo /usr/bin/jetbackup5api -F listAlerts -O json'), 1); $critical = array_filter($decoded['data']['alerts'], function($level) { return $level['level'] === 4; }); if(empty($critical)) { echo "No critical alerts." . PHP_EOL; exit(0); } foreach ($critical as $c) { if(preg_match("/\b(connecting|aborted|destination)\b/", $c['message'])) { $response[] = $c; } } if(!empty($response)) { print_r(yaml_emit($response)); exit(2); } echo "No critical alerts.". PHP_EOL; exit(0);
Coded With 💗 by
HanzOFC