Closed davidrei closed 6 years ago
thanks for the detailed description of the bug.
The solution will be not the check for the organization. We will only check for a valid role membership and thats all. The role membership could be from organization A or B or C that doesn't matter.
Prerequisite:
Issue:
/adm_program/system/lost_password.php
Analysis:
/adm_program/system/lost_password.php
carries no information about the organisation nor does it allow the user to select an organisation[2018-09-24 15:55:12.639039] Admidio.INFO: SQL: SELECT usr_id FROM adm_members INNER JOIN adm_roles ON rol_id = mem_rol_id INNER JOIN adm_categories ON cat_id = rol_cat_id INNER JOIN adm_users ON usr_id = mem_usr_id INNER JOIN adm_user_data AS email ON email.usd_usr_id = usr_id AND email.usd_usf_id = ? AND email.usd_value = ? WHERE LENGTH(usr_login_name) > 0 AND rol_valid = 1 AND usr_valid = 1 AND mem_begin <= ? AND mem_end > ? AND ( cat_org_id = ? OR cat_org_id IS NULL ) GROUP BY usr_id [12,"test@email.com","2018-09-24","2018-09-24",1] {"file":"/…/adm_program/system/classes/Database.php","line":723,"class":"Database","function":"queryPrepared"}
Possible Solution
cat_org_id