I would say, "Do you have any friends?". "Have you got any friends?" is grammatically correct though. I guess most people have more than one friend, hopefully. For some reason, "have you got a friend" to me sounds like the person asking is talking about a friend to go with you somewhere for a specific event or something. "Do you have a friend to go with you to the concert?".