UsernamePasswordChallenge

class UsernamePasswordChallenge(val url: String, onUsernamePasswordReceived: (username: String, password: String) -> Unit, val cause: Throwable? = null, onCancel: () -> Unit)

Represents an authentication challenge requiring a username and password.

Since

200.8.0

Constructors

Link copied to clipboard
constructor(url: String, onUsernamePasswordReceived: (username: String, password: String) -> Unit, cause: Throwable? = null, onCancel: () -> Unit)

Properties

Link copied to clipboard
val cause: Throwable? = null

the exception that caused this challenge

Link copied to clipboard
Link copied to clipboard
val url: String

the name of the server that initiated this challenge

Functions

Link copied to clipboard
fun cancel()

Cancels the challenge.. Note that either continueWithCredentials or cancel can only be called once on a given UsernamePasswordChallenge object; further calls will have no effect.

Link copied to clipboard
fun continueWithCredentials(username: String, password: String)

Completes the challenge with the credentials. Note that either continueWithCredentials or cancel can only be called once on a given UsernamePasswordChallenge object; further calls will have no effect.