Show / Hide Table of Contents

Method RemoveAndRevokeAllCredentialsAsync

RemoveAndRevokeAllCredentialsAsync()

Removes all credentials from the cache and revokes tokens if appropriate.

Declaration
public Task RemoveAndRevokeAllCredentialsAsync()
Returns
Type Description
System.Threading.Tasks.Task

A System.Threading.Tasks.Task representing the asynchronous removal and revoking of credential.

Remarks

If one or more token credentials could not be revoked, the task will complete with an System.AggregateException. Credentials that could not be revoked will remain in Credentials. You can examine the errors and attempt to revoke again, or use RemoveAllCredentials() to "forget" them without revoking. Note that removing a token credential without revoking may be a security risk, because the token will remain valid and could potentially be misused before it expires.

Exceptions
Type Condition
System.InvalidOperationException

A loadable credential persistence is assigned but not yet loaded.

Applies to

Platforms and versions
TargetVersions
.NET Standard 2.0100.6 - 200.8
.NET100.13 - 200.8
.NET Windows100.13 - 200.8
.NET Android200.0 - 200.8
.NET iOS200.0 - 200.8
.NET Framework100.6 - 200.8
Xamarin.Android100.6 - 100.15
Xamarin.iOS100.6 - 100.15
UWP100.6 - 200.8
In This Article
Back to top Copyright © 2022 Esri.