Hello. Thank you for posting.
You cannot get pregnant from anal sex. As long as there was no ejaculation placed in your vagina, there is no risk of pregnancy. I think you know this. Taking ECP when you don't need it will only cause unnecessary side effects such as period irregularity. So, be sure to read the information that comes with the pills so you know what to expect. For future, insist on a condom for any type of penetration so you won't have this worry.