Is this against the rules?

I would suggest reading through this fighter etiquette guide

You must be careful with your spacing when “escorting”. And not everyone likes it when they have a fighter flying around them. It’s also important to give the aircraft the proper spacing when on approach

(I personally do not like when a fighter is buzzing around me)