It appears that such an ordinance is an example of age discrimination.
Assuming that a person under a certain age out at night is more likely to commit a crime than an older person out at night also appears to be prejudicial. However, if a specific young person has been arrested numerous times at night committing crimes, I could see how a curfew could be imposed upon that criminally-minded individual, due to his or her prior actions. To pass an ordinance to include all youth who may or may not have a criminal history is very poor policy.
A curfew so imposed is a violation of Rights, since you have a perfect right to be out and about at night. But the exercise of that Right ends (not the Right itself) when any individual commits crime at night, which is, in effect, violating the Rights of others.