Download the PHP package ikechukwukalu/clamavfileupload without Composer
On this page you can find all versions of the php package ikechukwukalu/clamavfileupload. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download ikechukwukalu/clamavfileupload
More information about ikechukwukalu/clamavfileupload
Files in ikechukwukalu/clamavfileupload
Package clamavfileupload
Short Description File upload with ClamAV anti-virus scan
License MIT
Informations about the package clamavfileupload
CLAMAV FILE UPLOAD
A simple File upload Laravel package with ClamAV anti-virus scan. This library was built riding on an existing clamav php library kissit/php-clamav-scan.
REQUIREMENTS
- PHP 8.0+
- Laravel 9+
- Clamav
STEPS TO INSTALL
-
php artisan vendor:publish --tag=cfu-config
php artisan vendor:publish --tag=cfu-migrations
php artisan migrate
CLAMAV SCAN FILE UPLOAD
QUEUED CLAMAV SCAN FILE UPLOAD
This process stores the file in a tmp
directory and sets up a queue for the clamav scan and uploads the tmp
files to their designated directory. At the end of the process temp files would have been removed from the tmp
directory.
- To use
Redis
setREDIS_CLIENT=predis
andQUEUE_CONNECTION=redis
within your.env
file. php artisan queue:work
NO CLAMAV SCAN FILE UPLOAD
HASH
If the HASHED
param within your .env
is set to true
the file_name
, path
and url
fields will be encrypted before they are saved into the DB.
The stored file will also be encrypted.
It might be helpful to extend the Model file Ikechukwukalu\Clamavfileupload\Models\FileUpload
and add the following code:
Sample codes to view and download encrypted file:
EVENTS
NOTE
- When a single file scanned fails, the process is ended and every uploaded file is removed.
- Every batch of uploaded files has a
$ref
UUID assigned to them. - When using
s3
disk, files are first stored in atmp
directory using thelocal
disk where they will be scanned before being uploaded to thes3
bucket - Always add custom
s3
disks to thes3_disk
array within the configurations file. - Model file
Ikechukwukalu\Clamavfileupload\Models\FileUpload
PUBLISH LANG
php artisan vendor:publish --tag=cfu-lang
LICENSE
The CFU package is an open-sourced software licensed under the MIT license.
All versions of clamavfileupload with dependencies
illuminate/contracts Version ^9.0|^10.0|^11.0
illuminate/database Version ^9.0|^10.0|^11.0
illuminate/events Version ^9.0|^10.0|^11.0
illuminate/http Version ^9.0|^10.0|^11.0
illuminate/queue Version ^9.0|^10.0|^11.0
illuminate/support Version ^9.0|^10.0|^11.0
php Version >=8.0
symfony/http-foundation Version ^5.4|^6.0|^7.0