Common
1 year ago
Crypt
1 year ago
Exception
1 year ago
File
1 year ago
Math
1 year ago
Net
1 year ago
System
1 year ago
.htaccess
1 year ago
autoload.php
1 year ago
bootstrap.php
1 year ago
index.html
1 year ago
openssl.cnf
1 year ago
web.config
1 year ago
bootstrap.php
25 lines
| 1 | <?php |
| 2 | |
| 3 | declare(strict_types=1); |
| 4 | |
| 5 | /** |
| 6 | * Bootstrapping File for phpseclib |
| 7 | * |
| 8 | * composer isn't a requirement for phpseclib 2.0 but this file isn't really required |
| 9 | * either. it's a bonus for those using composer but if you're not phpseclib will |
| 10 | * still work |
| 11 | * |
| 12 | * @license http://www.opensource.org/licenses/mit-license.html MIT License |
| 13 | */ |
| 14 | |
| 15 | if (extension_loaded('mbstring')) { |
| 16 | // 2 - MB_OVERLOAD_STRING |
| 17 | // mbstring.func_overload is deprecated in php 7.2 and removed in php 8.0. |
| 18 | if (version_compare(PHP_VERSION, '8.0.0') < 0 && ini_get('mbstring.func_overload') & 2) { |
| 19 | throw new UnexpectedValueException( |
| 20 | 'Overloading of string functions using mbstring.func_overload ' . |
| 21 | 'is not supported by phpseclib.' |
| 22 | ); |
| 23 | } |
| 24 | } |
| 25 |