Sholo.Web.Security/Authentication/Device/Provider/CacheDeviceAuthenticationTicketProvider.cs
/// <summary>
/// Retrieve a DeviceAuthenticationTicket from the ticket store by it's ticket key
/// </summary>
/// <param name="ticketKey">The ticket key generated by the server</param>
/// <returns>The DeviceAuthenticationTicket or null if no matching ticket is found</returns>
/// <exception cref="ArgumentNullException">ticketKey is null</exception>
/// <exception cref="ArgumentException">ticketKey is empty</exception>
Retrieve a DeviceAuthenticationTicket from the ticket store by it's ticket key
Retrieve a DeviceAuthenticationTicket from the ticket store by it ' s ticket key
public override DeviceAuthenticationTicket GetTicket(string ticketKey)
        {
            if (ticketKey == null)
            {
                throw new ArgumentNullException("ticketKey", "ticketKey parameter cannot be null or empty.");
            }
            if (string.IsNullOrEmpty(ticketKey))
            {
                throw new ArgumentException("ticketKey parameter cannot be null or empty.", "ticketKey");
            }
            string key = GetCacheKey(ticketKey);
            if (HttpContext.Current.Cache[key] != null)
            {
                DeviceAuthenticationTicket result = HttpContext.Current.Cache[key] as DeviceAuthenticationTicket;
                return result;
            }
            return null;
        }
public override DeviceAuthenticationTicket GetTicket ( string ticketKey ) { if ( ticketKey == null ) { throw new ArgumentNullException ( " " , " " ) ; } if ( string . IsNullOrEmpty ( ticketKey ) ) { throw new ArgumentException ( " " , " " ) ; } string key = GetCacheKey ( ticketKey ) ; if ( HttpContext . Current . Cache [ key ] != null ) { DeviceAuthenticationTicket result = HttpContext . Current . Cache [ key ] as DeviceAuthenticationTicket ; return result ; } return null ; }
Retrieve a DeviceAuthenticationTicket from the ticket store by it's ticket key
Retrieve a DeviceAuthenticationTicket from the ticket store by it ' s ticket key
The DeviceAuthenticationTicket or null if no matching ticket is found
The DeviceAuthenticationTicket or null if no matching ticket is found
ticketKey is null
ticketKey is null
ticketKey is empty
ticketKey is empty
ticketKey
string
The ticket key generated by the server
The ticket key generated by the server