Try our conversational search powered by Generative AI!

Host wcf-service with basic authentication

Vote:
 

I want to host a wcf-service in my episerver-application and secure it with basic authentication the same way as with asmx-services. I’ve done the standard configuration for the webservices-catalog and added one wfc-service and one asmx-service to it. Now I cannot access neighter the catalog nor the asmx-service (when not logged in) but I can still access the wcf-service. Can I do some extra configuration or something to make this work for wcf-services?

Thanks for any reply.

#60449
Aug 09, 2012 15:51
Vote:
 

Are you accessing you WCF service directly (folder/folder/myservice.svc) or via a route?

If directly, have you placed your svc file in the standard /webservices folder or another folder?

if its in another folder, you will need to duplicate the location tag from /webservices for the new folder to set the episerver.basicAuthentication, authorization and handlers.

#60455
Aug 09, 2012 18:32
Vote:
 

Thanks for the answer!

Turns out there were something wrong with the registration of the basic authentication module. After I registered it programmatically everything seems to work.

#60458
Aug 09, 2012 21:30
Vote:
 

no problem - I have had this working before and never had to register the authentication module progrmatically. Its strange that it worked for securing asmx but not svc files.

#60460
Aug 10, 2012 9:47
Vote:
 

I have the same problem. .asmx service returns 401 Unauthorized but I can still access the .svc service in the same folder (WebServices). Is there a way to secure a WCF service in WebServices-folder?

#113296
Nov 18, 2014 10:47
This topic was created over six months ago and has been resolved. If you have a similar question, please create a new topic and refer to this one.
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.