定制 jord-jd/laravel-malware-validation-rule 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

jord-jd/laravel-malware-validation-rule

Composer 安装命令:

composer require jord-jd/laravel-malware-validation-rule

包简介

Scans uploaded files for viruses and other malware

README 文档

README

Build Status

The Laravel Malware Validation Rule package provides a validation rule that scans uploaded files for viruses and other malware.

Installation

To install the Laravel Malware Validation Rule package, run the following command

composer require jord-jd/laravel-malware-validation-rule

This package makes use of the ClamAV daemon to perform virus/malware scanning. You can install ClamAV in Ubuntu/Debian with the following command.

sudo apt install clamav-daemon

Your ClamAV installation should automatically update virus defintions. However, you can update your ClamAV virus definitions manually using the freshclam command. It is recommended to restart the ClamAV daemon after the virus definitions have been updated to ensure they take effect.

sudo freshclam
sudo service clamav-daemon restart

Usage

See the following basic usage example, which demonstrates how to validate a basic file upload does not contain contain a known virus/malware.

use \JordJD\LaravelMalwareValidationRule\Rules\Malware;

// ...

public function rules()
{
    return [
        'my_file' => ['required', 'file', new Malware()],
    ];
}

By default the validation rule message will include the name of the detected virus/malware. If you do not wish the malware name to be shown in the validation message you can turn this off as shown below.

public function rules()
{
    $showMalwareName = false;

    return [
        'my_file' => ['required', 'file', new Malware($showMalwareName)],
    ];
}

jord-jd/laravel-malware-validation-rule 适用场景与选型建议

jord-jd/laravel-malware-validation-rule 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 0 次下载、GitHub Stars 达 4, 最近一次更新时间为 2026 年 02 月 14 日, 在 PHP 生态内属于活跃度较高的组件。

我们在过去多个企业项目中使用过 jord-jd/laravel-malware-validation-rule 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。

围绕 jord-jd/laravel-malware-validation-rule 我们能提供哪些服务?
定制开发 / 二次开发

基于 jord-jd/laravel-malware-validation-rule 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。

BUG 修复 & 性能优化

线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。

项目外包 & 长期维护

承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。

yvsm@zunyunkeji.com QQ:316430983 微信:yvsm316 西安尊云信息科技 · 专注 PHP / Go / 分布式系统研发

统计信息

  • 总下载量: 0
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 4
  • 点击次数: 26
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 4
  • Watchers: 0
  • Forks: 1
  • 开发语言: PHP

其他信息

  • 授权协议: LGPL-3.0-only
  • 更新时间: 2026-02-14