Public Overrides Function CheckAccess(context As Microsoft.IdentityModel.Claims.AuthorizationContext) As Boolean 'Compares the web.config predefined alias with the User Role that is received from the Token If System.Configuration.ConfigurationManager.AppSettings.Get("UserRole") = SAMLTokenRead.Role Then Return True End If 'Send the user to the page which displays "No Access" page HttpContext.Current.Response.Redirect(System.Configuration.ConfigurationManager.AppSettings.Get("NoAccessPage")) Return False End Function
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)