Issue(SOLVED): Sitecore 8.2.3: IsAuthenticated property is “false” for statless/token based authentication in ServicesApiController

Posted by on Jun 9, 2017 in Sitecore Blog | 0 comments

I have had issue with JWT  token authentication in stateless mode, where is IsAuthenticated property is always  set to ‘false’. The issue does not exist in cookie based authentication for the same request. As a workaround I used ” Context.User.Name” property instead. Solution From Sitecore: The default TokenDelegatingHandler is using UserService.SwitchToUser method to log in the user. However, UserService is loading the...

Read More

Sitecore WebAPI: ServicesApiController and JWT Token Security

Posted by on Jun 9, 2017 in Sitecore Blog | 10 comments

I would like to demonstrate how to create Sitecore WebAPI based custom service and utilize native Sitecore/.NET security mechanism. The ServicesApiController is part of Sitecore.Services.Infrastructure.dll and it implements .NET ApiController. Usage of ServicesApiController ensures continuation of Sitecore global item security policies and individual filters that can have individual requirements. My goal is to create stateless WebAPI based...

Read More