From 326686794a439d3c6268336014083f23712a5116 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Fri, 12 Aug 2022 17:09:14 +0200 Subject: [PATCH 1/7] Fix when log handler has been removed --- htdocs/core/class/conf.class.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/htdocs/core/class/conf.class.php b/htdocs/core/class/conf.class.php index 2b19e0db134..97edefd01e1 100644 --- a/htdocs/core/class/conf.class.php +++ b/htdocs/core/class/conf.class.php @@ -1013,7 +1013,9 @@ class Conf } if (empty($handler_file_found)) { - throw new Exception('Missing log handler file '.$handler.'.php'); + // If log handler has been removed of is badly setup, we must be able to continue code. + //throw new Exception('Missing log handler file '.$handler.'.php'); + continue; } require_once $handler_file_found; From 5b74f1d3dcca9838dd2c5c9aa002b10660841232 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sat, 13 Aug 2022 12:33:00 +0200 Subject: [PATCH 2/7] Fix duplicate string Conflicts: htdocs/public/members/new.php --- htdocs/install/step4.php | 2 +- htdocs/langs/en_US/install.lang | 1 - htdocs/langs/en_US/main.lang | 2 +- htdocs/public/members/new.php | 2 +- 4 files changed, 3 insertions(+), 4 deletions(-) diff --git a/htdocs/install/step4.php b/htdocs/install/step4.php index 1bd7665f52a..1b179cf98ab 100644 --- a/htdocs/install/step4.php +++ b/htdocs/install/step4.php @@ -83,7 +83,7 @@ if ($db->ok) { print ''; print ''; print ''; - print ''; + print ''; print ''; print ''; diff --git a/htdocs/langs/en_US/install.lang b/htdocs/langs/en_US/install.lang index 4db9086dec9..dd451200c11 100644 --- a/htdocs/langs/en_US/install.lang +++ b/htdocs/langs/en_US/install.lang @@ -50,7 +50,6 @@ DatabaseName=Database name DatabasePrefix=Database table prefix DatabasePrefixDescription=Database table prefix. If empty, defaults to llx_. AdminLogin=User account for the Dolibarr database owner. -PasswordAgain=Retype password confirmation AdminPassword=Password for Dolibarr database owner. CreateDatabase=Create database CreateUser=Create user account or grant user account permission on the Dolibarr database diff --git a/htdocs/langs/en_US/main.lang b/htdocs/langs/en_US/main.lang index c44bea6a078..cf748a60626 100644 --- a/htdocs/langs/en_US/main.lang +++ b/htdocs/langs/en_US/main.lang @@ -222,7 +222,7 @@ UserGroup=User group UserGroups=User groups NoUserGroupDefined=No user group defined Password=Password -PasswordRetype=Retype your password +PasswordRetype=Repeat your password NoteSomeFeaturesAreDisabled=Note that a lot of features/modules are disabled in this demonstration. Name=Name NameSlashCompany=Name / Company diff --git a/htdocs/public/members/new.php b/htdocs/public/members/new.php index 31f1fa9f952..333ef90677f 100644 --- a/htdocs/public/members/new.php +++ b/htdocs/public/members/new.php @@ -564,7 +564,7 @@ print 'global->ADHERENT_LOGIN_NOT_REQUIRED)) { print ''.$langs->trans("Login").' *'."\n"; print ''.$langs->trans("Password").' *'."\n"; - print ''.$langs->trans("PasswordAgain").' *'."\n"; + print ''.$langs->trans("PasswordRetype").' *'."\n"; } // Gender print ''.$langs->trans("Gender").''; From 168f07933e9359deb20f23292cfb426212d0d4f8 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sat, 13 Aug 2022 13:51:47 +0200 Subject: [PATCH 3/7] FIX #18425 --- htdocs/societe/class/api_thirdparties.class.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htdocs/societe/class/api_thirdparties.class.php b/htdocs/societe/class/api_thirdparties.class.php index 962bbf021b8..4f70a6b9335 100644 --- a/htdocs/societe/class/api_thirdparties.class.php +++ b/htdocs/societe/class/api_thirdparties.class.php @@ -442,7 +442,7 @@ class Thirdparties extends DolibarrApi 'FactureFournisseur' => '/fourn/class/fournisseur.facture.class.php', 'SupplierProposal' => '/supplier_proposal/class/supplier_proposal.class.php', 'ProductFournisseur' => '/fourn/class/fournisseur.product.class.php', - 'Livraison' => '/delivery/class/delivery.class.php', + 'Delivery' => '/delivery/class/delivery.class.php', 'Product' => '/product/class/product.class.php', 'Project' => '/projet/class/project.class.php', 'Ticket' => '/ticket/class/ticket.class.php', From 2c95d8d5cd26749cddf7609c02210af4d3e2d6ae Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sat, 13 Aug 2022 13:54:32 +0200 Subject: [PATCH 4/7] FIX #18425 --- htdocs/societe/class/api_thirdparties.class.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/htdocs/societe/class/api_thirdparties.class.php b/htdocs/societe/class/api_thirdparties.class.php index 4f70a6b9335..5021712c010 100644 --- a/htdocs/societe/class/api_thirdparties.class.php +++ b/htdocs/societe/class/api_thirdparties.class.php @@ -425,8 +425,9 @@ class Thirdparties extends DolibarrApi // TODO Mutualise the list into object societe.class.php $objects = array( 'Adherent' => '/adherents/class/adherent.class.php', + 'Don' => '/don/class/don.class.php', 'Societe' => '/societe/class/societe.class.php', - 'Categorie' => '/categories/class/categorie.class.php', + //'Categorie' => '/categories/class/categorie.class.php', 'ActionComm' => '/comm/action/class/actioncomm.class.php', 'Propal' => '/comm/propal/class/propal.class.php', 'Commande' => '/commande/class/commande.class.php', @@ -447,7 +448,8 @@ class Thirdparties extends DolibarrApi 'Project' => '/projet/class/project.class.php', 'Ticket' => '/ticket/class/ticket.class.php', 'User' => '/user/class/user.class.php', - 'Account' => '/compta/bank/class/account.class.php' + 'Account' => '/compta/bank/class/account.class.php', + 'ConferenceOrBoothAttendee' => '/eventorganization/class/conferenceorboothattendee.class.php' ); //First, all core objects must update their tables From 35822d943133c57f456aac2826d257a92271c30f Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sat, 13 Aug 2022 15:08:36 +0200 Subject: [PATCH 5/7] css --- htdocs/fourn/facture/list.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/htdocs/fourn/facture/list.php b/htdocs/fourn/facture/list.php index df5cd0d090d..1c41820012e 100644 --- a/htdocs/fourn/facture/list.php +++ b/htdocs/fourn/facture/list.php @@ -1434,8 +1434,8 @@ if ($resql) { } // Zip if (!empty($arrayfields['s.zip']['checked'])) { - print ''; - print $obj->zip; + print ''; + print dol_escape_htmltag($obj->zip); print ''; if (!$i) { $totalarray['nbfield']++; From 9732c3c06a3dfab2f30855315af13c515b4fe25b Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sun, 14 Aug 2022 15:25:06 +0200 Subject: [PATCH 6/7] Fix error code --- htdocs/public/recruitment/index.php | 5 +++-- htdocs/public/recruitment/view.php | 5 +++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/htdocs/public/recruitment/index.php b/htdocs/public/recruitment/index.php index ce30306eb2f..632a3f57da2 100644 --- a/htdocs/public/recruitment/index.php +++ b/htdocs/public/recruitment/index.php @@ -272,9 +272,10 @@ if (is_array($results)) { if ($action != 'dosubmit') { - if ($found && !$error) { // We are in a management option and no error + if ($found && !$error) { + // We are in a management option and no error } else { - dol_print_error_email('ERRORNEWONLINESIGN'); + dol_print_error_email('ERRORSUBMITAPPLICATION'); } } else { // Print diff --git a/htdocs/public/recruitment/view.php b/htdocs/public/recruitment/view.php index 4516b9c0d2f..b92dcbf9824 100644 --- a/htdocs/public/recruitment/view.php +++ b/htdocs/public/recruitment/view.php @@ -323,9 +323,10 @@ print "\n"; if ($action != 'dosubmit') { - if ($found && !$error) { // We are in a management option and no error + if ($found && !$error) { + // We are in a management option and no error } else { - dol_print_error_email('ERRORNEWONLINESIGN'); + dol_print_error_email('ERRORSUBMITAPPLICATION'); } } else { // Print From a0d56b6db764736c1e6b1bc0cc2b799f1ffc7654 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sun, 14 Aug 2022 19:14:20 +0200 Subject: [PATCH 7/7] FIX the online signature feature --- htdocs/core/lib/signature.lib.php | 2 +- htdocs/public/onlinesign/newonlinesign.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/htdocs/core/lib/signature.lib.php b/htdocs/core/lib/signature.lib.php index 6a8d824872d..33b0a1e8e5e 100644 --- a/htdocs/core/lib/signature.lib.php +++ b/htdocs/core/lib/signature.lib.php @@ -91,7 +91,7 @@ function getOnlineSignatureUrl($mode, $type, $ref = '', $localorexternal = 1) if ($mode == 1) { $out .= "hash('".$securekeyseed."' + '".$type."' + proposal_ref)"; } else { - $out .= '&securekey='.dol_hash($securekeyseed.$type.$ref.$object->entity, '0'); + $out .= '&securekey='.dol_hash($securekeyseed.$type.$ref, '0'); } /* if ($mode == 1) { diff --git a/htdocs/public/onlinesign/newonlinesign.php b/htdocs/public/onlinesign/newonlinesign.php index 9ebea80aeb3..87aef8163e1 100644 --- a/htdocs/public/onlinesign/newonlinesign.php +++ b/htdocs/public/onlinesign/newonlinesign.php @@ -139,7 +139,7 @@ if ($source == 'proposal') { $securekeyseed = $conf->global->PROPOSAL_ONLINE_SIGNATURE_SECURITY_TOKEN; } -if (!dol_verifyHash($securekeyseed.$type.$ref.$object->entity, $SECUREKEY, '0')) { +if (!dol_verifyHash($securekeyseed.$type.$ref, $SECUREKEY, '0')) { http_response_code(403); print 'Bad value for securitykey. Value provided '.dol_escape_htmltag($SECUREKEY).' does not match expected value for ref='.dol_escape_htmltag($ref); exit(-1);