Using HTTP? Send the host header:

Host: sub.domain.com

That should do it.