Giving a guy a hand job isn't going to result in an STD for you. That's pretty much non sexual contact for YOU. Your hand isn't a means for transmission. And soap isn't going to give you an std either. His just touching you also isn't going to transmit an std. I would say that if you become this nervous you have two options to either forgo sexual activity until you are ready to take on risks and not worry about non risks (which getting really educated on what they are helps) or getting help for anxiety. Do you tend to worry a lot in general?
It does not sound like you exposed yourself to any risk. After all, the guy would have to have an STD in the first place, and the likelihood of him having one and not knowing does not seem high. Then you took a lot of precautions, and probably did not have anything on your hand by the time you washed your vagina with it.