Ejemplo n.º 1
0
        public override WhoAmIRequest.OutputType HandleWhoAmI(WhoAmIRequest.InputType input)
        {
            WhoAmIRequest.OutputType result = new WhoAmIRequest.OutputType();
            //result.UserEmailAddress = m_session.Email;
            result.UserIsAnonymous = m_session.IsAnonymous;
            result.UserLogin       = m_session.Login;
            result.UserName        = m_session.Name;

            return(result);
        }
Ejemplo n.º 2
0
        public override WhoAmIRequest.OutputType HandleWhoAmI(WhoAmIRequest.InputType input)
        {
            WhoAmIRequest.OutputType result = new WhoAmIRequest.OutputType();
            result.UserEmailAddress = m_session.Email;
            result.UserIsAnonymous = m_session.IsAnonymous;
            result.UserLogin = m_session.Login;
            result.UserName = m_session.Name;

            return result;
        }
Ejemplo n.º 3
0
        public override WhoAmIRequest.OutputType HandleWhoAmI(WhoAmIRequest.InputType input)
        {
            var result = new WhoAmIRequest.OutputType
            {
                UserEmailAddress = _principal?.FindFirst(ClaimTypes.Email).Value,
                UserIsAnonymous  = string.IsNullOrEmpty(_principal?.FindFirst(ClaimTypes.NameIdentifier).Value),
                UserLogin        = _principal?.FindFirst(ClaimTypes.NameIdentifier).Value,
                UserName         = _principal?.FindFirst(ClaimTypes.Name).Value
            };

            return(result);
        }
Ejemplo n.º 4
0
        public override WhoAmIRequest.OutputType HandleWhoAmI(WhoAmIRequest.InputType input)
        {
            WhoAmIRequest.OutputType result = new WhoAmIRequest.OutputType();
            result.UserIsAnonymous = WspContext.User == null;
            if (WspContext.User != null)
            {
                result.UserEmailAddress = WspContext.User.Login;
                result.UserLogin        = WspContext.User.Login;
                result.UserName         = WspContext.User.DisplayName;
            }

            return(result);
        }
        public override WhoAmIRequest.OutputType HandleWhoAmI(WhoAmIRequest.InputType input)
        {
            WhoAmIRequest.OutputType result = new WhoAmIRequest.OutputType();
            result.UserIsAnonymous = WspContext.User == null;
            if (WspContext.User != null)
            {
                result.UserEmailAddress = WspContext.User.Login;
                result.UserLogin = WspContext.User.Login;
                result.UserName = WspContext.User.DisplayName;
            }

            return result;
        }