mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2025-02-20 13:46:52 +01:00
Debug v21
This commit is contained in:
parent
f35c232530
commit
84940c6f84
|
|
@ -291,7 +291,7 @@ class ConferenceOrBooth extends ActionComm
|
|||
|
||||
$link_subscription = $dolibarr_main_url_root.'/public/eventorganization/attendee_new.php?id='.urlencode((string) ($id)).'&type=conf';
|
||||
|
||||
$encodedsecurekey = dol_hash(getDolGlobalString('EVENTORGANIZATION_SECUREKEY').'conferenceorbooth'.$id, '2');
|
||||
$encodedsecurekey = dol_hash(getDolGlobalString('EVENTORGANIZATION_SECUREKEY').'conferenceorbooth'.((int) $id), 'md5');
|
||||
$link_subscription .= '&securekey='.urlencode($encodedsecurekey);
|
||||
|
||||
/*$this->fields['pubregister'] = array('type'=>'url', 'label'=>$langs->trans("PublicAttendeeSubscriptionPage"), 'enabled'=>'1', 'position'=>72, 'notnull'=>0, 'visible'=>1);
|
||||
|
|
|
|||
|
|
@ -362,7 +362,7 @@ if (empty($reshook) && $action == 'add' && (!empty($conference->id) && $conferen
|
|||
|
||||
// If the registration has already been paid for this attendee
|
||||
if (!empty($confattendee->date_subscription) && !empty($confattendee->amount)) {
|
||||
$securekeyurl = dol_hash(getDolGlobalString('EVENTORGANIZATION_SECUREKEY') . 'conferenceorbooth'.$id, 'master');
|
||||
$securekeyurl = dol_hash(getDolGlobalString('EVENTORGANIZATION_SECUREKEY') . 'conferenceorbooth'.((int) $id), 'md5');
|
||||
$redirection = $dolibarr_main_url_root.'/public/eventorganization/subscriptionok.php?id='.((int) $id).'&securekey='.urlencode($securekeyurl);
|
||||
|
||||
$mesg = $langs->trans("RegistrationAndPaymentWereAlreadyRecorded", $email);
|
||||
|
|
@ -698,7 +698,7 @@ if (empty($reshook) && $action == 'add' && (!empty($conference->id) && $conferen
|
|||
dol_syslog("Failed to send EMail to ".$sendto, LOG_ERR, 0, '_payment');
|
||||
}
|
||||
|
||||
$securekeyurl = dol_hash(getDolGlobalString('EVENTORGANIZATION_SECUREKEY') . 'conferenceorbooth'.$id, '2');
|
||||
$securekeyurl = dol_hash(getDolGlobalString('EVENTORGANIZATION_SECUREKEY') . 'conferenceorbooth'.((int) $id), 'md5');
|
||||
$redirection = $dolibarr_main_url_root.'/public/eventorganization/subscriptionok.php?id='.((int) $id).'&securekey='.urlencode($securekeyurl);
|
||||
|
||||
header("Location: ".$redirection);
|
||||
|
|
|
|||
|
|
@ -81,7 +81,7 @@ $error = 0;
|
|||
// Security check
|
||||
$id = GETPOSTINT("id");
|
||||
$securekeyreceived = GETPOST("securekey");
|
||||
$securekeytocompare = dol_hash(getDolGlobalString('EVENTORGANIZATION_SECUREKEY') . 'conferenceorbooth'.$id, '2');
|
||||
$securekeytocompare = dol_hash(getDolGlobalString('EVENTORGANIZATION_SECUREKEY') . 'conferenceorbooth'.((int) $id), 'md5');
|
||||
|
||||
if ($securekeyreceived != $securekeytocompare) {
|
||||
print $langs->trans('MissingOrBadSecureKey');
|
||||
|
|
|
|||
|
|
@ -94,7 +94,7 @@ if ($resultproject < 0) {
|
|||
|
||||
// Security check
|
||||
$securekeyreceived = GETPOST('securekey', 'alpha');
|
||||
$securekeytocompare = dol_hash(getDolGlobalString('EVENTORGANIZATION_SECUREKEY') . 'conferenceorbooth'.$id, 'md5');
|
||||
$securekeytocompare = dol_hash(getDolGlobalString('EVENTORGANIZATION_SECUREKEY') . 'conferenceorbooth'.((int) $id), 'md5');
|
||||
|
||||
if ($securekeytocompare != $securekeyreceived) {
|
||||
print $langs->trans('MissingOrBadSecureKey');
|
||||
|
|
@ -550,7 +550,7 @@ if (empty($reshook) && $action == 'add') { // Test on permission not required he
|
|||
dol_syslog("Failed to send EMail to ".$sendto, LOG_ERR, 0, '_payment');
|
||||
}
|
||||
|
||||
$securekeyurl = dol_hash(getDolGlobalString('EVENTORGANIZATION_SECUREKEY') . 'conferenceorbooth'.$id, '2');
|
||||
$securekeyurl = dol_hash(getDolGlobalString('EVENTORGANIZATION_SECUREKEY') . 'conferenceorbooth'.((int) $id), 'md5');
|
||||
$redirection = $dolibarr_main_url_root.'/public/eventorganization/subscriptionok.php?id='.$id.'&securekey='.$securekeyurl;
|
||||
header("Location: ".$redirection);
|
||||
exit;
|
||||
|
|
|
|||
|
|
@ -94,7 +94,7 @@ if ($resultproject < 0) {
|
|||
|
||||
// Security check
|
||||
$securekeyreceived = GETPOST('securekey', 'alpha');
|
||||
$securekeytocompare = dol_hash(getDolGlobalString('EVENTORGANIZATION_SECUREKEY') . 'conferenceorbooth'.$id, 'md5');
|
||||
$securekeytocompare = dol_hash(getDolGlobalString('EVENTORGANIZATION_SECUREKEY') . 'conferenceorbooth'.((int) $id), 'md5');
|
||||
|
||||
if ($securekeytocompare != $securekeyreceived) {
|
||||
print $langs->trans('MissingOrBadSecureKey');
|
||||
|
|
@ -486,7 +486,7 @@ if (empty($reshook) && $action == 'add') { // Test on permission not required he
|
|||
|
||||
if (!$error) {
|
||||
$db->commit();
|
||||
$securekeyurl = dol_hash(getDolGlobalString('EVENTORGANIZATION_SECUREKEY') . 'conferenceorbooth'.$id, '2');
|
||||
$securekeyurl = dol_hash(getDolGlobalString('EVENTORGANIZATION_SECUREKEY') . 'conferenceorbooth'.((int) $id), 'md5');
|
||||
$redirection = $dolibarr_main_url_root.'/public/eventorganization/subscriptionok.php?id='.((int) $id).'&securekey='.urlencode($securekeyurl);
|
||||
header("Location: ".$redirection);
|
||||
exit;
|
||||
|
|
|
|||
|
|
@ -81,7 +81,7 @@ $error = 0;
|
|||
$action = GETPOST('action', 'aZ09');
|
||||
$id = GETPOST('id');
|
||||
$securekeyreceived = GETPOST("securekey");
|
||||
$securekeytocompare = dol_hash(getDolGlobalString('EVENTORGANIZATION_SECUREKEY') . 'conferenceorbooth'.$id, 'md5');
|
||||
$securekeytocompare = dol_hash(getDolGlobalString('EVENTORGANIZATION_SECUREKEY') . 'conferenceorbooth'.((int) $id), 'md5');
|
||||
|
||||
if ($securekeytocompare != $securekeyreceived) {
|
||||
print $langs->trans('MissingOrBadSecureKey');
|
||||
|
|
@ -173,10 +173,10 @@ while ($i < $db->num_rows($result)) {
|
|||
*/
|
||||
|
||||
// Get vote result
|
||||
$idvote = GETPOST("vote");
|
||||
$hashedvote = dol_hash(getDolGlobalString('EVENTORGANIZATION_SECUREKEY') . 'vote'.$idvote);
|
||||
$idvote = GETPOSTINT("vote");
|
||||
$hashedvote = dol_hash(getDolGlobalString('EVENTORGANIZATION_SECUREKEY').'vote'.$idvote);
|
||||
|
||||
if (strlen($idvote)) {
|
||||
if ($idvote > 0) {
|
||||
if (in_array($hashedvote, $listofvotes)) {
|
||||
// Has already voted
|
||||
$votestatus = 'ko';
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user