The only risks for HIV are to have unprotected vaginal or anal sex or to share IV needles to inject drugs. Air and saliva inactivate the virus. So, exposure 1. No risk from a hand job. Air is present. Exposure 2. No risk as well as the head of your penis was always covered and you wouldn't get HIV from an inside out condom, it was exposed to air. That simply isn't a way it would transmit and transmission only happens during unprotected intercourse and INSIDE the body. No risk