Such exclusionary criteria are permitted under Section 14 of the Ontario Human Rights Code to “relieve hardship or economic disadvantage, help disadvantaged people or groups to achieve, or try to achieve, equal opportunity or help eliminate discrimination.”

https://jonathanturley.org/2022/04/23/university-of-waterloo-limits-science-position-to-women-transgender-non-binary-or-two-spirit-persons/