My mother's sage advice "don't make enemies, destroy them".
Consider every possible direction you can attack them from:
Above
Appeal to authority, make it their problem, say this person is impeding your ability to do your job, obviously this works better if the authorities are inclined to favor your side of things, just don't tell them said person is your enemy or what to do about it instead let the authority figure think the punishment was their idea.
Below
Attack their foundations, people often cultivate skill/knowledge in a particular discipline/topic to serve as a crutch for their ego, kick the crutch, a great way to do this is to call them out on why they're hassling you as such motivations often tie into their own insecurities. This can backfire if you attack someone in a way that plays to their strengths or if you attack an area of assumed insecurity that isn't, particularly dangerous people may feign insecurity in some way as bait and a well prepared to punish you for taking it.
Behind
In essence "stop helping me", if someone's particularly hard to get at pretend to be on their side then undermine and sabotage them or better yet take their position to it's logical extreme to strawman them, this works best when you have an accomplice attacking them from the front. Obviously it's difficult to attack someone from behind when they've facing you because they've already identified you as an enemy.
Front
Ask someone "why are you being such an asshole?" and stare them down, maintain eye contact, most people can't deal with a combination of being asked a question they aren't prepared to answer and simultaneously put under the pressure of a possible direct confrontation. Others will just punch you, which in the right context might actually be a resounding victory.
I don't advocate an confrontational attitude, destroying enemies is effort intensive, if a rando on the street's rude to me I'm not going to bother with them, if they're sitting next to me at work I'll try to make peace first but if they choose to make my life difficult anyway then they've only themselves to blame.