Theoritically speaking, the risk of infection occurs due to exchange of body fluids like vaginal fluid, sperm, blood and saliva.
However, the percentage of possibilty varies from one body fluid to another. Morever research shows that male to female infection is more possible than a female to male infection.
If you are unsure of what you did, and your possibility of infection, to be on a safer side, you could test yourself after the window period. In the mean time, you could protect your close one like your gf or your wife by staying away to make sure that you dont infect them too.