Wcf – How to pass Credentials to WCF service for Windows Authentication from Silverlight

silverlightwcfwcf-clientwcf-data-serviceswcf-security

I have enabled my WCF service for Windows Authentication. How can I pass Credentials to Service from From Silverlight application.
For Credentials I can get User name and domain by code WebContext.Current.User.DisplayName. But how I will get client password through code.
serviceClient.Credentials = newSystem.Net.NetworkCredential("UserName", "Password", "Domian");

Best Answer

It should be done automatically if you have configured the client to use Windows authentication mode, please read following link:

Use Windows Authentication to Secure a Service for Silverlight Applications

Related Topic