public AuthenticationContextProxy(string authority, bool validateAuthority, TokenCacheType tokenCacheType)
 {
     CommandProxy.AddCommand(new AuthenticationContextCommand(
                                 CommandType.CreateContextAVT,
                                 new CommandArguments {
         Authority = authority, ValidateAuthority = validateAuthority, TokenCacheType = tokenCacheType
     }));
 }
        public AuthenticationContextProxy(string authority, bool validateAuthority, TokenCacheType tokenCacheType)
        {
            TokenCache tokenCache = null;
            if (tokenCacheType == TokenCacheType.InMemory)
            {
                tokenCache = new TokenCache();
            }

            this.context = new AuthenticationContext(authority, validateAuthority, tokenCache);
            this.context.CorrelationId = new Guid(FixedCorrelationId);
        }
Пример #3
0
        public AuthenticationContextProxy(string authority, bool validateAuthority, TokenCacheType tokenCacheType)
        {
            TokenCache tokenCache = null;

            if (tokenCacheType == TokenCacheType.InMemory)
            {
                tokenCache = new TokenCache();
            }

            this.context = new AuthenticationContext(authority, validateAuthority, tokenCache);
            this.context.CorrelationId = new Guid(FixedCorrelationId);
        }
        public AuthenticationContextProxy(string authority, bool validateAuthority, TokenCacheType tokenCacheType)
        {
            TokenCache tokenCache = null;
            if (tokenCacheType == TokenCacheType.InMemory)
            {
                tokenCache = new TokenCache();
            }

            try
            {
                this.context = CreateAsync(authority, validateAuthority, tokenCache, new Guid(FixedCorrelationId)).Result;
            }
            catch (AggregateException ae)
            {
                throw ae.InnerExceptions[0];
            }
        }
Пример #5
0
        public AuthenticationContextProxy(string authority, bool validateAuthority, TokenCacheType tokenCacheType)
        {
            TokenCache tokenCache = null;

            if (tokenCacheType == TokenCacheType.InMemory)
            {
                tokenCache = new TokenCache();
            }

            try
            {
                this.context = CreateAsync(authority, validateAuthority, tokenCache, new Guid(FixedCorrelationId)).Result;
            }
            catch (AggregateException ae)
            {
                throw ae.InnerExceptions[0];
            }
        }
 public AuthenticationContextProxy(string authority, bool validateAuthority, TokenCacheType tokenCacheType)
 {
     CommandProxy.AddCommand(new AuthenticationContextCommand(
         CommandType.CreateContextAVT,
         new CommandArguments { Authority = authority, ValidateAuthority = validateAuthority, TokenCacheType = tokenCacheType }));
 }