ArcGIS Runtime SDK for iOS: AGSAuthenticationChallenge.h Source File
ArcGIS Runtime SDK for iOS  100.15
AGSAuthenticationChallenge.h
Go to the documentation of this file.
1 /*
2  COPYRIGHT 2022 ESRI
3 
4  All rights reserved under the copyright laws of the United States
5  and applicable international laws, treaties, and conventions.
6 
7  This material is licensed for use under the Esri Master License
8  Agreement (MLA), and is bound by the terms of that agreement.
9  You may redistribute and use this code without modification,
10  provided you adhere to the terms of the MLA and include this
11  copyright notice.
12 
13  See use restrictions at http://www.esri.com/legal/pdfs/mla_e204_e300/english
14 
15  For additional information, contact:
16  Environmental Systems Research Institute, Inc.
17  Attn: Contracts and Legal Services Department
18  380 New York Street
19  Redlands, California, 92373
20  USA
21 
22  email: contracts@esri.com
23  */
24  //Required for Globals API doc
26 
27 #import <Foundation/Foundation.h>
28 #import <ArcGIS/AGSRemoteResource.h>
29 
30 
31 
36 typedef NS_ENUM(NSInteger, AGSAuthenticationChallengeType) {
42 };
43 
44 @class AGSCredential;
45 
59 @interface AGSAuthenticationChallenge : NSObject
60 
64 @property (nonatomic, assign, readonly) NSUInteger failureCount;
65 
69 @property (nullable, nonatomic, weak, readonly) id<AGSRemoteResource> remoteResource;
70 
75 @property (nullable, nonatomic, strong, readonly) AGSCredential *proposedCredential;
76 
80 @property (nullable, nonatomic, strong, readonly) NSURLProtectionSpace *protectionSpace;
81 
86 @property (nonatomic, strong, readonly) NSError *error;
87 
92 @property (nonatomic, copy, readonly) NSURLRequest *request;
93 
98 @property (nonatomic, copy, readonly) NSString *authenticatingHost;
99 
103 @property (nullable, nonatomic, strong, readonly) NSURL *portalURL;
104 
108 @property (nonatomic, assign, readonly) AGSAuthenticationChallengeType type;
109 
115 -(void)continueWithCredential:(nullable AGSCredential*)credential;
116 
121 -(void)trustHostAndContinue;
122 
126 -(void)cancel;
127 
137 
141 - (BOOL)isRemoteResourceFederatedWithPortalURL:(NSURL*)portalURL;
142 
143 @end
144 
145 
AGSAuthenticationChallengeType
Definition: AGSAuthenticationChallenge.h:36
@ AGSAuthenticationChallengeTypeUnknown
Definition: AGSAuthenticationChallenge.h:41
@ AGSAuthenticationChallengeTypeOAuth
Definition: AGSAuthenticationChallenge.h:38
@ AGSAuthenticationChallengeTypeUntrustedHost
Definition: AGSAuthenticationChallenge.h:40
@ AGSAuthenticationChallengeTypeUsernamePassword
Definition: AGSAuthenticationChallenge.h:37
@ AGSAuthenticationChallengeTypeClientCertificate
Definition: AGSAuthenticationChallenge.h:39
Represents an authentication challenge when accessing secured resources.
Definition: AGSAuthenticationChallenge.h:60
NSString * authenticatingHost
Definition: AGSAuthenticationChallenge.h:98
NSURL * portalURL
Definition: AGSAuthenticationChallenge.h:103
NSUInteger failureCount
Definition: AGSAuthenticationChallenge.h:64
NSURLRequest * request
Definition: AGSAuthenticationChallenge.h:92
id< AGSRemoteResource > remoteResource
Definition: AGSAuthenticationChallenge.h:69
NSError * error
Definition: AGSAuthenticationChallenge.h:86
NSURLProtectionSpace * protectionSpace
Definition: AGSAuthenticationChallenge.h:80
AGSCredential * proposedCredential
Definition: AGSAuthenticationChallenge.h:75
AGSAuthenticationChallengeType type
Definition: AGSAuthenticationChallenge.h:108
Represents an credential to access a secured resource.
Definition: AGSCredential.h:52