vaultr (version 1.0.2)

vault_client_auth: Vault Authentication Configuration

Description

Interact with vault's authentication backends.

Arguments

Methods

backends

Return a character vector of supported authentication backends. If a backend x is present, then you can access it with $auth$x. Note that vault calls these authentication methods but we use backends here to differentiate with R6 methods. Note that these are backends supported by vaultr and not necessarily supported by the server - the server may not have enabled some of these backends, and may support other authentication backends not directly supported by vaultr. See the $list() method to query what the server supports. Usage:

backends()

list

List authentication backends supported by the vault server, including information about where these backends are mounted. Usage:

list(detailed = FALSE)

Arguments:

  • detailed: Logical, indicating if detailed information should be returned

enable

Enable an authentication backend in the vault server. Usage:

enable(type, description = NULL, local = FALSE, path = NULL)

Arguments:

  • type: The type of authentication backend (e.g., userpass, github)

  • description: Human-friendly description of the backend; will be returned by $list()

  • local: Specifies if the auth method is local only. Local auth methods are not replicated nor (if a secondary) removed by replication.

  • path: Specifies the path in which to enable the auth method. Defaults to be the same as type.

disable

Disable an active authentication backend. Usage:

disable(path)

Arguments:

  • path: The path of the authentication backend to disable.

token

Interact with vault's token authentication. See vault_client_token for more information.

github

Interact with vault's GitHub authentication. See vault_client_auth_github for more information.

userpass

Interact with vault's username/password based authentication. See vault_client_auth_userpass for more information.

Examples

Run this code
# NOT RUN {
server <- vaultr::vault_test_server(if_disabled = message)
if (!is.null(server)) {
  client <- server$client()

  # List configured authentication backends
  client$auth$list()

  # cleanup
  server$kill()
}
# }

Run the code above in your browser using DataCamp Workspace