New hostel rules at my college say that students who violate the curfew for the fifth time will be restrained and not allowed to leave campus for one month. This applies in spite of getting permission from parents or guardians (not that it matters for most). You can find more info [here](
https://www.reddit.com/r/Btechtards/comments/1i91pdg/hostel_rules_at_iiit_bangalore/).
What is the legality of this? How can a private institute lawfully enforce a rule like this, and what action can students take?