VaultSharp.Core.VaultApiException : {"errors":["invalid role ID"]}

See original GitHub issue

Hello,

We are trying to use key-value secrets like this -

var authMethod = new AppRoleAuthMethodInfo("...",
                "....");

            var vaultClientSettings =
                new VaultClientSettings("...", authMethod);

            var vaultClient = new VaultClient(vaultClientSettings);

            var value = new Dictionary<string, object> { { "key1", "val1" }, { "key2", 2 } };
            await vaultClient.V1.Secrets.KeyValue.V1.WriteSecretAsync("secretPath", value);

            var kv1Secret = await vaultClient.V1.Secrets.KeyValue.V1.ReadSecretAsync("secretPath");
            var dataDictionary = kv1Secret.Data;

And We get VaultSharp.Core.VaultApiException : {“errors”:[“invalid role ID”]} with above. Please help

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:5 (1 by maintainers)

github_iconTop GitHub Comments

1reaction
Nitin5acccommented, Jan 23, 2020

Thanks!!! It works after adding correct roleID

0reactions
rajanadarcommented, Apr 22, 2020

thanks @Marusyk for the help.

Read more comments on GitHub >

github_iconTop Results From Across the Web

asp.net core - Hashicorp Vaultsharp permission denied error
Your mountpoint is jumbled up with the key-path. Separate them out as follows: var vaultSecrets = vaultClient.V1.Secrets.KeyValue.V1 .
Read more >
A brand new website interface for an even better experience!
VaultSharp.Core.VaultApiException : {"errors":["invalid role ID"]}
Read more >
Using HashiCorp Vault C# client with .NET Core
Demonstrate how to retrieve secrets from HashiCorp Vault in .NET Core application using a Vault C# Client.
Read more >
AppRole - Auth Methods | Vault
When authenticating against this auth method's login endpoint, the RoleID is a required argument (via role_id ) at all times. By default, RoleIDs...
Read more >
VaultSharp 1.13.0.1
Whenever you initialize VaultSharp with an appropriate AuthMethod, VaultSharp fetches the vault token on the first authenticated Vault operation requested by ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found