I'm not sure if there's any law against that, but there should be if there isn't already one. JYP Entertainment actually did have a restraining order placed on him, but, according to them, Nayeon submitted a request to have it withdrawn. The reason or reasons weren't made public.
They were made public.
"The restraining order injunction is a civil case, but due to issues with processing, we plan to drop that injunction for now. We will resume that injunction when [the stalker] enters the country again."