PHP code example of aedart / athenaeum-antivirus

1. Go to this page and download the library: Download aedart/athenaeum-antivirus library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

aedart / athenaeum-antivirus example snippets


use Aedart\Antivirus\Facades\Antivirus;

$result = Antivirus::scan($file);

if (!$result->isOk()) {
    // File may contain harmful code... do something!
}

use Aedart\Antivirus\Validation\Rules\InfectionFreeFile;
use Illuminate\Support\Facades\Route;
use Illuminate\Http\Request;

Route::post('/pictures', function (Request $request) {
    $request->validate([
        'picture' => [
            '