Up
Authors
- Generated by fedor
-
- Declared in:
- Foundation/NSURLAuthenticationChallenge.h
Availability: MacOS-X 10.2.0, Base 1.13.0
Class to represent an
authentication challenge and indicate when the
challenge is complete.
Instance Variables
Method summary
- (
NSError*)
error;
Availability: MacOS-X 10.2.0, Base 1.13.0
Returns the error with which the reciver was
initialised or nil
if it was not
initialised with an error.
The error may
indicate the nature of the authentication failure.
- (
NSURLResponse*)
failureResponse;
Availability: MacOS-X 10.2.0, Base 1.13.0
Returns the response with which the receiver was
initialised.
This response contains the
authentication failure corresponding to this
challenge object.
If there was no failure
or response, returns nil
.
- (id)
initWithProtectionSpace: (
NSURLProtectionSpace*)space
proposedCredential: (
NSURLCredential*)credential
previousFailureCount: (
NSInteger)previousFailureCount
failureResponse: (
NSURLResponse*)response
error: (
NSError*)error
sender: (id<
NSURLAuthenticationChallengeSender>)sender;
Availability: MacOS-X 10.2.0, Base 1.13.0
Returns the receiver initialised in the specified
protection space and with the
specified credential. The
previousFailureCount says how many
requests have failed the challenge and
response provide information about the
last failure (which caused this challenge to be
created).
The error provides
information about the authentication failure
and the sender is the object to receive
callbacks.
- (
NSInteger)
previousFailureCount;
Availability: MacOS-X 10.2.0, Base 1.13.0
Returns the count of failed authentication
attempts.
- (
NSURLCredential*)
proposedCredential;
Availability: MacOS-X 10.2.0, Base 1.13.0
Returns a proposed credential to answer the
challenge.
If there is no credential
available, this returns nil
.
The credential may come from storage or from the URL
itsself.
- (
NSURLProtectionSpace*)
protectionSpace;
Availability: MacOS-X 10.2.0, Base 1.13.0
Returns the protection space needing
authentication.
- (id<
NSURLAuthenticationChallengeSender>)
sender;
Availability: MacOS-X 10.2.0, Base 1.13.0
Returns the sender of the challenge... the object
to which callbacks should be made while processing the
challenge.
Instance Variables for NSURLAuthenticationChallenge Class
@protected void* _NSURLAuthenticationChallengeInternal;
Availability: MacOS-X 10.2.0, Base 1.13.0
Warning the underscore at the start of the
name of this instance variable indicates that, even
though it is not technically private, it is
intended for internal use within the package, and
you should not use the variable in other code.
- Declared in:
- Foundation/NSURLAuthenticationChallenge.h
- Conforms to:
- NSObject
Availability: MacOS-X 10.2.0, Base 1.13.0
A challenge sender (usually an NSURLProtocol subclass
handling a connection/download) provides these
methods to permit a client to control authentication.
Method summary
- (void)
cancelAuthenticationChallenge: (
NSURLAuthenticationChallenge*)challenge;
Availability: MacOS-X 10.2.0, Base 1.13.0
Cancels the authenticatiopn challenge,
ensuring that the load operation will fail to
retrieve data, completing with only the response
headers containing the challenge having
been read from the server.
- (void)
continueWithoutCredentialForAuthenticationChallenge: (
NSURLAuthenticationChallenge*)challenge;
Availability: MacOS-X 10.2.0, Base 1.13.0
Tells the sender to continue the load without
providing a new credential for it to use... if
the challenge already had a proposed
credential, the sender may elect to use it.
- (void)
useCredential: (
NSURLCredential*)credential
forAuthenticationChallenge: (
NSURLAuthenticationChallenge*)challenge;
Availability: MacOS-X 10.2.0, Base 1.13.0
Tells the sender to continue the load using the new
credential provided by this method.
Up