Commit Graph

26 Commits

Author SHA1 Message Date
frytimo 08001488f4
Allow namespace in auto loader (#7307)
* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove class_exists wrapper for class definitions

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove include statement of class file

* remove closing tag

* remove invalid method params

* remove closing tag

* remove closing tag

* Update auto_loader to load each class file in the project
Update the auto_loader class to use an include statement on each file in the project to load the class within the file. This will allow mismatched names within the file to be loaded and mapped according to the declaration instead of the filename. The class is then checked against the parsed classes from the PHP engine so that namespaces are available and mapped to the file they were declared in. An update was also made to the search algorithm used to find a file that was not already loaded by collapsing the array to have only valid matches to increase performance on a cache miss. Logging within the auto_loader has been moved to a function.
Multiple files were modified to allow the include statement. When the class has the `if(class_exists())` statement, the auto_loader is called to check for the class. This caused an infinite loop scenario so all wrappers have been removed. The auto_loader will now break the loop by directly modifying the internal classes array instead of trying to restart with the 'reload_classes' method.

- APCu is used to cache classes so any loading of the classes is done only once. To clear the APCu cache, restart php-fpm or call the auto_loader::clear_cache() function.
- Cache file is used when APCu is not available. To clear the cache remove it from the tmp folder or call the auto_loader::clear_cache() function.
- All classes must no longer have a class_exists wrapper to benefit from the performance boost.
- Classes should not be directly included when the auto_loader is used.

* remove include statement of class file

* Update destinations.php
2025-03-12 13:55:47 -06:00
FusionPBX cd8d5302ac
Fix temporary permissions 2024-11-29 13:57:01 -07:00
FusionPBX 71334c9655
Removed session server temp directory
This session variables is no longer used
2024-06-26 07:48:41 -06:00
FusionPBX efce99375b
Template engine use sys_get_temp_dir
Used to get the operating system temp directory.
2024-06-26 07:28:37 -06:00
FusionPBX 02db089d8f
New setting background_video 2024-06-18 09:32:19 -06:00
markjcrane 4951647225 Add user_type is null for better backwarads compatibility 2023-07-14 12:38:45 -06:00
markjcrane 52c0b3955f Disable authentication if the user type is set to virtual. 2023-07-13 18:30:29 -06:00
FusionPBX e9839e3b30
Refine the authentication ldap class 2023-05-12 19:34:05 -06:00
FusionPBX 663bcf929e
Add project_path and login_destination_url 2023-05-10 23:10:44 -06:00
FusionPBX d9cc3314d3
Add favicon (#6671)
* Add favicon

* Update totp_secret.htm

* Update totp.htm

* Update login.htm

* Update email.htm

* Update totp.php

* Update ldap.php

* Update email.php

* Update database.php
2023-05-06 18:31:48 -06:00
frytimo fef8165be2
Frytimo pr patches for php8.1 (#6630)
* Passing null to parameter #2 ($string) of type string is deprecated

* Passing null to parameter #1 ($string) of type string is deprecated

* php 8.1 fixes

* php 8.1 fixes - replace strlen($var) > 0 with !empty($var)

* php 8.1 fixes - replace ${var} with {$var}

* php 8.1 fixes - replace ${var} with {$var}

* php 8.1 fixes - replace ${var} with {$var}

* php 8.1 fixes - replace ${var} with {$var}

* php 8.1 fixes - strlower with null

* php 8.1 fixes - strreplace with null

* php 8.1 fixes - passing null to base64_decode

* php 8.1 fixes - check for false and check for null on $this->dir

* php 8.1 fixes - remove assignment of $db variable to modules object

* php 8.1 fixes - avoid sending null to substr

* php 8.1 fixes - change ${var} to {$var}

* php 8.1 fixes - check for null before preg_replace

* php 8.1 fixes - remove setting db variable on domains object

* php 8.1 fixes - set empty string if $row['domain_setting_subcategory'] is null

* php 8.1 fixes - set empty string if $_REQUEST['show'] is not available

* php 8.1 fixes

* php 8.1 fixes - correct $_POST checking syntax

* php 8.1 fixes - correct $_POST variables

* php 8.1 fixes

* Use brackets consistently

* Update user_setting_edit.php

* Change to not empty

* Update device.php

* Update text.php

---------

Co-authored-by: Tim Fry <tim@voipstratus.com>
Co-authored-by: FusionPBX <markjcrane@gmail.com>
2023-05-05 10:46:37 -06:00
FusionPBX a9dc2ec479
Add login form to ldap 2023-04-18 09:36:09 -06:00
markjcrane 00801b5b04 Add mutli-factor authentication. 2023-04-16 01:10:39 -06:00
Nate 836fb87136 Misc Classes: Database class integration. 2019-09-02 15:57:18 -06:00
FusionPBX bce5d6b043 Update ldap.php 2019-08-15 01:55:23 -06:00
FusionPBX 89ce56e3ac Update ldap.php 2019-07-29 10:33:27 -06:00
Baji Zsolt f4618b7bfa Ldap connection to non standard port
port not used in ldap_connect
2019-05-29 17:24:48 +02:00
FusionPBX 3d076b169f Update ldap.php 2019-02-09 08:06:07 -07:00
FusionPBX 28f960a9f4 Update ldap.php 2017-04-20 10:28:53 -06:00
FusionPBX 381b420ac1 Update ldap.php 2017-04-03 12:04:16 -06:00
FusionPBX 5c5446b953 Update ldap.php
If the LDAP password is not provided then set authorized to false.
2016-11-02 00:16:30 -06:00
FusionPBX c212bba3b8 Update ldap.php 2016-10-31 11:01:52 -06:00
FusionPBX d27824cbb7 Update ldap.php 2016-09-11 09:09:54 -06:00
FusionPBX c1db75ab45 Fix a spelling mistake in ldap.php. 2016-09-11 09:08:33 -06:00
FusionPBX 1082578788 Update ldap.php 2016-09-10 22:28:35 -06:00
FusionPBX c3cd81f0f9 Create ldap.php
Add a the authentication ldap plugin.
2016-09-10 18:02:37 -06:00