You make a quick friend with the dog, momentarily distracting them, and hopefully find you acceptable. When I used to house sit, at times that included taking care of pets, i.e., the dog. The week prior to the scheduled house sitting, I would meet the owner and the dog to go on a walk. I kept several treats, normally a small dog biscuit, with me. The next week when I moved in and its me and the dog, of course the come crashing the front door. I pull out half a biscuit, hold my hand flat, and the dog would take it and run to a corner of the run to eat it. By this time I've closed the door and sit on the couch. The typical sniffing occurs, and then I give the other half of the biscuit, but this time the dog stands right there and eats in. Normally after several of these, and rubbing and petting the dog, they see that your okay, and then things go forward with happy co-existence for all.