diff --git a/www/agc/vicidial.php b/www/agc/vicidial.php index ef466cae..88191d7c 100644 --- a/www/agc/vicidial.php +++ b/www/agc/vicidial.php @@ -1,7 +1,7 @@ LICENSE: AGPLv2 +# Copyright (C) 2026 Matt Florell LICENSE: AGPLv2 # # Other scripts that this application depends on: # - vdc_db_query.php: Updates information in the database @@ -753,10 +753,11 @@ # 251002-1353 - Added call_count_limit_restrict campaign option # 251020-0849 - Added code for recording_dtmf_muting, fix for Stereo Call Recording # 251124-0936 - Added lead status display for callbacks list +# 260106-1418 - Fixes for PHP8 # -$version = '2.14-719c'; -$build = '251124-0936'; +$version = '2.14-720c'; +$build = '260106-1418'; $php_script = 'vicidial.php'; $mel=1; # Mysql Error Log enabled = 1 $mysql_log_count=108; @@ -861,6 +862,8 @@ $JS_date = $StarTtimE."000"; # milliseconds since epoch or "16,3,31,8,56,1,0" $webphone_width = 460; $webphone_height = 500; $VUselected_language = ''; +$session_name=''; +$server_ip=''; $random = (rand(1000000, 9999999) + 10000000); @@ -1840,7 +1843,7 @@ else { $subhead_font = "style=\"font-family:HELVETICA;font-size:14;color:BLACK;font-weight:bold;\""; - echo "\"Two-Factor-Authentication\" "._QXZ("Two-Factor-Authentication"),"
\n"; + echo "\"Two-Factor-Authentication\" "._QXZ("Two-Factor-Authentication")."
\n"; if ( ($SStwo_factor_auth_hours < 1) or ($SStwo_factor_container == '') or ($SStwo_factor_container == '---DISABLED---') ) { @@ -1862,10 +1865,16 @@ else # first character and last 6 characters $temp_emailARY = explode('@',$OBSCUREemail); $field_temp_val = $temp_emailARY[0]; - $OBSCUREemail = substr($field_temp_val,0,2) . str_repeat(".", (strlen($field_temp_val) - 2)) . '@' . $temp_emailARY[1]; + if (strlen($field_temp_val) > 1) + {$OBSCUREemail = substr($field_temp_val,0,2) . str_repeat(".", (strlen($field_temp_val) - 2)) . '@' . $temp_emailARY[1];} + else + {$OBSCUREemail = '<'._QXZ("none").'>';} # first 3 digits and last 2 digits $field_temp_val = $OBSCUREmobile_number; - $OBSCUREmobile_number = substr($field_temp_val,0,3) . str_repeat("x", (strlen($field_temp_val) - 5)) . substr($field_temp_val,-2,2); + if (strlen($field_temp_val) > 1) + {$OBSCUREmobile_number = substr($field_temp_val,0,3) . str_repeat("x", (strlen($field_temp_val) - 5)) . substr($field_temp_val,-2,2);} + else + {$OBSCUREmobile_number = '<'._QXZ("none").'>';} ### BEGIN Gather 2FA settings container details ### $valid_2FA_config=0; @@ -1898,7 +1907,7 @@ else $two_factor_settings = explode("\n",$TFAcontainer_entry); $two_factor_settings_ct = count($two_factor_settings); $tfal=0; - while ($two_factor_settings_ct >= $tfal) + while ($two_factor_settings_ct > $tfal) { if (preg_match("/^auth_code_expire_minutes=>/",$two_factor_settings[$tfal])) { diff --git a/www/vicidial/AST_hangup_cause_report.php b/www/vicidial/AST_hangup_cause_report.php index 7cda4f93..6be91d18 100644 --- a/www/vicidial/AST_hangup_cause_report.php +++ b/www/vicidial/AST_hangup_cause_report.php @@ -1,7 +1,7 @@ LICENSE: AGPLv2 +# Copyright (C) 2025 Joe Johnson, Matt Florell LICENSE: AGPLv2 # # CHANGES # 120331-2301 - First build @@ -22,6 +22,7 @@ # 220302-1813 - Added allow_web_debug system setting # 220812-0940 - Added User Group report permissions checking # 240801-1130 - Code updates for PHP8 compatibility +# 260103-1900 - Small fix for missing variables in links # $startMS = microtime(); @@ -814,7 +815,7 @@ if ($SUBMIT && $server_ip_ct>0) { if (!$lower_limit) {$lower_limit=1;} if ($lower_limit+999>=mysqli_num_rows($rpt_rslt)) {$upper_limit=($lower_limit+mysqli_num_rows($rpt_rslt)%1000)-1;} else {$upper_limit=$lower_limit+999;} - $TEXT.="--- "._QXZ("CARRIER LOG RECORDS FOR")." $query_date, $query_date_D "._QXZ("TO")." $query_date_T $server_rpt_string, $HC_rpt_string, $DS_rpt_string\n --- "._QXZ("RECORDS")." #$lower_limit-$upper_limit ["._QXZ("DOWNLOAD")."]\n"; + $TEXT.="--- "._QXZ("CARRIER LOG RECORDS FOR")." $query_date, $query_date_D "._QXZ("TO")." $query_date_T $server_rpt_string, $HC_rpt_string, $DS_rpt_string\n --- "._QXZ("RECORDS")." #$lower_limit-$upper_limit ["._QXZ("DOWNLOAD")."]\n"; $carrier_rpt.="+----------------------+---------------------+-----------------+-----------+--------------+-------------+------------------------------------------+--------------+-----------+---------------+--------------+--------------+--------------------------------+\n"; $carrier_rpt.="| "._QXZ("UNIQUE ID",20)." | "._QXZ("CALL DATE",19)." | "._QXZ("SERVER IP",15)." | "._QXZ("LEAD ID",9)." | "._QXZ("HANGUP CAUSE",12)." | "._QXZ("DIAL STATUS",11)." | "._QXZ("CHANNEL",40)." | "._QXZ("CALLER ID",12)." | "._QXZ("DIAL TIME",9)." | "._QXZ("ANSWERED TIME",13)." | "._QXZ("PHONE NUMBER",12)." | "._QXZ("SIP RESPONSE",12)." | "._QXZ("SIP REASON",30)." |\n"; $carrier_rpt.="+----------------------+---------------------+-----------------+-----------+--------------+-------------+------------------------------------------+--------------+-----------+---------------+--------------+--------------+--------------------------------+\n"; @@ -823,7 +824,7 @@ if ($SUBMIT && $server_ip_ct>0) { $HTML.=""; $HTML.=""; $HTML.=""; - $HTML.=""; + $HTML.=""; $HTML.="\n"; $HTML.=""; $HTML.=""; diff --git a/www/vicidial/admin.php b/www/vicidial/admin.php index 4412a842..0be12866 100644 --- a/www/vicidial/admin.php +++ b/www/vicidial/admin.php @@ -1,7 +1,7 @@ LICENSE: AGPLv2 +# Copyright (C) 2026 Matt Florell LICENSE: AGPLv2 # $startMS = microtime(); @@ -6304,12 +6304,13 @@ if ($SSscript_remove_js > 0) # 251112-2201 - Added alter_cid_name DID option # 251204-0757 - Added SERVER DRIVE PARTITIONS display # 251211-1134 - Added ADAPT_PERCENTMAX dial_method and adaptive_percentmax_percentage campaign setting +# 260106-1438 - Fixes for PHP8, 2026 date change # # make sure you have added a user to the vicidial_users MySQL table with at least user_level 9 to access this page the first time -$admin_version = '2.14-950a'; -$build = '251211-1134'; +$admin_version = '2.14-951a'; +$build = '260106-1438'; $STARTtime = date("U"); $SQLdate = date("Y-m-d H:i:s"); @@ -6384,7 +6385,7 @@ if ($force_logout) echo "\n"; echo "\n"; echo "\n"; - echo "\n"; + echo "\n"; echo "\n"; ?> \n"; echo "\n"; @@ -50909,7 +50910,7 @@ if ($ADD==99999701) { $subhead_font = "style=\"font-family:HELVETICA;font-size:14;color:BLACK;font-weight:bold;\""; - echo "\"Two-Factor-Authentication\" "._QXZ("Two-Factor-Authentication"),"
\n"; + echo "\"Two-Factor-Authentication\" "._QXZ("Two-Factor-Authentication")."
\n"; if ( ($SStwo_factor_auth_hours < 1) or ($SStwo_factor_container == '') or ($SStwo_factor_container == '---DISABLED---') ) { @@ -50923,10 +50924,18 @@ if ($ADD==99999701) # first character and last 6 characters $temp_emailARY = explode('@',$OBSCUREemail); $field_temp_val = $temp_emailARY[0]; - $OBSCUREemail = substr($field_temp_val,0,2) . str_repeat(".", (strlen($field_temp_val) - 2)) . '@' . $temp_emailARY[1]; + if (is_null($field_temp_val)) {$field_temp_val='';} + if (strlen($field_temp_val) > 1) + {$OBSCUREemail = substr($field_temp_val,0,2) . str_repeat(".", (strlen($field_temp_val) - 2)) . '@' . $temp_emailARY[1];} + else + {$OBSCUREemail = '<'._QXZ("none").'>';} # first 3 digits and last 2 digits $field_temp_val = $OBSCUREmobile_number; - $OBSCUREmobile_number = substr($field_temp_val,0,3) . str_repeat("x", (strlen($field_temp_val) - 5)) . substr($field_temp_val,-2,2); + if (is_null($field_temp_val)) {$field_temp_val='';} + if (strlen($field_temp_val) > 1) + {$OBSCUREmobile_number = substr($field_temp_val,0,3) . str_repeat("x", (strlen($field_temp_val) - 5)) . substr($field_temp_val,-2,2);} + else + {$OBSCUREmobile_number = '<'._QXZ("none").'>';} ### BEGIN Gather 2FA settings container details ### $valid_2FA_config=0; @@ -50959,7 +50968,7 @@ if ($ADD==99999701) $two_factor_settings = explode("\n",$TFAcontainer_entry); $two_factor_settings_ct = count($two_factor_settings); $tfal=0; - while ($two_factor_settings_ct >= $tfal) + while ($two_factor_settings_ct > $tfal) { if (preg_match("/^auth_code_expire_minutes=>/",$two_factor_settings[$tfal])) { @@ -51052,6 +51061,8 @@ if ($ADD==99999701) echo "
"._QXZ("Two-Factor-Authentication is not properly configured on your system. Please contact your system administrator")."

