Tuesday 27 August 2013

How to Authorize SignalR Hub Connection using Cookie?

How to Authorize SignalR Hub Connection using Cookie?

I am very new to SignalR and I am trying to authorize connections to the
SignalR Hub using Cookie.
Below is the code for my Hub Class;
[Authorize]
public class MyHub : Hub
{
....
}
and I've below code in the Application_Start
RouteTable.Routes.MapHubs();
GlobalHost.HubPipeline.RequireAuthentication();
Where am I supposed to do the Authorization process? Is there any specific
event for this? Or AuthorizeRequest method which I can override?

No comments:

Post a Comment