├── .github └── ISSUE_TEMPLATE │ ├── bug.yaml │ ├── documentation.yaml │ └── feature.yaml ├── .gitignore ├── .travis.yml ├── LICENSE.md ├── README.md ├── composer.json ├── composer.lock ├── docker-compose.yml ├── phpunit.xml ├── src └── ClamAV │ ├── ClamAV.php │ ├── Network.php │ └── Pipe.php └── tests └── ClamAV └── ClamAVTest.php /.github/ISSUE_TEMPLATE/bug.yaml: -------------------------------------------------------------------------------- 1 | name: "🐛 Bug Report" 2 | description: "Submit a bug report to help us improve" 3 | title: "🐛 Bug Report: " 4 | labels: [bug] 5 | body: 6 | - type: markdown 7 | attributes: 8 | value: | 9 | Thanks for taking the time to fill out our bug report form 🙏 10 | - type: textarea 11 | id: steps-to-reproduce 12 | validations: 13 | required: true 14 | attributes: 15 | label: "👟 Reproduction steps" 16 | description: "How do you trigger this bug? Please walk us through it step by step." 17 | placeholder: "When I ..." 18 | - type: textarea 19 | id: expected-behavior 20 | validations: 21 | required: true 22 | attributes: 23 | label: "👍 Expected behavior" 24 | description: "What did you think would happen?" 25 | placeholder: "It should ..." 26 | - type: textarea 27 | id: actual-behavior 28 | validations: 29 | required: true 30 | attributes: 31 | label: "👎 Actual Behavior" 32 | description: "What did actually happen? Add screenshots, if applicable." 33 | placeholder: "It actually ..." 34 | - type: dropdown 35 | id: php-clamav-version 36 | attributes: 37 | label: "🎲 PHP ClamAV version" 38 | description: "What version of Appwrite ClamAV PHP Client are you running?" 39 | options: 40 | - Version 1.1.x 41 | - Version 1.0.x 42 | - Different version (specify in environment) 43 | validations: 44 | required: true 45 | - type: dropdown 46 | id: operating-system 47 | attributes: 48 | label: "💻 Operating system" 49 | description: "What OS is your server / device running on?" 50 | options: 51 | - Linux 52 | - MacOS 53 | - Windows 54 | - Something else 55 | validations: 56 | required: true 57 | - type: textarea 58 | id: enviromnemt 59 | validations: 60 | required: false 61 | attributes: 62 | label: "🧱 Your Environment" 63 | description: "Is your environment customized in any way?" 64 | placeholder: "I use Cloudflare for ..." 65 | - type: checkboxes 66 | id: no-duplicate-issues 67 | attributes: 68 | label: "👀 Have you spent some time to check if this issue has been raised before?" 69 | description: "Have you Googled for a similar issue or checked our older issues for a similar bug?" 70 | options: 71 | - label: "I checked and didn't find similar issue" 72 | required: true 73 | - type: checkboxes 74 | id: read-code-of-conduct 75 | attributes: 76 | label: "🏢 Have you read the Code of Conduct?" 77 | options: 78 | - label: "I have read the [Code of Conduct](https://github.com/appwrite/appwrite/blob/HEAD/CODE_OF_CONDUCT.md)" 79 | required: true 80 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/documentation.yaml: -------------------------------------------------------------------------------- 1 | name: "📚 Documentation" 2 | description: "Report an issue related to documentation" 3 | title: "📚 Documentation: " 4 | labels: [documentation] 5 | body: 6 | - type: markdown 7 | attributes: 8 | value: | 9 | Thanks for taking the time to make our documentation better 🙏 10 | - type: textarea 11 | id: issue-description 12 | validations: 13 | required: true 14 | attributes: 15 | label: "💭 Description" 16 | description: "A clear and concise description of what the issue is." 17 | placeholder: "Documentation should not ..." 18 | - type: checkboxes 19 | id: no-duplicate-issues 20 | attributes: 21 | label: "👀 Have you spent some time to check if this issue has been raised before?" 22 | description: "Have you Googled for a similar issue or checked our older issues for a similar bug?" 23 | options: 24 | - label: "I checked and didn't find similar issue" 25 | required: true 26 | - type: checkboxes 27 | id: read-code-of-conduct 28 | attributes: 29 | label: "🏢 Have you read the Code of Conduct?" 30 | options: 31 | - label: "I have read the [Code of Conduct](https://github.com/appwrite/appwrite/blob/HEAD/CODE_OF_CONDUCT.md)" 32 | required: true 33 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/feature.yaml: -------------------------------------------------------------------------------- 1 | name: 🚀 Feature 2 | description: "Submit a proposal for a new feature" 3 | title: "🚀 Feature: " 4 | labels: [feature] 5 | body: 6 | - type: markdown 7 | attributes: 8 | value: | 9 | Thanks for taking the time to fill out our feature request form 🙏 10 | - type: textarea 11 | id: feature-description 12 | validations: 13 | required: true 14 | attributes: 15 | label: "🔖 Feature description" 16 | description: "A clear and concise description of what the feature is." 17 | placeholder: "You should add ..." 18 | - type: textarea 19 | id: pitch 20 | validations: 21 | required: true 22 | attributes: 23 | label: "🎤 Pitch" 24 | description: "Please explain why this feature should be implemented and how it would be used. Add examples, if applicable." 25 | placeholder: "In my use-case, ..." 26 | - type: checkboxes 27 | id: no-duplicate-issues 28 | attributes: 29 | label: "👀 Have you spent some time to check if this issue has been raised before?" 30 | description: "Have you Googled for a similar issue or checked our older issues for a similar bug?" 31 | options: 32 | - label: "I checked and didn't find similar issue" 33 | required: true 34 | - type: checkboxes 35 | id: read-code-of-conduct 36 | attributes: 37 | label: "🏢 Have you read the Code of Conduct?" 38 | options: 39 | - label: "I have read the [Code of Conduct](https://github.com/appwrite/appwrite/blob/HEAD/CODE_OF_CONDUCT.md)" 40 | required: true 41 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | .phpunit.result.cache 2 | /vendor/ 3 | /.idea/ 4 | -------------------------------------------------------------------------------- /.travis.yml: -------------------------------------------------------------------------------- 1 | dist: focal 2 | 3 | language: php 4 | 5 | php: 6 | - 8.0 7 | - 8.1 8 | 9 | notifications: 10 | email: 11 | - team@appwrite.io 12 | 13 | services: 14 | - docker 15 | 16 | before_install: 17 | - docker-compose up -d 18 | - sleep 60 19 | 20 | before_script: composer install 21 | 22 | script: 23 | - vendor/bin/phpunit 24 | -------------------------------------------------------------------------------- /LICENSE.md: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2013 Eldad Fux 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy of 6 | this software and associated documentation files (the "Software"), to deal in 7 | the Software without restriction, including without limitation the rights to 8 | use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of 9 | the Software, and to permit persons to whom the Software is furnished to do so, 10 | subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 17 | FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 18 | COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 19 | IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 20 | CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 21 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Appwrite ClamAV PHP Client 2 | 3 | [![Discord](https://img.shields.io/discord/564160730845151244?label=discord&style=flat-square)](https://appwrite.io/discord?r=Github) 4 | ![Total Downloads](https://img.shields.io/packagist/dt/appwrite/php-clamav.svg?style=flat-square) 5 | [![Build Status](https://img.shields.io/travis/com/appwrite/php-clamav?style=flat-square)](https://travis-ci.com/appwrite/php-clamav) 6 | [![Twitter Account](https://img.shields.io/twitter/follow/appwrite?color=00acee&label=twitter&style=flat-square)](https://twitter.com/appwrite) 7 | 8 | PHP Client to connect to ClamAV daemon over TCP or using a local socket from command line and scan your storage files for viruses. 9 | 10 | ## Getting Started 11 | 12 | Install using composer: 13 | ```bash 14 | composer require appwrite/php-clamav 15 | ``` 16 | 17 | ```php 18 | ping(); // Check ClamAV is up and running 27 | 28 | $clam->version(); // Check ClamAV version 29 | 30 | $clam->fileScan('path/to/file.dmg'); // Returns true if a file is clean or false if a file is infected 31 | 32 | $clam->reload(); // Reload ClamAV database 33 | 34 | $clam->shutdown(); // Shutdown ClamAV 35 | ``` 36 | 37 | ## System Requirements 38 | 39 | This package requires PHP 7.1 or later. We recommend using the latest PHP version whenever possible. 40 | 41 | ## Find Us 42 | 43 | * [GitHub](https://github.com/appwrite) 44 | * [Discord](https://appwrite.io/discord) 45 | * [Twitter](https://twitter.com/appwrite) 46 | 47 | ## Authors 48 | 49 | **Eldad Fux** 50 | 51 | + [https://twitter.com/eldadfux](https://twitter.com/eldadfux) 52 | + [https://github.com/eldadfux](https://github.com/eldadfux) 53 | 54 | ## Copyright and license 55 | 56 | The MIT License (MIT) [http://www.opensource.org/licenses/mit-license.php](http://www.opensource.org/licenses/mit-license.php) 57 | -------------------------------------------------------------------------------- /composer.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "appwrite/php-clamav", 3 | "description": "ClamAV network and pipe client for PHP", 4 | "type": "library", 5 | "keywords": [ 6 | "php", 7 | "clamav", 8 | "anti virus", 9 | "appwrite" 10 | ], 11 | "license": "MIT", 12 | "authors": [ 13 | { 14 | "name": "Eldad Fux", 15 | "email": "eldad@appwrite.io" 16 | } 17 | ], 18 | "autoload": { 19 | "psr-4": { 20 | "Appwrite\\ClamAV\\": "src/ClamAV" 21 | } 22 | }, 23 | "autoload-dev": { 24 | "psr-4": { 25 | "Appwrite\\ClamAV\\Tests\\": "tests/ClamAV" 26 | } 27 | }, 28 | "require": { 29 | "php": ">=8.0", 30 | "ext-sockets": "*" 31 | }, 32 | "require-dev": { 33 | "phpunit/phpunit": "^9" 34 | }, 35 | "minimum-stability": "stable" 36 | } 37 | -------------------------------------------------------------------------------- /composer.lock: -------------------------------------------------------------------------------- 1 | { 2 | "_readme": [ 3 | "This file locks the dependencies of your project to a known state", 4 | "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", 5 | "This file is @generated automatically" 6 | ], 7 | "content-hash": "fa520ce5ec18c933888bcf33ec560427", 8 | "packages": [], 9 | "packages-dev": [ 10 | { 11 | "name": "doctrine/instantiator", 12 | "version": "1.4.1", 13 | "source": { 14 | "type": "git", 15 | "url": "https://github.com/doctrine/instantiator.git", 16 | "reference": "10dcfce151b967d20fde1b34ae6640712c3891bc" 17 | }, 18 | "dist": { 19 | "type": "zip", 20 | "url": "https://api.github.com/repos/doctrine/instantiator/zipball/10dcfce151b967d20fde1b34ae6640712c3891bc", 21 | "reference": "10dcfce151b967d20fde1b34ae6640712c3891bc", 22 | "shasum": "" 23 | }, 24 | "require": { 25 | "php": "^7.1 || ^8.0" 26 | }, 27 | "require-dev": { 28 | "doctrine/coding-standard": "^9", 29 | "ext-pdo": "*", 30 | "ext-phar": "*", 31 | "phpbench/phpbench": "^0.16 || ^1", 32 | "phpstan/phpstan": "^1.4", 33 | "phpstan/phpstan-phpunit": "^1", 34 | "phpunit/phpunit": "^7.5 || ^8.5 || ^9.5", 35 | "vimeo/psalm": "^4.22" 36 | }, 37 | "type": "library", 38 | "autoload": { 39 | "psr-4": { 40 | "Doctrine\\Instantiator\\": "src/Doctrine/Instantiator/" 41 | } 42 | }, 43 | "notification-url": "https://packagist.org/downloads/", 44 | "license": [ 45 | "MIT" 46 | ], 47 | "authors": [ 48 | { 49 | "name": "Marco Pivetta", 50 | "email": "ocramius@gmail.com", 51 | "homepage": "https://ocramius.github.io/" 52 | } 53 | ], 54 | "description": "A small, lightweight utility to instantiate objects in PHP without invoking their constructors", 55 | "homepage": "https://www.doctrine-project.org/projects/instantiator.html", 56 | "keywords": [ 57 | "constructor", 58 | "instantiate" 59 | ], 60 | "support": { 61 | "issues": "https://github.com/doctrine/instantiator/issues", 62 | "source": "https://github.com/doctrine/instantiator/tree/1.4.1" 63 | }, 64 | "funding": [ 65 | { 66 | "url": "https://www.doctrine-project.org/sponsorship.html", 67 | "type": "custom" 68 | }, 69 | { 70 | "url": "https://www.patreon.com/phpdoctrine", 71 | "type": "patreon" 72 | }, 73 | { 74 | "url": "https://tidelift.com/funding/github/packagist/doctrine%2Finstantiator", 75 | "type": "tidelift" 76 | } 77 | ], 78 | "time": "2022-03-03T08:28:38+00:00" 79 | }, 80 | { 81 | "name": "myclabs/deep-copy", 82 | "version": "1.11.0", 83 | "source": { 84 | "type": "git", 85 | "url": "https://github.com/myclabs/DeepCopy.git", 86 | "reference": "14daed4296fae74d9e3201d2c4925d1acb7aa614" 87 | }, 88 | "dist": { 89 | "type": "zip", 90 | "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/14daed4296fae74d9e3201d2c4925d1acb7aa614", 91 | "reference": "14daed4296fae74d9e3201d2c4925d1acb7aa614", 92 | "shasum": "" 93 | }, 94 | "require": { 95 | "php": "^7.1 || ^8.0" 96 | }, 97 | "conflict": { 98 | "doctrine/collections": "<1.6.8", 99 | "doctrine/common": "<2.13.3 || >=3,<3.2.2" 100 | }, 101 | "require-dev": { 102 | "doctrine/collections": "^1.6.8", 103 | "doctrine/common": "^2.13.3 || ^3.2.2", 104 | "phpunit/phpunit": "^7.5.20 || ^8.5.23 || ^9.5.13" 105 | }, 106 | "type": "library", 107 | "autoload": { 108 | "files": [ 109 | "src/DeepCopy/deep_copy.php" 110 | ], 111 | "psr-4": { 112 | "DeepCopy\\": "src/DeepCopy/" 113 | } 114 | }, 115 | "notification-url": "https://packagist.org/downloads/", 116 | "license": [ 117 | "MIT" 118 | ], 119 | "description": "Create deep copies (clones) of your objects", 120 | "keywords": [ 121 | "clone", 122 | "copy", 123 | "duplicate", 124 | "object", 125 | "object graph" 126 | ], 127 | "support": { 128 | "issues": "https://github.com/myclabs/DeepCopy/issues", 129 | "source": "https://github.com/myclabs/DeepCopy/tree/1.11.0" 130 | }, 131 | "funding": [ 132 | { 133 | "url": "https://tidelift.com/funding/github/packagist/myclabs/deep-copy", 134 | "type": "tidelift" 135 | } 136 | ], 137 | "time": "2022-03-03T13:19:32+00:00" 138 | }, 139 | { 140 | "name": "nikic/php-parser", 141 | "version": "v4.15.1", 142 | "source": { 143 | "type": "git", 144 | "url": "https://github.com/nikic/PHP-Parser.git", 145 | "reference": "0ef6c55a3f47f89d7a374e6f835197a0b5fcf900" 146 | }, 147 | "dist": { 148 | "type": "zip", 149 | "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/0ef6c55a3f47f89d7a374e6f835197a0b5fcf900", 150 | "reference": "0ef6c55a3f47f89d7a374e6f835197a0b5fcf900", 151 | "shasum": "" 152 | }, 153 | "require": { 154 | "ext-tokenizer": "*", 155 | "php": ">=7.0" 156 | }, 157 | "require-dev": { 158 | "ircmaxell/php-yacc": "^0.0.7", 159 | "phpunit/phpunit": "^6.5 || ^7.0 || ^8.0 || ^9.0" 160 | }, 161 | "bin": [ 162 | "bin/php-parse" 163 | ], 164 | "type": "library", 165 | "extra": { 166 | "branch-alias": { 167 | "dev-master": "4.9-dev" 168 | } 169 | }, 170 | "autoload": { 171 | "psr-4": { 172 | "PhpParser\\": "lib/PhpParser" 173 | } 174 | }, 175 | "notification-url": "https://packagist.org/downloads/", 176 | "license": [ 177 | "BSD-3-Clause" 178 | ], 179 | "authors": [ 180 | { 181 | "name": "Nikita Popov" 182 | } 183 | ], 184 | "description": "A PHP parser written in PHP", 185 | "keywords": [ 186 | "parser", 187 | "php" 188 | ], 189 | "support": { 190 | "issues": "https://github.com/nikic/PHP-Parser/issues", 191 | "source": "https://github.com/nikic/PHP-Parser/tree/v4.15.1" 192 | }, 193 | "time": "2022-09-04T07:30:47+00:00" 194 | }, 195 | { 196 | "name": "phar-io/manifest", 197 | "version": "2.0.3", 198 | "source": { 199 | "type": "git", 200 | "url": "https://github.com/phar-io/manifest.git", 201 | "reference": "97803eca37d319dfa7826cc2437fc020857acb53" 202 | }, 203 | "dist": { 204 | "type": "zip", 205 | "url": "https://api.github.com/repos/phar-io/manifest/zipball/97803eca37d319dfa7826cc2437fc020857acb53", 206 | "reference": "97803eca37d319dfa7826cc2437fc020857acb53", 207 | "shasum": "" 208 | }, 209 | "require": { 210 | "ext-dom": "*", 211 | "ext-phar": "*", 212 | "ext-xmlwriter": "*", 213 | "phar-io/version": "^3.0.1", 214 | "php": "^7.2 || ^8.0" 215 | }, 216 | "type": "library", 217 | "extra": { 218 | "branch-alias": { 219 | "dev-master": "2.0.x-dev" 220 | } 221 | }, 222 | "autoload": { 223 | "classmap": [ 224 | "src/" 225 | ] 226 | }, 227 | "notification-url": "https://packagist.org/downloads/", 228 | "license": [ 229 | "BSD-3-Clause" 230 | ], 231 | "authors": [ 232 | { 233 | "name": "Arne Blankerts", 234 | "email": "arne@blankerts.de", 235 | "role": "Developer" 236 | }, 237 | { 238 | "name": "Sebastian Heuer", 239 | "email": "sebastian@phpeople.de", 240 | "role": "Developer" 241 | }, 242 | { 243 | "name": "Sebastian Bergmann", 244 | "email": "sebastian@phpunit.de", 245 | "role": "Developer" 246 | } 247 | ], 248 | "description": "Component for reading phar.io manifest information from a PHP Archive (PHAR)", 249 | "support": { 250 | "issues": "https://github.com/phar-io/manifest/issues", 251 | "source": "https://github.com/phar-io/manifest/tree/2.0.3" 252 | }, 253 | "time": "2021-07-20T11:28:43+00:00" 254 | }, 255 | { 256 | "name": "phar-io/version", 257 | "version": "3.2.1", 258 | "source": { 259 | "type": "git", 260 | "url": "https://github.com/phar-io/version.git", 261 | "reference": "4f7fd7836c6f332bb2933569e566a0d6c4cbed74" 262 | }, 263 | "dist": { 264 | "type": "zip", 265 | "url": "https://api.github.com/repos/phar-io/version/zipball/4f7fd7836c6f332bb2933569e566a0d6c4cbed74", 266 | "reference": "4f7fd7836c6f332bb2933569e566a0d6c4cbed74", 267 | "shasum": "" 268 | }, 269 | "require": { 270 | "php": "^7.2 || ^8.0" 271 | }, 272 | "type": "library", 273 | "autoload": { 274 | "classmap": [ 275 | "src/" 276 | ] 277 | }, 278 | "notification-url": "https://packagist.org/downloads/", 279 | "license": [ 280 | "BSD-3-Clause" 281 | ], 282 | "authors": [ 283 | { 284 | "name": "Arne Blankerts", 285 | "email": "arne@blankerts.de", 286 | "role": "Developer" 287 | }, 288 | { 289 | "name": "Sebastian Heuer", 290 | "email": "sebastian@phpeople.de", 291 | "role": "Developer" 292 | }, 293 | { 294 | "name": "Sebastian Bergmann", 295 | "email": "sebastian@phpunit.de", 296 | "role": "Developer" 297 | } 298 | ], 299 | "description": "Library for handling version information and constraints", 300 | "support": { 301 | "issues": "https://github.com/phar-io/version/issues", 302 | "source": "https://github.com/phar-io/version/tree/3.2.1" 303 | }, 304 | "time": "2022-02-21T01:04:05+00:00" 305 | }, 306 | { 307 | "name": "phpunit/php-code-coverage", 308 | "version": "9.2.17", 309 | "source": { 310 | "type": "git", 311 | "url": "https://github.com/sebastianbergmann/php-code-coverage.git", 312 | "reference": "aa94dc41e8661fe90c7316849907cba3007b10d8" 313 | }, 314 | "dist": { 315 | "type": "zip", 316 | "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/aa94dc41e8661fe90c7316849907cba3007b10d8", 317 | "reference": "aa94dc41e8661fe90c7316849907cba3007b10d8", 318 | "shasum": "" 319 | }, 320 | "require": { 321 | "ext-dom": "*", 322 | "ext-libxml": "*", 323 | "ext-xmlwriter": "*", 324 | "nikic/php-parser": "^4.14", 325 | "php": ">=7.3", 326 | "phpunit/php-file-iterator": "^3.0.3", 327 | "phpunit/php-text-template": "^2.0.2", 328 | "sebastian/code-unit-reverse-lookup": "^2.0.2", 329 | "sebastian/complexity": "^2.0", 330 | "sebastian/environment": "^5.1.2", 331 | "sebastian/lines-of-code": "^1.0.3", 332 | "sebastian/version": "^3.0.1", 333 | "theseer/tokenizer": "^1.2.0" 334 | }, 335 | "require-dev": { 336 | "phpunit/phpunit": "^9.3" 337 | }, 338 | "suggest": { 339 | "ext-pcov": "*", 340 | "ext-xdebug": "*" 341 | }, 342 | "type": "library", 343 | "extra": { 344 | "branch-alias": { 345 | "dev-master": "9.2-dev" 346 | } 347 | }, 348 | "autoload": { 349 | "classmap": [ 350 | "src/" 351 | ] 352 | }, 353 | "notification-url": "https://packagist.org/downloads/", 354 | "license": [ 355 | "BSD-3-Clause" 356 | ], 357 | "authors": [ 358 | { 359 | "name": "Sebastian Bergmann", 360 | "email": "sebastian@phpunit.de", 361 | "role": "lead" 362 | } 363 | ], 364 | "description": "Library that provides collection, processing, and rendering functionality for PHP code coverage information.", 365 | "homepage": "https://github.com/sebastianbergmann/php-code-coverage", 366 | "keywords": [ 367 | "coverage", 368 | "testing", 369 | "xunit" 370 | ], 371 | "support": { 372 | "issues": "https://github.com/sebastianbergmann/php-code-coverage/issues", 373 | "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/9.2.17" 374 | }, 375 | "funding": [ 376 | { 377 | "url": "https://github.com/sebastianbergmann", 378 | "type": "github" 379 | } 380 | ], 381 | "time": "2022-08-30T12:24:04+00:00" 382 | }, 383 | { 384 | "name": "phpunit/php-file-iterator", 385 | "version": "3.0.6", 386 | "source": { 387 | "type": "git", 388 | "url": "https://github.com/sebastianbergmann/php-file-iterator.git", 389 | "reference": "cf1c2e7c203ac650e352f4cc675a7021e7d1b3cf" 390 | }, 391 | "dist": { 392 | "type": "zip", 393 | "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/cf1c2e7c203ac650e352f4cc675a7021e7d1b3cf", 394 | "reference": "cf1c2e7c203ac650e352f4cc675a7021e7d1b3cf", 395 | "shasum": "" 396 | }, 397 | "require": { 398 | "php": ">=7.3" 399 | }, 400 | "require-dev": { 401 | "phpunit/phpunit": "^9.3" 402 | }, 403 | "type": "library", 404 | "extra": { 405 | "branch-alias": { 406 | "dev-master": "3.0-dev" 407 | } 408 | }, 409 | "autoload": { 410 | "classmap": [ 411 | "src/" 412 | ] 413 | }, 414 | "notification-url": "https://packagist.org/downloads/", 415 | "license": [ 416 | "BSD-3-Clause" 417 | ], 418 | "authors": [ 419 | { 420 | "name": "Sebastian Bergmann", 421 | "email": "sebastian@phpunit.de", 422 | "role": "lead" 423 | } 424 | ], 425 | "description": "FilterIterator implementation that filters files based on a list of suffixes.", 426 | "homepage": "https://github.com/sebastianbergmann/php-file-iterator/", 427 | "keywords": [ 428 | "filesystem", 429 | "iterator" 430 | ], 431 | "support": { 432 | "issues": "https://github.com/sebastianbergmann/php-file-iterator/issues", 433 | "source": "https://github.com/sebastianbergmann/php-file-iterator/tree/3.0.6" 434 | }, 435 | "funding": [ 436 | { 437 | "url": "https://github.com/sebastianbergmann", 438 | "type": "github" 439 | } 440 | ], 441 | "time": "2021-12-02T12:48:52+00:00" 442 | }, 443 | { 444 | "name": "phpunit/php-invoker", 445 | "version": "3.1.1", 446 | "source": { 447 | "type": "git", 448 | "url": "https://github.com/sebastianbergmann/php-invoker.git", 449 | "reference": "5a10147d0aaf65b58940a0b72f71c9ac0423cc67" 450 | }, 451 | "dist": { 452 | "type": "zip", 453 | "url": "https://api.github.com/repos/sebastianbergmann/php-invoker/zipball/5a10147d0aaf65b58940a0b72f71c9ac0423cc67", 454 | "reference": "5a10147d0aaf65b58940a0b72f71c9ac0423cc67", 455 | "shasum": "" 456 | }, 457 | "require": { 458 | "php": ">=7.3" 459 | }, 460 | "require-dev": { 461 | "ext-pcntl": "*", 462 | "phpunit/phpunit": "^9.3" 463 | }, 464 | "suggest": { 465 | "ext-pcntl": "*" 466 | }, 467 | "type": "library", 468 | "extra": { 469 | "branch-alias": { 470 | "dev-master": "3.1-dev" 471 | } 472 | }, 473 | "autoload": { 474 | "classmap": [ 475 | "src/" 476 | ] 477 | }, 478 | "notification-url": "https://packagist.org/downloads/", 479 | "license": [ 480 | "BSD-3-Clause" 481 | ], 482 | "authors": [ 483 | { 484 | "name": "Sebastian Bergmann", 485 | "email": "sebastian@phpunit.de", 486 | "role": "lead" 487 | } 488 | ], 489 | "description": "Invoke callables with a timeout", 490 | "homepage": "https://github.com/sebastianbergmann/php-invoker/", 491 | "keywords": [ 492 | "process" 493 | ], 494 | "support": { 495 | "issues": "https://github.com/sebastianbergmann/php-invoker/issues", 496 | "source": "https://github.com/sebastianbergmann/php-invoker/tree/3.1.1" 497 | }, 498 | "funding": [ 499 | { 500 | "url": "https://github.com/sebastianbergmann", 501 | "type": "github" 502 | } 503 | ], 504 | "time": "2020-09-28T05:58:55+00:00" 505 | }, 506 | { 507 | "name": "phpunit/php-text-template", 508 | "version": "2.0.4", 509 | "source": { 510 | "type": "git", 511 | "url": "https://github.com/sebastianbergmann/php-text-template.git", 512 | "reference": "5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28" 513 | }, 514 | "dist": { 515 | "type": "zip", 516 | "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28", 517 | "reference": "5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28", 518 | "shasum": "" 519 | }, 520 | "require": { 521 | "php": ">=7.3" 522 | }, 523 | "require-dev": { 524 | "phpunit/phpunit": "^9.3" 525 | }, 526 | "type": "library", 527 | "extra": { 528 | "branch-alias": { 529 | "dev-master": "2.0-dev" 530 | } 531 | }, 532 | "autoload": { 533 | "classmap": [ 534 | "src/" 535 | ] 536 | }, 537 | "notification-url": "https://packagist.org/downloads/", 538 | "license": [ 539 | "BSD-3-Clause" 540 | ], 541 | "authors": [ 542 | { 543 | "name": "Sebastian Bergmann", 544 | "email": "sebastian@phpunit.de", 545 | "role": "lead" 546 | } 547 | ], 548 | "description": "Simple template engine.", 549 | "homepage": "https://github.com/sebastianbergmann/php-text-template/", 550 | "keywords": [ 551 | "template" 552 | ], 553 | "support": { 554 | "issues": "https://github.com/sebastianbergmann/php-text-template/issues", 555 | "source": "https://github.com/sebastianbergmann/php-text-template/tree/2.0.4" 556 | }, 557 | "funding": [ 558 | { 559 | "url": "https://github.com/sebastianbergmann", 560 | "type": "github" 561 | } 562 | ], 563 | "time": "2020-10-26T05:33:50+00:00" 564 | }, 565 | { 566 | "name": "phpunit/php-timer", 567 | "version": "5.0.3", 568 | "source": { 569 | "type": "git", 570 | "url": "https://github.com/sebastianbergmann/php-timer.git", 571 | "reference": "5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2" 572 | }, 573 | "dist": { 574 | "type": "zip", 575 | "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2", 576 | "reference": "5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2", 577 | "shasum": "" 578 | }, 579 | "require": { 580 | "php": ">=7.3" 581 | }, 582 | "require-dev": { 583 | "phpunit/phpunit": "^9.3" 584 | }, 585 | "type": "library", 586 | "extra": { 587 | "branch-alias": { 588 | "dev-master": "5.0-dev" 589 | } 590 | }, 591 | "autoload": { 592 | "classmap": [ 593 | "src/" 594 | ] 595 | }, 596 | "notification-url": "https://packagist.org/downloads/", 597 | "license": [ 598 | "BSD-3-Clause" 599 | ], 600 | "authors": [ 601 | { 602 | "name": "Sebastian Bergmann", 603 | "email": "sebastian@phpunit.de", 604 | "role": "lead" 605 | } 606 | ], 607 | "description": "Utility class for timing", 608 | "homepage": "https://github.com/sebastianbergmann/php-timer/", 609 | "keywords": [ 610 | "timer" 611 | ], 612 | "support": { 613 | "issues": "https://github.com/sebastianbergmann/php-timer/issues", 614 | "source": "https://github.com/sebastianbergmann/php-timer/tree/5.0.3" 615 | }, 616 | "funding": [ 617 | { 618 | "url": "https://github.com/sebastianbergmann", 619 | "type": "github" 620 | } 621 | ], 622 | "time": "2020-10-26T13:16:10+00:00" 623 | }, 624 | { 625 | "name": "phpunit/phpunit", 626 | "version": "9.5.25", 627 | "source": { 628 | "type": "git", 629 | "url": "https://github.com/sebastianbergmann/phpunit.git", 630 | "reference": "3e6f90ca7e3d02025b1d147bd8d4a89fd4ca8a1d" 631 | }, 632 | "dist": { 633 | "type": "zip", 634 | "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/3e6f90ca7e3d02025b1d147bd8d4a89fd4ca8a1d", 635 | "reference": "3e6f90ca7e3d02025b1d147bd8d4a89fd4ca8a1d", 636 | "shasum": "" 637 | }, 638 | "require": { 639 | "doctrine/instantiator": "^1.3.1", 640 | "ext-dom": "*", 641 | "ext-json": "*", 642 | "ext-libxml": "*", 643 | "ext-mbstring": "*", 644 | "ext-xml": "*", 645 | "ext-xmlwriter": "*", 646 | "myclabs/deep-copy": "^1.10.1", 647 | "phar-io/manifest": "^2.0.3", 648 | "phar-io/version": "^3.0.2", 649 | "php": ">=7.3", 650 | "phpunit/php-code-coverage": "^9.2.13", 651 | "phpunit/php-file-iterator": "^3.0.5", 652 | "phpunit/php-invoker": "^3.1.1", 653 | "phpunit/php-text-template": "^2.0.3", 654 | "phpunit/php-timer": "^5.0.2", 655 | "sebastian/cli-parser": "^1.0.1", 656 | "sebastian/code-unit": "^1.0.6", 657 | "sebastian/comparator": "^4.0.8", 658 | "sebastian/diff": "^4.0.3", 659 | "sebastian/environment": "^5.1.3", 660 | "sebastian/exporter": "^4.0.5", 661 | "sebastian/global-state": "^5.0.1", 662 | "sebastian/object-enumerator": "^4.0.3", 663 | "sebastian/resource-operations": "^3.0.3", 664 | "sebastian/type": "^3.2", 665 | "sebastian/version": "^3.0.2" 666 | }, 667 | "suggest": { 668 | "ext-soap": "*", 669 | "ext-xdebug": "*" 670 | }, 671 | "bin": [ 672 | "phpunit" 673 | ], 674 | "type": "library", 675 | "extra": { 676 | "branch-alias": { 677 | "dev-master": "9.5-dev" 678 | } 679 | }, 680 | "autoload": { 681 | "files": [ 682 | "src/Framework/Assert/Functions.php" 683 | ], 684 | "classmap": [ 685 | "src/" 686 | ] 687 | }, 688 | "notification-url": "https://packagist.org/downloads/", 689 | "license": [ 690 | "BSD-3-Clause" 691 | ], 692 | "authors": [ 693 | { 694 | "name": "Sebastian Bergmann", 695 | "email": "sebastian@phpunit.de", 696 | "role": "lead" 697 | } 698 | ], 699 | "description": "The PHP Unit Testing framework.", 700 | "homepage": "https://phpunit.de/", 701 | "keywords": [ 702 | "phpunit", 703 | "testing", 704 | "xunit" 705 | ], 706 | "support": { 707 | "issues": "https://github.com/sebastianbergmann/phpunit/issues", 708 | "source": "https://github.com/sebastianbergmann/phpunit/tree/9.5.25" 709 | }, 710 | "funding": [ 711 | { 712 | "url": "https://phpunit.de/sponsors.html", 713 | "type": "custom" 714 | }, 715 | { 716 | "url": "https://github.com/sebastianbergmann", 717 | "type": "github" 718 | }, 719 | { 720 | "url": "https://tidelift.com/funding/github/packagist/phpunit/phpunit", 721 | "type": "tidelift" 722 | } 723 | ], 724 | "time": "2022-09-25T03:44:45+00:00" 725 | }, 726 | { 727 | "name": "sebastian/cli-parser", 728 | "version": "1.0.1", 729 | "source": { 730 | "type": "git", 731 | "url": "https://github.com/sebastianbergmann/cli-parser.git", 732 | "reference": "442e7c7e687e42adc03470c7b668bc4b2402c0b2" 733 | }, 734 | "dist": { 735 | "type": "zip", 736 | "url": "https://api.github.com/repos/sebastianbergmann/cli-parser/zipball/442e7c7e687e42adc03470c7b668bc4b2402c0b2", 737 | "reference": "442e7c7e687e42adc03470c7b668bc4b2402c0b2", 738 | "shasum": "" 739 | }, 740 | "require": { 741 | "php": ">=7.3" 742 | }, 743 | "require-dev": { 744 | "phpunit/phpunit": "^9.3" 745 | }, 746 | "type": "library", 747 | "extra": { 748 | "branch-alias": { 749 | "dev-master": "1.0-dev" 750 | } 751 | }, 752 | "autoload": { 753 | "classmap": [ 754 | "src/" 755 | ] 756 | }, 757 | "notification-url": "https://packagist.org/downloads/", 758 | "license": [ 759 | "BSD-3-Clause" 760 | ], 761 | "authors": [ 762 | { 763 | "name": "Sebastian Bergmann", 764 | "email": "sebastian@phpunit.de", 765 | "role": "lead" 766 | } 767 | ], 768 | "description": "Library for parsing CLI options", 769 | "homepage": "https://github.com/sebastianbergmann/cli-parser", 770 | "support": { 771 | "issues": "https://github.com/sebastianbergmann/cli-parser/issues", 772 | "source": "https://github.com/sebastianbergmann/cli-parser/tree/1.0.1" 773 | }, 774 | "funding": [ 775 | { 776 | "url": "https://github.com/sebastianbergmann", 777 | "type": "github" 778 | } 779 | ], 780 | "time": "2020-09-28T06:08:49+00:00" 781 | }, 782 | { 783 | "name": "sebastian/code-unit", 784 | "version": "1.0.8", 785 | "source": { 786 | "type": "git", 787 | "url": "https://github.com/sebastianbergmann/code-unit.git", 788 | "reference": "1fc9f64c0927627ef78ba436c9b17d967e68e120" 789 | }, 790 | "dist": { 791 | "type": "zip", 792 | "url": "https://api.github.com/repos/sebastianbergmann/code-unit/zipball/1fc9f64c0927627ef78ba436c9b17d967e68e120", 793 | "reference": "1fc9f64c0927627ef78ba436c9b17d967e68e120", 794 | "shasum": "" 795 | }, 796 | "require": { 797 | "php": ">=7.3" 798 | }, 799 | "require-dev": { 800 | "phpunit/phpunit": "^9.3" 801 | }, 802 | "type": "library", 803 | "extra": { 804 | "branch-alias": { 805 | "dev-master": "1.0-dev" 806 | } 807 | }, 808 | "autoload": { 809 | "classmap": [ 810 | "src/" 811 | ] 812 | }, 813 | "notification-url": "https://packagist.org/downloads/", 814 | "license": [ 815 | "BSD-3-Clause" 816 | ], 817 | "authors": [ 818 | { 819 | "name": "Sebastian Bergmann", 820 | "email": "sebastian@phpunit.de", 821 | "role": "lead" 822 | } 823 | ], 824 | "description": "Collection of value objects that represent the PHP code units", 825 | "homepage": "https://github.com/sebastianbergmann/code-unit", 826 | "support": { 827 | "issues": "https://github.com/sebastianbergmann/code-unit/issues", 828 | "source": "https://github.com/sebastianbergmann/code-unit/tree/1.0.8" 829 | }, 830 | "funding": [ 831 | { 832 | "url": "https://github.com/sebastianbergmann", 833 | "type": "github" 834 | } 835 | ], 836 | "time": "2020-10-26T13:08:54+00:00" 837 | }, 838 | { 839 | "name": "sebastian/code-unit-reverse-lookup", 840 | "version": "2.0.3", 841 | "source": { 842 | "type": "git", 843 | "url": "https://github.com/sebastianbergmann/code-unit-reverse-lookup.git", 844 | "reference": "ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5" 845 | }, 846 | "dist": { 847 | "type": "zip", 848 | "url": "https://api.github.com/repos/sebastianbergmann/code-unit-reverse-lookup/zipball/ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5", 849 | "reference": "ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5", 850 | "shasum": "" 851 | }, 852 | "require": { 853 | "php": ">=7.3" 854 | }, 855 | "require-dev": { 856 | "phpunit/phpunit": "^9.3" 857 | }, 858 | "type": "library", 859 | "extra": { 860 | "branch-alias": { 861 | "dev-master": "2.0-dev" 862 | } 863 | }, 864 | "autoload": { 865 | "classmap": [ 866 | "src/" 867 | ] 868 | }, 869 | "notification-url": "https://packagist.org/downloads/", 870 | "license": [ 871 | "BSD-3-Clause" 872 | ], 873 | "authors": [ 874 | { 875 | "name": "Sebastian Bergmann", 876 | "email": "sebastian@phpunit.de" 877 | } 878 | ], 879 | "description": "Looks up which function or method a line of code belongs to", 880 | "homepage": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/", 881 | "support": { 882 | "issues": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/issues", 883 | "source": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/tree/2.0.3" 884 | }, 885 | "funding": [ 886 | { 887 | "url": "https://github.com/sebastianbergmann", 888 | "type": "github" 889 | } 890 | ], 891 | "time": "2020-09-28T05:30:19+00:00" 892 | }, 893 | { 894 | "name": "sebastian/comparator", 895 | "version": "4.0.8", 896 | "source": { 897 | "type": "git", 898 | "url": "https://github.com/sebastianbergmann/comparator.git", 899 | "reference": "fa0f136dd2334583309d32b62544682ee972b51a" 900 | }, 901 | "dist": { 902 | "type": "zip", 903 | "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/fa0f136dd2334583309d32b62544682ee972b51a", 904 | "reference": "fa0f136dd2334583309d32b62544682ee972b51a", 905 | "shasum": "" 906 | }, 907 | "require": { 908 | "php": ">=7.3", 909 | "sebastian/diff": "^4.0", 910 | "sebastian/exporter": "^4.0" 911 | }, 912 | "require-dev": { 913 | "phpunit/phpunit": "^9.3" 914 | }, 915 | "type": "library", 916 | "extra": { 917 | "branch-alias": { 918 | "dev-master": "4.0-dev" 919 | } 920 | }, 921 | "autoload": { 922 | "classmap": [ 923 | "src/" 924 | ] 925 | }, 926 | "notification-url": "https://packagist.org/downloads/", 927 | "license": [ 928 | "BSD-3-Clause" 929 | ], 930 | "authors": [ 931 | { 932 | "name": "Sebastian Bergmann", 933 | "email": "sebastian@phpunit.de" 934 | }, 935 | { 936 | "name": "Jeff Welch", 937 | "email": "whatthejeff@gmail.com" 938 | }, 939 | { 940 | "name": "Volker Dusch", 941 | "email": "github@wallbash.com" 942 | }, 943 | { 944 | "name": "Bernhard Schussek", 945 | "email": "bschussek@2bepublished.at" 946 | } 947 | ], 948 | "description": "Provides the functionality to compare PHP values for equality", 949 | "homepage": "https://github.com/sebastianbergmann/comparator", 950 | "keywords": [ 951 | "comparator", 952 | "compare", 953 | "equality" 954 | ], 955 | "support": { 956 | "issues": "https://github.com/sebastianbergmann/comparator/issues", 957 | "source": "https://github.com/sebastianbergmann/comparator/tree/4.0.8" 958 | }, 959 | "funding": [ 960 | { 961 | "url": "https://github.com/sebastianbergmann", 962 | "type": "github" 963 | } 964 | ], 965 | "time": "2022-09-14T12:41:17+00:00" 966 | }, 967 | { 968 | "name": "sebastian/complexity", 969 | "version": "2.0.2", 970 | "source": { 971 | "type": "git", 972 | "url": "https://github.com/sebastianbergmann/complexity.git", 973 | "reference": "739b35e53379900cc9ac327b2147867b8b6efd88" 974 | }, 975 | "dist": { 976 | "type": "zip", 977 | "url": "https://api.github.com/repos/sebastianbergmann/complexity/zipball/739b35e53379900cc9ac327b2147867b8b6efd88", 978 | "reference": "739b35e53379900cc9ac327b2147867b8b6efd88", 979 | "shasum": "" 980 | }, 981 | "require": { 982 | "nikic/php-parser": "^4.7", 983 | "php": ">=7.3" 984 | }, 985 | "require-dev": { 986 | "phpunit/phpunit": "^9.3" 987 | }, 988 | "type": "library", 989 | "extra": { 990 | "branch-alias": { 991 | "dev-master": "2.0-dev" 992 | } 993 | }, 994 | "autoload": { 995 | "classmap": [ 996 | "src/" 997 | ] 998 | }, 999 | "notification-url": "https://packagist.org/downloads/", 1000 | "license": [ 1001 | "BSD-3-Clause" 1002 | ], 1003 | "authors": [ 1004 | { 1005 | "name": "Sebastian Bergmann", 1006 | "email": "sebastian@phpunit.de", 1007 | "role": "lead" 1008 | } 1009 | ], 1010 | "description": "Library for calculating the complexity of PHP code units", 1011 | "homepage": "https://github.com/sebastianbergmann/complexity", 1012 | "support": { 1013 | "issues": "https://github.com/sebastianbergmann/complexity/issues", 1014 | "source": "https://github.com/sebastianbergmann/complexity/tree/2.0.2" 1015 | }, 1016 | "funding": [ 1017 | { 1018 | "url": "https://github.com/sebastianbergmann", 1019 | "type": "github" 1020 | } 1021 | ], 1022 | "time": "2020-10-26T15:52:27+00:00" 1023 | }, 1024 | { 1025 | "name": "sebastian/diff", 1026 | "version": "4.0.4", 1027 | "source": { 1028 | "type": "git", 1029 | "url": "https://github.com/sebastianbergmann/diff.git", 1030 | "reference": "3461e3fccc7cfdfc2720be910d3bd73c69be590d" 1031 | }, 1032 | "dist": { 1033 | "type": "zip", 1034 | "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/3461e3fccc7cfdfc2720be910d3bd73c69be590d", 1035 | "reference": "3461e3fccc7cfdfc2720be910d3bd73c69be590d", 1036 | "shasum": "" 1037 | }, 1038 | "require": { 1039 | "php": ">=7.3" 1040 | }, 1041 | "require-dev": { 1042 | "phpunit/phpunit": "^9.3", 1043 | "symfony/process": "^4.2 || ^5" 1044 | }, 1045 | "type": "library", 1046 | "extra": { 1047 | "branch-alias": { 1048 | "dev-master": "4.0-dev" 1049 | } 1050 | }, 1051 | "autoload": { 1052 | "classmap": [ 1053 | "src/" 1054 | ] 1055 | }, 1056 | "notification-url": "https://packagist.org/downloads/", 1057 | "license": [ 1058 | "BSD-3-Clause" 1059 | ], 1060 | "authors": [ 1061 | { 1062 | "name": "Sebastian Bergmann", 1063 | "email": "sebastian@phpunit.de" 1064 | }, 1065 | { 1066 | "name": "Kore Nordmann", 1067 | "email": "mail@kore-nordmann.de" 1068 | } 1069 | ], 1070 | "description": "Diff implementation", 1071 | "homepage": "https://github.com/sebastianbergmann/diff", 1072 | "keywords": [ 1073 | "diff", 1074 | "udiff", 1075 | "unidiff", 1076 | "unified diff" 1077 | ], 1078 | "support": { 1079 | "issues": "https://github.com/sebastianbergmann/diff/issues", 1080 | "source": "https://github.com/sebastianbergmann/diff/tree/4.0.4" 1081 | }, 1082 | "funding": [ 1083 | { 1084 | "url": "https://github.com/sebastianbergmann", 1085 | "type": "github" 1086 | } 1087 | ], 1088 | "time": "2020-10-26T13:10:38+00:00" 1089 | }, 1090 | { 1091 | "name": "sebastian/environment", 1092 | "version": "5.1.4", 1093 | "source": { 1094 | "type": "git", 1095 | "url": "https://github.com/sebastianbergmann/environment.git", 1096 | "reference": "1b5dff7bb151a4db11d49d90e5408e4e938270f7" 1097 | }, 1098 | "dist": { 1099 | "type": "zip", 1100 | "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/1b5dff7bb151a4db11d49d90e5408e4e938270f7", 1101 | "reference": "1b5dff7bb151a4db11d49d90e5408e4e938270f7", 1102 | "shasum": "" 1103 | }, 1104 | "require": { 1105 | "php": ">=7.3" 1106 | }, 1107 | "require-dev": { 1108 | "phpunit/phpunit": "^9.3" 1109 | }, 1110 | "suggest": { 1111 | "ext-posix": "*" 1112 | }, 1113 | "type": "library", 1114 | "extra": { 1115 | "branch-alias": { 1116 | "dev-master": "5.1-dev" 1117 | } 1118 | }, 1119 | "autoload": { 1120 | "classmap": [ 1121 | "src/" 1122 | ] 1123 | }, 1124 | "notification-url": "https://packagist.org/downloads/", 1125 | "license": [ 1126 | "BSD-3-Clause" 1127 | ], 1128 | "authors": [ 1129 | { 1130 | "name": "Sebastian Bergmann", 1131 | "email": "sebastian@phpunit.de" 1132 | } 1133 | ], 1134 | "description": "Provides functionality to handle HHVM/PHP environments", 1135 | "homepage": "http://www.github.com/sebastianbergmann/environment", 1136 | "keywords": [ 1137 | "Xdebug", 1138 | "environment", 1139 | "hhvm" 1140 | ], 1141 | "support": { 1142 | "issues": "https://github.com/sebastianbergmann/environment/issues", 1143 | "source": "https://github.com/sebastianbergmann/environment/tree/5.1.4" 1144 | }, 1145 | "funding": [ 1146 | { 1147 | "url": "https://github.com/sebastianbergmann", 1148 | "type": "github" 1149 | } 1150 | ], 1151 | "time": "2022-04-03T09:37:03+00:00" 1152 | }, 1153 | { 1154 | "name": "sebastian/exporter", 1155 | "version": "4.0.5", 1156 | "source": { 1157 | "type": "git", 1158 | "url": "https://github.com/sebastianbergmann/exporter.git", 1159 | "reference": "ac230ed27f0f98f597c8a2b6eb7ac563af5e5b9d" 1160 | }, 1161 | "dist": { 1162 | "type": "zip", 1163 | "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/ac230ed27f0f98f597c8a2b6eb7ac563af5e5b9d", 1164 | "reference": "ac230ed27f0f98f597c8a2b6eb7ac563af5e5b9d", 1165 | "shasum": "" 1166 | }, 1167 | "require": { 1168 | "php": ">=7.3", 1169 | "sebastian/recursion-context": "^4.0" 1170 | }, 1171 | "require-dev": { 1172 | "ext-mbstring": "*", 1173 | "phpunit/phpunit": "^9.3" 1174 | }, 1175 | "type": "library", 1176 | "extra": { 1177 | "branch-alias": { 1178 | "dev-master": "4.0-dev" 1179 | } 1180 | }, 1181 | "autoload": { 1182 | "classmap": [ 1183 | "src/" 1184 | ] 1185 | }, 1186 | "notification-url": "https://packagist.org/downloads/", 1187 | "license": [ 1188 | "BSD-3-Clause" 1189 | ], 1190 | "authors": [ 1191 | { 1192 | "name": "Sebastian Bergmann", 1193 | "email": "sebastian@phpunit.de" 1194 | }, 1195 | { 1196 | "name": "Jeff Welch", 1197 | "email": "whatthejeff@gmail.com" 1198 | }, 1199 | { 1200 | "name": "Volker Dusch", 1201 | "email": "github@wallbash.com" 1202 | }, 1203 | { 1204 | "name": "Adam Harvey", 1205 | "email": "aharvey@php.net" 1206 | }, 1207 | { 1208 | "name": "Bernhard Schussek", 1209 | "email": "bschussek@gmail.com" 1210 | } 1211 | ], 1212 | "description": "Provides the functionality to export PHP variables for visualization", 1213 | "homepage": "https://www.github.com/sebastianbergmann/exporter", 1214 | "keywords": [ 1215 | "export", 1216 | "exporter" 1217 | ], 1218 | "support": { 1219 | "issues": "https://github.com/sebastianbergmann/exporter/issues", 1220 | "source": "https://github.com/sebastianbergmann/exporter/tree/4.0.5" 1221 | }, 1222 | "funding": [ 1223 | { 1224 | "url": "https://github.com/sebastianbergmann", 1225 | "type": "github" 1226 | } 1227 | ], 1228 | "time": "2022-09-14T06:03:37+00:00" 1229 | }, 1230 | { 1231 | "name": "sebastian/global-state", 1232 | "version": "5.0.5", 1233 | "source": { 1234 | "type": "git", 1235 | "url": "https://github.com/sebastianbergmann/global-state.git", 1236 | "reference": "0ca8db5a5fc9c8646244e629625ac486fa286bf2" 1237 | }, 1238 | "dist": { 1239 | "type": "zip", 1240 | "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/0ca8db5a5fc9c8646244e629625ac486fa286bf2", 1241 | "reference": "0ca8db5a5fc9c8646244e629625ac486fa286bf2", 1242 | "shasum": "" 1243 | }, 1244 | "require": { 1245 | "php": ">=7.3", 1246 | "sebastian/object-reflector": "^2.0", 1247 | "sebastian/recursion-context": "^4.0" 1248 | }, 1249 | "require-dev": { 1250 | "ext-dom": "*", 1251 | "phpunit/phpunit": "^9.3" 1252 | }, 1253 | "suggest": { 1254 | "ext-uopz": "*" 1255 | }, 1256 | "type": "library", 1257 | "extra": { 1258 | "branch-alias": { 1259 | "dev-master": "5.0-dev" 1260 | } 1261 | }, 1262 | "autoload": { 1263 | "classmap": [ 1264 | "src/" 1265 | ] 1266 | }, 1267 | "notification-url": "https://packagist.org/downloads/", 1268 | "license": [ 1269 | "BSD-3-Clause" 1270 | ], 1271 | "authors": [ 1272 | { 1273 | "name": "Sebastian Bergmann", 1274 | "email": "sebastian@phpunit.de" 1275 | } 1276 | ], 1277 | "description": "Snapshotting of global state", 1278 | "homepage": "http://www.github.com/sebastianbergmann/global-state", 1279 | "keywords": [ 1280 | "global state" 1281 | ], 1282 | "support": { 1283 | "issues": "https://github.com/sebastianbergmann/global-state/issues", 1284 | "source": "https://github.com/sebastianbergmann/global-state/tree/5.0.5" 1285 | }, 1286 | "funding": [ 1287 | { 1288 | "url": "https://github.com/sebastianbergmann", 1289 | "type": "github" 1290 | } 1291 | ], 1292 | "time": "2022-02-14T08:28:10+00:00" 1293 | }, 1294 | { 1295 | "name": "sebastian/lines-of-code", 1296 | "version": "1.0.3", 1297 | "source": { 1298 | "type": "git", 1299 | "url": "https://github.com/sebastianbergmann/lines-of-code.git", 1300 | "reference": "c1c2e997aa3146983ed888ad08b15470a2e22ecc" 1301 | }, 1302 | "dist": { 1303 | "type": "zip", 1304 | "url": "https://api.github.com/repos/sebastianbergmann/lines-of-code/zipball/c1c2e997aa3146983ed888ad08b15470a2e22ecc", 1305 | "reference": "c1c2e997aa3146983ed888ad08b15470a2e22ecc", 1306 | "shasum": "" 1307 | }, 1308 | "require": { 1309 | "nikic/php-parser": "^4.6", 1310 | "php": ">=7.3" 1311 | }, 1312 | "require-dev": { 1313 | "phpunit/phpunit": "^9.3" 1314 | }, 1315 | "type": "library", 1316 | "extra": { 1317 | "branch-alias": { 1318 | "dev-master": "1.0-dev" 1319 | } 1320 | }, 1321 | "autoload": { 1322 | "classmap": [ 1323 | "src/" 1324 | ] 1325 | }, 1326 | "notification-url": "https://packagist.org/downloads/", 1327 | "license": [ 1328 | "BSD-3-Clause" 1329 | ], 1330 | "authors": [ 1331 | { 1332 | "name": "Sebastian Bergmann", 1333 | "email": "sebastian@phpunit.de", 1334 | "role": "lead" 1335 | } 1336 | ], 1337 | "description": "Library for counting the lines of code in PHP source code", 1338 | "homepage": "https://github.com/sebastianbergmann/lines-of-code", 1339 | "support": { 1340 | "issues": "https://github.com/sebastianbergmann/lines-of-code/issues", 1341 | "source": "https://github.com/sebastianbergmann/lines-of-code/tree/1.0.3" 1342 | }, 1343 | "funding": [ 1344 | { 1345 | "url": "https://github.com/sebastianbergmann", 1346 | "type": "github" 1347 | } 1348 | ], 1349 | "time": "2020-11-28T06:42:11+00:00" 1350 | }, 1351 | { 1352 | "name": "sebastian/object-enumerator", 1353 | "version": "4.0.4", 1354 | "source": { 1355 | "type": "git", 1356 | "url": "https://github.com/sebastianbergmann/object-enumerator.git", 1357 | "reference": "5c9eeac41b290a3712d88851518825ad78f45c71" 1358 | }, 1359 | "dist": { 1360 | "type": "zip", 1361 | "url": "https://api.github.com/repos/sebastianbergmann/object-enumerator/zipball/5c9eeac41b290a3712d88851518825ad78f45c71", 1362 | "reference": "5c9eeac41b290a3712d88851518825ad78f45c71", 1363 | "shasum": "" 1364 | }, 1365 | "require": { 1366 | "php": ">=7.3", 1367 | "sebastian/object-reflector": "^2.0", 1368 | "sebastian/recursion-context": "^4.0" 1369 | }, 1370 | "require-dev": { 1371 | "phpunit/phpunit": "^9.3" 1372 | }, 1373 | "type": "library", 1374 | "extra": { 1375 | "branch-alias": { 1376 | "dev-master": "4.0-dev" 1377 | } 1378 | }, 1379 | "autoload": { 1380 | "classmap": [ 1381 | "src/" 1382 | ] 1383 | }, 1384 | "notification-url": "https://packagist.org/downloads/", 1385 | "license": [ 1386 | "BSD-3-Clause" 1387 | ], 1388 | "authors": [ 1389 | { 1390 | "name": "Sebastian Bergmann", 1391 | "email": "sebastian@phpunit.de" 1392 | } 1393 | ], 1394 | "description": "Traverses array structures and object graphs to enumerate all referenced objects", 1395 | "homepage": "https://github.com/sebastianbergmann/object-enumerator/", 1396 | "support": { 1397 | "issues": "https://github.com/sebastianbergmann/object-enumerator/issues", 1398 | "source": "https://github.com/sebastianbergmann/object-enumerator/tree/4.0.4" 1399 | }, 1400 | "funding": [ 1401 | { 1402 | "url": "https://github.com/sebastianbergmann", 1403 | "type": "github" 1404 | } 1405 | ], 1406 | "time": "2020-10-26T13:12:34+00:00" 1407 | }, 1408 | { 1409 | "name": "sebastian/object-reflector", 1410 | "version": "2.0.4", 1411 | "source": { 1412 | "type": "git", 1413 | "url": "https://github.com/sebastianbergmann/object-reflector.git", 1414 | "reference": "b4f479ebdbf63ac605d183ece17d8d7fe49c15c7" 1415 | }, 1416 | "dist": { 1417 | "type": "zip", 1418 | "url": "https://api.github.com/repos/sebastianbergmann/object-reflector/zipball/b4f479ebdbf63ac605d183ece17d8d7fe49c15c7", 1419 | "reference": "b4f479ebdbf63ac605d183ece17d8d7fe49c15c7", 1420 | "shasum": "" 1421 | }, 1422 | "require": { 1423 | "php": ">=7.3" 1424 | }, 1425 | "require-dev": { 1426 | "phpunit/phpunit": "^9.3" 1427 | }, 1428 | "type": "library", 1429 | "extra": { 1430 | "branch-alias": { 1431 | "dev-master": "2.0-dev" 1432 | } 1433 | }, 1434 | "autoload": { 1435 | "classmap": [ 1436 | "src/" 1437 | ] 1438 | }, 1439 | "notification-url": "https://packagist.org/downloads/", 1440 | "license": [ 1441 | "BSD-3-Clause" 1442 | ], 1443 | "authors": [ 1444 | { 1445 | "name": "Sebastian Bergmann", 1446 | "email": "sebastian@phpunit.de" 1447 | } 1448 | ], 1449 | "description": "Allows reflection of object attributes, including inherited and non-public ones", 1450 | "homepage": "https://github.com/sebastianbergmann/object-reflector/", 1451 | "support": { 1452 | "issues": "https://github.com/sebastianbergmann/object-reflector/issues", 1453 | "source": "https://github.com/sebastianbergmann/object-reflector/tree/2.0.4" 1454 | }, 1455 | "funding": [ 1456 | { 1457 | "url": "https://github.com/sebastianbergmann", 1458 | "type": "github" 1459 | } 1460 | ], 1461 | "time": "2020-10-26T13:14:26+00:00" 1462 | }, 1463 | { 1464 | "name": "sebastian/recursion-context", 1465 | "version": "4.0.4", 1466 | "source": { 1467 | "type": "git", 1468 | "url": "https://github.com/sebastianbergmann/recursion-context.git", 1469 | "reference": "cd9d8cf3c5804de4341c283ed787f099f5506172" 1470 | }, 1471 | "dist": { 1472 | "type": "zip", 1473 | "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/cd9d8cf3c5804de4341c283ed787f099f5506172", 1474 | "reference": "cd9d8cf3c5804de4341c283ed787f099f5506172", 1475 | "shasum": "" 1476 | }, 1477 | "require": { 1478 | "php": ">=7.3" 1479 | }, 1480 | "require-dev": { 1481 | "phpunit/phpunit": "^9.3" 1482 | }, 1483 | "type": "library", 1484 | "extra": { 1485 | "branch-alias": { 1486 | "dev-master": "4.0-dev" 1487 | } 1488 | }, 1489 | "autoload": { 1490 | "classmap": [ 1491 | "src/" 1492 | ] 1493 | }, 1494 | "notification-url": "https://packagist.org/downloads/", 1495 | "license": [ 1496 | "BSD-3-Clause" 1497 | ], 1498 | "authors": [ 1499 | { 1500 | "name": "Sebastian Bergmann", 1501 | "email": "sebastian@phpunit.de" 1502 | }, 1503 | { 1504 | "name": "Jeff Welch", 1505 | "email": "whatthejeff@gmail.com" 1506 | }, 1507 | { 1508 | "name": "Adam Harvey", 1509 | "email": "aharvey@php.net" 1510 | } 1511 | ], 1512 | "description": "Provides functionality to recursively process PHP variables", 1513 | "homepage": "http://www.github.com/sebastianbergmann/recursion-context", 1514 | "support": { 1515 | "issues": "https://github.com/sebastianbergmann/recursion-context/issues", 1516 | "source": "https://github.com/sebastianbergmann/recursion-context/tree/4.0.4" 1517 | }, 1518 | "funding": [ 1519 | { 1520 | "url": "https://github.com/sebastianbergmann", 1521 | "type": "github" 1522 | } 1523 | ], 1524 | "time": "2020-10-26T13:17:30+00:00" 1525 | }, 1526 | { 1527 | "name": "sebastian/resource-operations", 1528 | "version": "3.0.3", 1529 | "source": { 1530 | "type": "git", 1531 | "url": "https://github.com/sebastianbergmann/resource-operations.git", 1532 | "reference": "0f4443cb3a1d92ce809899753bc0d5d5a8dd19a8" 1533 | }, 1534 | "dist": { 1535 | "type": "zip", 1536 | "url": "https://api.github.com/repos/sebastianbergmann/resource-operations/zipball/0f4443cb3a1d92ce809899753bc0d5d5a8dd19a8", 1537 | "reference": "0f4443cb3a1d92ce809899753bc0d5d5a8dd19a8", 1538 | "shasum": "" 1539 | }, 1540 | "require": { 1541 | "php": ">=7.3" 1542 | }, 1543 | "require-dev": { 1544 | "phpunit/phpunit": "^9.0" 1545 | }, 1546 | "type": "library", 1547 | "extra": { 1548 | "branch-alias": { 1549 | "dev-master": "3.0-dev" 1550 | } 1551 | }, 1552 | "autoload": { 1553 | "classmap": [ 1554 | "src/" 1555 | ] 1556 | }, 1557 | "notification-url": "https://packagist.org/downloads/", 1558 | "license": [ 1559 | "BSD-3-Clause" 1560 | ], 1561 | "authors": [ 1562 | { 1563 | "name": "Sebastian Bergmann", 1564 | "email": "sebastian@phpunit.de" 1565 | } 1566 | ], 1567 | "description": "Provides a list of PHP built-in functions that operate on resources", 1568 | "homepage": "https://www.github.com/sebastianbergmann/resource-operations", 1569 | "support": { 1570 | "issues": "https://github.com/sebastianbergmann/resource-operations/issues", 1571 | "source": "https://github.com/sebastianbergmann/resource-operations/tree/3.0.3" 1572 | }, 1573 | "funding": [ 1574 | { 1575 | "url": "https://github.com/sebastianbergmann", 1576 | "type": "github" 1577 | } 1578 | ], 1579 | "time": "2020-09-28T06:45:17+00:00" 1580 | }, 1581 | { 1582 | "name": "sebastian/type", 1583 | "version": "3.2.0", 1584 | "source": { 1585 | "type": "git", 1586 | "url": "https://github.com/sebastianbergmann/type.git", 1587 | "reference": "fb3fe09c5f0bae6bc27ef3ce933a1e0ed9464b6e" 1588 | }, 1589 | "dist": { 1590 | "type": "zip", 1591 | "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/fb3fe09c5f0bae6bc27ef3ce933a1e0ed9464b6e", 1592 | "reference": "fb3fe09c5f0bae6bc27ef3ce933a1e0ed9464b6e", 1593 | "shasum": "" 1594 | }, 1595 | "require": { 1596 | "php": ">=7.3" 1597 | }, 1598 | "require-dev": { 1599 | "phpunit/phpunit": "^9.5" 1600 | }, 1601 | "type": "library", 1602 | "extra": { 1603 | "branch-alias": { 1604 | "dev-master": "3.2-dev" 1605 | } 1606 | }, 1607 | "autoload": { 1608 | "classmap": [ 1609 | "src/" 1610 | ] 1611 | }, 1612 | "notification-url": "https://packagist.org/downloads/", 1613 | "license": [ 1614 | "BSD-3-Clause" 1615 | ], 1616 | "authors": [ 1617 | { 1618 | "name": "Sebastian Bergmann", 1619 | "email": "sebastian@phpunit.de", 1620 | "role": "lead" 1621 | } 1622 | ], 1623 | "description": "Collection of value objects that represent the types of the PHP type system", 1624 | "homepage": "https://github.com/sebastianbergmann/type", 1625 | "support": { 1626 | "issues": "https://github.com/sebastianbergmann/type/issues", 1627 | "source": "https://github.com/sebastianbergmann/type/tree/3.2.0" 1628 | }, 1629 | "funding": [ 1630 | { 1631 | "url": "https://github.com/sebastianbergmann", 1632 | "type": "github" 1633 | } 1634 | ], 1635 | "time": "2022-09-12T14:47:03+00:00" 1636 | }, 1637 | { 1638 | "name": "sebastian/version", 1639 | "version": "3.0.2", 1640 | "source": { 1641 | "type": "git", 1642 | "url": "https://github.com/sebastianbergmann/version.git", 1643 | "reference": "c6c1022351a901512170118436c764e473f6de8c" 1644 | }, 1645 | "dist": { 1646 | "type": "zip", 1647 | "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/c6c1022351a901512170118436c764e473f6de8c", 1648 | "reference": "c6c1022351a901512170118436c764e473f6de8c", 1649 | "shasum": "" 1650 | }, 1651 | "require": { 1652 | "php": ">=7.3" 1653 | }, 1654 | "type": "library", 1655 | "extra": { 1656 | "branch-alias": { 1657 | "dev-master": "3.0-dev" 1658 | } 1659 | }, 1660 | "autoload": { 1661 | "classmap": [ 1662 | "src/" 1663 | ] 1664 | }, 1665 | "notification-url": "https://packagist.org/downloads/", 1666 | "license": [ 1667 | "BSD-3-Clause" 1668 | ], 1669 | "authors": [ 1670 | { 1671 | "name": "Sebastian Bergmann", 1672 | "email": "sebastian@phpunit.de", 1673 | "role": "lead" 1674 | } 1675 | ], 1676 | "description": "Library that helps with managing the version number of Git-hosted PHP projects", 1677 | "homepage": "https://github.com/sebastianbergmann/version", 1678 | "support": { 1679 | "issues": "https://github.com/sebastianbergmann/version/issues", 1680 | "source": "https://github.com/sebastianbergmann/version/tree/3.0.2" 1681 | }, 1682 | "funding": [ 1683 | { 1684 | "url": "https://github.com/sebastianbergmann", 1685 | "type": "github" 1686 | } 1687 | ], 1688 | "time": "2020-09-28T06:39:44+00:00" 1689 | }, 1690 | { 1691 | "name": "theseer/tokenizer", 1692 | "version": "1.2.1", 1693 | "source": { 1694 | "type": "git", 1695 | "url": "https://github.com/theseer/tokenizer.git", 1696 | "reference": "34a41e998c2183e22995f158c581e7b5e755ab9e" 1697 | }, 1698 | "dist": { 1699 | "type": "zip", 1700 | "url": "https://api.github.com/repos/theseer/tokenizer/zipball/34a41e998c2183e22995f158c581e7b5e755ab9e", 1701 | "reference": "34a41e998c2183e22995f158c581e7b5e755ab9e", 1702 | "shasum": "" 1703 | }, 1704 | "require": { 1705 | "ext-dom": "*", 1706 | "ext-tokenizer": "*", 1707 | "ext-xmlwriter": "*", 1708 | "php": "^7.2 || ^8.0" 1709 | }, 1710 | "type": "library", 1711 | "autoload": { 1712 | "classmap": [ 1713 | "src/" 1714 | ] 1715 | }, 1716 | "notification-url": "https://packagist.org/downloads/", 1717 | "license": [ 1718 | "BSD-3-Clause" 1719 | ], 1720 | "authors": [ 1721 | { 1722 | "name": "Arne Blankerts", 1723 | "email": "arne@blankerts.de", 1724 | "role": "Developer" 1725 | } 1726 | ], 1727 | "description": "A small library for converting tokenized PHP source code into XML and potentially other formats", 1728 | "support": { 1729 | "issues": "https://github.com/theseer/tokenizer/issues", 1730 | "source": "https://github.com/theseer/tokenizer/tree/1.2.1" 1731 | }, 1732 | "funding": [ 1733 | { 1734 | "url": "https://github.com/theseer", 1735 | "type": "github" 1736 | } 1737 | ], 1738 | "time": "2021-07-28T10:34:58+00:00" 1739 | } 1740 | ], 1741 | "aliases": [], 1742 | "minimum-stability": "stable", 1743 | "stability-flags": [], 1744 | "prefer-stable": false, 1745 | "prefer-lowest": false, 1746 | "platform": { 1747 | "php": ">=8.0", 1748 | "ext-sockets": "*" 1749 | }, 1750 | "platform-dev": [], 1751 | "plugin-api-version": "2.3.0" 1752 | } 1753 | -------------------------------------------------------------------------------- /docker-compose.yml: -------------------------------------------------------------------------------- 1 | --- 2 | version: '3.7' 3 | 4 | services: 5 | freshclam: 6 | image: appwrite/clamav:2.0.0 7 | restart: unless-stopped 8 | environment: 9 | MODE: freshclam 10 | volumes: 11 | - conf:/etc/clamav 12 | - data:/var/lib/clamav 13 | 14 | clamav: 15 | depends_on: 16 | - freshclam 17 | image: appwrite/clamav:2.0.0 18 | restart: unless-stopped 19 | environment: 20 | MODE: clamd 21 | volumes: 22 | - conf:/etc/clamav 23 | - data:/var/lib/clamav 24 | ports: 25 | - "3310:3310" 26 | 27 | volumes: 28 | conf: 29 | data: 30 | -------------------------------------------------------------------------------- /phpunit.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | ./src/ 6 | 7 | 8 | 9 | 10 | ./tests/ 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /src/ClamAV/ClamAV.php: -------------------------------------------------------------------------------- 1 | 10 | */ 11 | 12 | namespace Appwrite\ClamAV; 13 | 14 | abstract class ClamAV 15 | { 16 | /** 17 | * @var int 18 | */ 19 | public const CLAMAV_MAX = 20000; 20 | 21 | /** 22 | * @return resource 23 | */ 24 | abstract protected function getSocket(); 25 | 26 | /** 27 | * Send a given command to ClamAV. 28 | * 29 | * @param string $command 30 | * @return string|null 31 | */ 32 | private function sendCommand(string $command): ?string 33 | { 34 | $return = null; 35 | 36 | $socket = $this->getSocket(); 37 | 38 | \socket_send($socket, $command, \strlen($command), 0); 39 | \socket_recv($socket, $return, self::CLAMAV_MAX, 0); 40 | \socket_close($socket); 41 | 42 | return \trim($return); 43 | } 44 | 45 | /** 46 | * Check if ClamAV is up and responsive. 47 | * 48 | * @return bool 49 | */ 50 | public function ping(): bool 51 | { 52 | $return = $this->sendCommand('PING'); 53 | 54 | return \trim($return) === 'PONG'; 55 | } 56 | 57 | /** 58 | * Check ClamAV Version. 59 | * 60 | * @return string 61 | */ 62 | public function version(): string 63 | { 64 | return \trim($this->sendCommand('VERSION')); 65 | } 66 | 67 | /** 68 | * Reload ClamAV virus databases. 69 | * 70 | * @return string|null 71 | */ 72 | public function reload(): ?string 73 | { 74 | return $this->sendCommand('RELOAD'); 75 | } 76 | 77 | /** 78 | * Shutdown ClamAV and preform a clean exit. 79 | * 80 | * @return string|null 81 | */ 82 | public function shutdown(): ?string 83 | { 84 | return $this->sendCommand('SHUTDOWN'); 85 | } 86 | 87 | /** 88 | * Scan a file or a directory (recursively) with archive support 89 | * enabled (if not disabled in clamd.conf). A full path is required. 90 | * 91 | * Returns whether the given file/directory is clean (true), or not (false). 92 | * 93 | * @param string $file 94 | * @return bool 95 | */ 96 | public function fileScanInStream(string $file): bool 97 | { 98 | $socket = $this->getSocket(); 99 | 100 | $handle = \fopen($file, 'rb'); 101 | $chunkSize = \filesize($file) < 8192 ? \filesize($file) : 8192; 102 | $command = "zINSTREAM\0"; 103 | 104 | \socket_send($socket, $command, \strlen($command), 0); 105 | 106 | while (!\feof($handle)) { 107 | $data = \fread($handle, $chunkSize); 108 | $packet = \pack(\sprintf("Na%d", $chunkSize), $chunkSize, $data); 109 | \socket_send($socket, $packet, $chunkSize + 4, 0); 110 | } 111 | 112 | \socket_send($socket, \pack("Nx", 0), 5, 0); 113 | \socket_recv($socket, $out, 20000, 0); 114 | \socket_close($socket); 115 | 116 | $out = \explode(':', $out); 117 | $stats = \end($out); 118 | 119 | return \trim($stats) === 'OK'; 120 | } 121 | 122 | /** 123 | * Scan a file or a directory (recursively) with archive support 124 | * enabled (if not disabled in clamd.conf). A full path is required. 125 | * 126 | * Returns whether the given file/directory is clean (true), or not (false). 127 | * 128 | * @param string $file 129 | * @return bool 130 | */ 131 | public function fileScan(string $file): bool 132 | { 133 | $out = $this->sendCommand('SCAN ' . $file); 134 | 135 | $out = \explode(':', $out); 136 | $stats = \end($out); 137 | 138 | return \trim($stats) === 'OK'; 139 | } 140 | 141 | /** 142 | * Scan file or directory (recursively) with archive support 143 | * enabled, and don't stop the scanning when a virus is found. 144 | * 145 | * @param string $file 146 | * @return array 147 | */ 148 | public function continueScan(string $file): array 149 | { 150 | $return = []; 151 | 152 | foreach (\explode("\n", \trim($this->sendCommand('CONTSCAN ' . $file))) as $results) { 153 | [$file, $stats] = \explode(':', $results); 154 | $return[] = ['file' => $file, 'stats' => \trim($stats)]; 155 | } 156 | 157 | return $return; 158 | } 159 | } 160 | -------------------------------------------------------------------------------- /src/ClamAV/Network.php: -------------------------------------------------------------------------------- 1 | 10 | */ 11 | 12 | namespace Appwrite\ClamAV; 13 | 14 | use RuntimeException; 15 | use Socket; 16 | use const AF_INET; 17 | use const SOCK_STREAM; 18 | 19 | class Network extends ClamAV 20 | { 21 | /** 22 | * @var string 23 | */ 24 | private const CLAMAV_HOST = '127.0.0.1'; 25 | 26 | /** 27 | * @var int 28 | */ 29 | private const CLAMAV_PORT = 3310; 30 | 31 | /** 32 | * @var string 33 | */ 34 | private string $host; 35 | 36 | /** 37 | * @var int 38 | */ 39 | private int $port; 40 | 41 | /** 42 | * Network constructor 43 | * 44 | * You need to pass the host address and the port the server. 45 | * 46 | * @param string $host 47 | * @param int $port 48 | */ 49 | public function __construct(string $host = self::CLAMAV_HOST, int $port = self::CLAMAV_PORT) 50 | { 51 | $this->host = $host; 52 | $this->port = $port; 53 | } 54 | 55 | /** 56 | * Returns a remote socket. 57 | * 58 | * @return Socket 59 | */ 60 | protected function getSocket(): Socket 61 | { 62 | $socket = @\socket_create(AF_INET, SOCK_STREAM, 0); 63 | $status = @\socket_connect($socket, $this->host, $this->port); 64 | 65 | if (!$status) { 66 | throw new RuntimeException('Unable to connect to ClamAV server'); 67 | } 68 | 69 | return $socket; 70 | } 71 | } 72 | -------------------------------------------------------------------------------- /src/ClamAV/Pipe.php: -------------------------------------------------------------------------------- 1 | 10 | */ 11 | 12 | namespace Appwrite\ClamAV; 13 | 14 | use Socket; 15 | use const AF_UNIX; 16 | use const SOCK_STREAM; 17 | 18 | class Pipe extends ClamAV 19 | { 20 | /** 21 | * @var string 22 | */ 23 | private const CLAMAV_HOST = '/run/clamav/clamd.sock'; 24 | 25 | /** 26 | * @var string 27 | */ 28 | private string $pip; 29 | 30 | /** 31 | * Pipe constructor. 32 | * 33 | * This class can be used to connect to local socket. 34 | * You need to pass the path to the socket pipe. 35 | * 36 | * @param string $pip 37 | */ 38 | public function __construct(string $pip = self::CLAMAV_HOST) 39 | { 40 | $this->pip = $pip; 41 | } 42 | 43 | /** 44 | * Returns a local socket. 45 | * 46 | * @return Socket 47 | */ 48 | protected function getSocket(): Socket 49 | { 50 | $socket = \socket_create(AF_UNIX, SOCK_STREAM, 0); 51 | \socket_connect($socket, $this->pip); 52 | 53 | return $socket; 54 | } 55 | } 56 | -------------------------------------------------------------------------------- /tests/ClamAV/ClamAVTest.php: -------------------------------------------------------------------------------- 1 | 10 | */ 11 | 12 | namespace Appwrite\ClamAV\Tests; 13 | 14 | use Appwrite\ClamAV\Network; 15 | use Appwrite\ClamAV\Pipe; 16 | use PHPUnit\Framework\TestCase; 17 | 18 | class ClamAVTest extends TestCase 19 | { 20 | /** 21 | * @var Network|null 22 | */ 23 | protected ?Network $network; 24 | 25 | /** 26 | * @var Pipe|null 27 | */ 28 | protected ?Pipe $pipe; 29 | 30 | protected function setUp(): void 31 | { 32 | $this->network = new Network('localhost', 3310); 33 | $this->pipe = new Pipe(); 34 | } 35 | 36 | protected function tearDown(): void 37 | { 38 | $this->network = null; 39 | $this->pipe = null; 40 | } 41 | 42 | public function testVersion(): void 43 | { 44 | self::assertStringStartsWith('ClamAV ', $this->network->version()); 45 | } 46 | 47 | public function testPing(): void 48 | { 49 | self::assertTrue($this->network->ping()); 50 | } 51 | 52 | public function testFileScanInStream(): void 53 | { 54 | self::assertTrue($this->network->fileScanInStream(__FILE__)); 55 | } 56 | 57 | public function testReload(): void 58 | { 59 | self::assertStringStartsWith('RELOADING', $this->network->reload()); 60 | } 61 | } 62 | --------------------------------------------------------------------------------