I was just hired for a new job, and my employer has sent me a document to sign. It's called a "Covenant not to compete." It looks like I have to agree not to work anywhere else in the same field for 2 years after I leave this job. Is this legal?
This type of contract is called a non-compete agreement, or restrictive covenant. They are a common way that companies try to protect their secrets. Sometimes, they are legal. But they have to be reasonable.
This means that the contract can't prevent you from ever working in the same industry anywhere in the world. That would be way too restrictive than it needs to be. A judge would call that unreasonable, and not enforce it. But, a restriction for 2 years, that only restricts you from doing the same job in the same region as your current job, is much more reasonable.
If you think your non-compete agreement is unreasonable, you should talk to a lawyer.
Also, as of January 1st, 2017, if you make $13/hour or less, your employer cannot make you sign a non-compete agreement, no matter how reasonable it is. This is because of the Illinois Freedom to Work Act.