private static void BuildUserContext(IPrincipal user)
    {
        if (!user.Identity.IsAuthenticated)
        {
            return;
        }
        // For my application, I use DI to get a service to retrieve my domain
        // user by the IPrincipal
        var personService = DependencyResolver.Current.GetService <IUserBaseService>();
        var person        = personService.FindBy(user);

        if (person == null)
        {
            return;
        }
        var uc = new UserContext {
            IsAuthenticated = true
        };
        // Here is where you would populate the user data (in my case a SiteUser object)
        var siteUser = new SiteUser();

        // This is a call to ValueInjecter, but you could map the properties however
        // you wanted. You might even be able to put your object in there if it's a POCO
        siteUser.InjectFrom <FlatLoopValueInjection>(person);
        // Next, stick the user data into the context
        uc.SiteUser = siteUser;
        // Finally, save it into your session
        HttpContext.Current.Session["UserContext"] = uc;
    }