I'd like to point user test1.domain.com test2.domain.com etc without manually adding the header binding in IIS7. Is this possible? If not automatically can I add the host header programmatically?
As far as I know there are only two options when it comes to host headers in IIS7.
The catch with option #2 is it'll respond to any request on that port and you will be unable to use that same port on another site without a host header.
There may be an ISAPI filter you can load at the server level to intercept the request before it gets to the host header part of the processing but it may be easier to set up a script to handle option #1.
By setting up a wildcard DNS entry, you can have as many names as you want go to your default website. Once the user hits that website, if you need it to redirect to another site, have your default.asp file look for the HOST header to determine if it needs to redirect, otherwise, go ahead and load the rest of the site.
I'm not very good with web development, but this should at least get you started.
Yes you can.
It is possible to use a wildcard SSL certificate and one single IP.
I can detail how to test this using a self-signed wildcard.
Execute the following command from a command prompt
Now let's create your web servers
Remove existing demo app pools and sites
Tell windows that Network Service is allowed access to your wildcard cert. and tell it to bind the cert to port 443 on your IP address
This is the code to create app pools and sites
...and that should be you ;) Enjoy!