File manager - Edit - /usr/local/cpanel/base/frontend/jupiter/cpguard/scanner/virus_detail.php
Back
<?php include_once dirname(__DIR__) . "/includes/init.php"; include_once $base_dir . "/classes/language.class.php"; $lang = new Language('scanner_logs'); include_once dirname(__DIR__) . "/classes/api.class.php"; $api = new Api($current_user); $data = array('id' => filter_var($_POST['id'])); $result = $api->request('virusDetail', $data); //print_r($result); $virus_row = $result; $quarantine_path = $virus_row['quarantine_path'] ?? ''; $file_size = $current_path = NULL; if ($virus_row['file_status'] == 4) { $status = 'deleted'; } else if ($virus_row['file_status'] == 1) { $file_size = filesize($quarantine_path); $status = 'quarantine'; $current_path = $quarantine_path; } else if ($virus_row['file_status'] == 0) { if (file_exists($virus_row['path'])) { $file_size = filesize($virus_row['path']); $current_path = $virus_row['path']; } $status = 'at original location'; } else if ($virus_row['file_status'] == 2) { $status = 'disabled'; $file_size = filesize($virus_row['path']); } else if ($virus_row['file_status'] == 3) { $status = 'cleaned'; $file_size = filesize($virus_row['path']); $current_path = $virus_row['path']; } ?> <div class="virus-title"> <h3>VIRUS DETAIL</h3> <button onclick="unBlockUI()"><i class="fa fa-times"></i></button> </div> <div class="details-container"> <div class="detail-item"> <span class="head">#ID</span> <span class="detail"><?php echo $virus_row['id']; ?></span> </div> <div class="detail-item"> <span class="head"><?php $lang->_('virusdetail.filename'); ?></span> <span class="detail"><?php echo basename($virus_row['path']); ?></span> </div> <div class="detail-item"> <span class="head"><?php $lang->_('virusdetail.originalpath'); ?></span> <span class="detail"><?php echo $virus_row['path']; ?></span> </div> <div class="detail-item"> <span class="head"><?php $lang->_('virusdetail.reason'); ?></span> <span class="detail"><?php echo $virus_row['reason']; ?></span> </div> <div class="detail-item"> <span class="head"><?php $lang->_('virusdetail.definition'); ?></span> <span class="detail"><?php echo $virus_row['definition']; ?></span> </div> <div class="detail-item"> <span class="head"><?php $lang->_('virusdetail.time'); ?></span> <span class="detail"><?php echo $virus_row['time']; ?></span> </div> <?php if ($status == 'quarantine') { ?> <div class="detail-item"> <span class="head"><?php $lang->_('virusdetail.quarantinepath'); ?></span> <span class="detail"><?php echo $quarantine_path; ?></span> </div> <?php } if (!empty($file_size)) { ?> <div class="detail-item"> <span class="head"><?php $lang->_('virusdetail.filesize'); ?></span> <span class="detail"><?php echo $file_size; ?> bytes</span> </div> <?php }?> <?php if (!empty($status)) { ?> <div class="detail-item"> <span class="head"><?php $lang->_('virusdetail.status'); ?></span> <span class="detail"><?php echo $status == 'quarantine' ? '<span class="badge badge-success">Quarantined</span>' : '<span class="badge badge-success">' . $status . '</span>'; ?></span> </div> <?php }?> </div> <div class="virus-actions"> <?php if ($status == 'at original location') { ?> <button type="button" class="btn btn-primary table-action" data-id="<?php echo $virus_row['id']; ?>" data-action="disable"><?php $lang->_('virusdetail.button.disable'); ?></button> <?php } if ($status != 'quarantine' && !empty($file_size)) { ?> <button type="button" class="btn btn-primary table-action" data-id="<?php echo $virus_row['id']; ?>" data-action="quarantine"><?php $lang->_('virusdetail.button.quarantine'); ?></button> <?php } if ($status != 'deleted') { ?> <button type="button" class="btn btn-primary table-action" data-id="<?php echo $virus_row['id']; ?>" data-action="delete"><?php $lang->_('virusdetail.button.delete'); ?></button> <button type="button" class="btn btn-primary table-action" data-id="<?php echo $virus_row['id']; ?>" data-action="report"><?php $lang->_('virusdetail.button.false'); ?></button> <?php } ?> </div> <script> initTableActions(); cjQ('.virus-actions').click(function(){ cjQ('.virus-actions button').attr('disabled', true); }); </script>
| ver. 1.4 |
Github
|
.
| PHP 8.1.34 | Generation time: 0.03 |
proxy
|
phpinfo
|
Settings