Windows authentication and Login Windows at the same Time with WCF RRS feed

  • Question

  • Hello I need to do Windows Authentication and Custom Login with username and password.

    I am not sure if I can define two Endpoints and depending on a certain scenario i call once login.

    Standard windows Authentication should work either.

    Can I define both at the same time can anyone help please?

    Thanks in Advance

    I have Seen that wcf 4.5 is allowing multiple auths for one vd in IIS but im a little confused can i have Windows auth and custom Login with credentials at the Same like to let windows auth to fail at a certain scenario and than call a Login view and if the user Login correctly it should all be authenticated...

    • Edited by TronMe Thursday, July 17, 2014 10:35 PM
    Thursday, July 17, 2014 9:29 PM

All replies

  • Hi,

    In WCF 4.5 we can specify a subset of authentication schemes to be used with our service using the ServiceAuthenticationBehavior or the <serviceAuthenticationManager> element as following:

            <behavior name="limitedAuthBehavior">
              <serviceAuthenticationManager authenticationSchemes="Negotiate, Digest, Basic"/>
              <!-- ... -->

    For more information, please try to refer to:
    #Using Multiple Authentication Schemes with WCF: .

    #2 auth modes on 1 endpoint - Using Multiple Authentication Schemes with ServiceAuthorizationManager: .

    Then for your question, you can have a test, if you meet any error, please try to post it here.

    Best Regards,
    Amy Peng

    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.

    Friday, July 18, 2014 10:24 AM
  • Hi,

    thanks for your answer. I understand this now, so I can use a custom Login and Windows Authentication both on one endpoint by setting authenticationsheme. I already created a class that inherits from ServiceAuthenticationManager and I can interact with this class on every request. This is fine. At the Moment I only use Windows Authentication first on IIS. But i dont understand how to activate the custom Login authScheme im hanging on the fact that i dont see how to call the custom Login because I enter the class that I have created for every request and this is as far as i understand windows authentication that already has happened than. At this step i want on a custom login window with username and password to activate depending on a scenario...But this I cant do because I dont know how...

    Thanks in advance for your Help

    • Edited by TronMe Friday, July 18, 2014 10:41 AM
    Friday, July 18, 2014 10:40 AM