Following societies' rules is the basic principle of the social contract, I recommend reading a little about it starting from Hobbes' Leviathan.
I think society has opinions and ideas that evolve into ethics and morals that are represented in laws.
It’s not a secret. In this case, rights are curtailed to require vaccines. This is deemed acceptable. If you don’t like it, convince your country mates to change their mind. Or move to a country that feels differently. Or move to the wilderness.
I think it also varies from country to country as it varies quite a bit.