When setting educational requirements for a job, it's important for the requirements to be relevant to the job at hand. There has to be a reason for the employer to set that standard. This is to keep employers from discriminating based on educational levels.
One important thing to consider when deciding if the requirements are legal or not is the intent. In some cases, employers may set standards in an effort to make it impossible for certain groups of people to apply for the positions. This allows them to discriminate against those groups without expressly saying that's what they're doing.
For instance, perhaps an employer knows that women are more likely to hold a college degree than men. In 2018, a full 35.3% of women had completed four years of college, as compared to 34.6% of men. If the employer is biased against men and wants to prevent them from applying for jobs at the company, requiring a four-year degree means that more women will be eligible for the jobs than men.
Granted, this is a small difference in percentages, but you can imagine how the same information could be used to discriminate against people of different ages, races or ethnicities. This also simply illustrates how employers may try to cover up gender-based discrimination and harassment; it is certainly not the only way that they do so.
Do you think that you have been discriminated against while trying to get a job or after you already worked for the company? If so, you absolutely need to know what rights you have and what steps you should take.