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
Alex f0bc1cfe33
Update contacts path (#7192)
* Update contacts path

* Update menu.php

* Update contact_edit.php

* Update contact_relation_edit.php

* Update config.php

* Update authentication.php

* Update database.php

* Update totp.php

* Update email.php
2024-12-06 11:55:41 -07:00
FusionPBX cd8d5302ac
Fix temporary permissions 2024-11-29 13:57:01 -07:00
fusionate ae15319487
Body Header User Image and Menu, Domain Selector, Contact Attachment improvements. 2024-09-28 16:37:36 -06:00
FusionPBX 54565ede41
Fix a bug where logo was overridden 2024-09-05 10:28:53 -06: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 1f62c73b2d
Use the email_send_mode 2023-07-11 19:22:43 -06:00
volga629-1 21be0125b5
Auth direct email or email queue (#6617)
* Auth direct email or email_queue

Authentication email plugin improvement 

* Update email.php
2023-07-11 19:14:20 -06:00
fusionate d24acf66bf
Authentication: Updates to improve order compatibility. 2023-06-27 02:32:11 +00:00
fusionate 2e2bd53170
Authentication: Additional improvements to order execution and invalid creds. 2023-06-25 01:11:49 +00:00
fusionate b23a18fdf1
Authentication: Minor improvements in bad username handling, effort to integrate messages. 2023-06-24 22:40:44 +00:00
fusionate a7ecdf72f8
Authentication: Remove cancel link from username template (form is always displayed first, if needed). 2023-06-24 21:34:42 +00:00
fusionate aa7def54a6
Authentication - Fix MFA when all methods are enabled. 2023-06-24 21:18:39 +00:00
fusionate 6bcc5aff5e
Authentication: Added some polish, Cancel links, PHP 8.1 updates. 2023-06-23 00:14:07 +00:00
FusionPBX cd27922ce6
Refine the authentication email class 2023-05-12 19:33:14 -06:00
FusionPBX cc77a060e1
Add project_path and login_destination_url 2023-05-10 23:09:43 -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
FusionPBX 3aa5024cb2
Allow login with email authentication 2023-05-06 14:44:30 -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 fd20067433
Remove unused login_destination_url 2023-04-18 09:41:25 -06:00
FusionPBX 6bdab612b5
Use the session username when it is set 2023-04-17 11:22:27 -06:00
markjcrane 00801b5b04 Add mutli-factor authentication. 2023-04-16 01:10:39 -06:00