$valid_2FA_config|$SStwo_factor_auth_hours|$SStwo_factor_container

\n"; exit; } + if (is_null($LOGemail)) {$LOGemail='';} + if (is_null($LOGmobile_number)) {$LOGmobile_number='';} if ( (strlen($LOGemail) < 4) and (strlen($LOGmobile_number) < 2) ) { echo _QXZ("Your User account is not configured for Two-Factor-Authentication. Please contact your system administrator. (no email or mobile number)").".\n"; @@ -51063,6 +51074,7 @@ if ($ADD==99999701) { $auth_fail=0; echo "
"; + if (is_null($rank)) {$rank='';} if (strlen($rank) < 2) { echo _QXZ("Please go back and enter a valid authorization code")." |1|" . strlen($rank) . "|"; $auth_fail++; @@ -51186,6 +51198,8 @@ if ($ADD==99999701) ### Send auth code by PHONE if ($stage == 'PHONE') { + if (is_null($ext_context)) {$ext_context='';} + if (is_null($phone_message_override)) {$phone_message_override='';} $context_2FA = '2FA_say_auth_code'; if (strlen($phone_message_override) > 0) {$context_2FA = $phone_message_override;} if (strlen($ext_context) < 1) {$ext_context='default';} @@ -51558,7 +51572,7 @@ if ($ADD==999995) echo "
"._QXZ("Welcome to ViciDial: copyright, trademark and license page")."

\n"; echo "
"._QXZ("CARRIER LOG RECORDS FOR")." $query_date, $query_date_D "._QXZ("TO")." $query_date_T $server_rpt_string, $HC_rpt_string, $DS_rpt_string\n --- "._QXZ("RECORDS")." #$lower_limit-$upper_limit["._QXZ("DOWNLOAD")."]["._QXZ("DOWNLOAD")."]
"._QXZ("UNIQUE ID")."
\n"; - echo "\n"; + echo "\n"; echo "\n"; @@ -53037,7 +53051,7 @@ echo "

"; echo _QXZ("BUILD").": $build\n"; if (!preg_match("/_BUILD_/",$SShosted_settings)) - {echo "
© 2025 ViciDial Group
";} + {echo "
© 2026 ViciDial Group
";} echo "
\n"; ?>
"._QXZ("Copyright").":   "._QXZ("The ViciDial Contact Center Suite is maintained by the")." ViciDial Group, © 2025
"._QXZ("Copyright").":   "._QXZ("The ViciDial Contact Center Suite is maintained by the")." ViciDial Group, © 2026
"._QXZ("Trademark").":   \"VICIDIAL\" "._QXZ("is a registered trademark of the")." ViciDial Group. Here is our "._QXZ("trademark use policy")."