When you make a service available external to your corporate network sometimes SSL isn’t secure enough.  If you really want to limit the users who can access a service they need to tied to credentials.  One of the most common credentials to tie to is a Windows account.  What if you are the consumer of these services.

When you add a service reference to a Visual Studio 2010 project it does not give you a chance to set credentials.  The following example is how you can apply credentials to a service reference.

ServiceReference1.MyService servicesClient = new ServiceReference1.MyService();
servicesClient.ClientCredentials.Windows.ClientCredential = new NetworkCredential("myUserName", "myPa$$W0rd", "mydomain.com");

While this example has hard coded credentials that is simply for demonstration.  You could easily (and should) replace these parameters with configured values.  As usual we are not talking about rocket science, but hopefully this tidbit will help a few people.