Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Max versions in the UI does not load default from secrets/config #8656

Closed
dmattia opened this issue Apr 1, 2020 · 10 comments · Fixed by #22394
Closed

Max versions in the UI does not load default from secrets/config #8656

dmattia opened this issue Apr 1, 2020 · 10 comments · Fixed by #22394
Assignees
Labels
bug Used to indicate a potential bug ui

Comments

@dmattia
Copy link

dmattia commented Apr 1, 2020

Describe the bug
Even with max_versions set to some non-default value, like 100, the Vault UI still brings up 10 as the max number of versions for all secrets (new and existing)

To Reproduce

  1. Write out to <kv_mount_path>/config that max_versions is 100. In terraform, this is:
resource vault_mount kv {
  path        = var.path
  type        = "kv"
  description = var.description
  options = {
    version      = "2"
  }
}

resource vault_generic_endpoint version_count {
  path = "${vault_mount.kv.path}/config"
  data_json = jsonencode({
    cas_required = false
    max_versions = 100
  })
}
  1. Validate that max_versions is globally set: vault read kv/config shows max_versions being 100
  2. Go into Vault UI, and create a new secret. You will see that "Maximum Number of Versions" is set to 10

Expected behavior
I would expect the "Maximum Number of Versions" in the UI to default to what I have set as max_versions in the global config.

Environment:

  • Vault Server Version (retrieve with vault status): 1.3.2
  • Vault CLI Version (retrieve with vault version): 1.3.3
  • Server Operating System/Architecture: linux
@tyrannosaurus-becks tyrannosaurus-becks added bug Used to indicate a potential bug ui waiting-for-response labels Apr 1, 2020
@tyrannosaurus-becks
Copy link
Contributor

Hi! Thanks for the report!

Can you please confirm that the issue lies within Vault and not Terraform by doing a:

$ vault read ${vault_mount.kv.path}/config

and confirming that you're seeing the max_versions set to 100 there?

@dmattia
Copy link
Author

dmattia commented Apr 3, 2020

Sure thing! It does show that max_versions is set to 100

@tyrannosaurus-becks
Copy link
Contributor

Thank you!

@aphorise
Copy link
Contributor

aphorise commented Sep 3, 2022

Hey @dmattia - I'd like to close this request as I feel it was already fixed at the time and is no longer releavnt.

But before doing so I'd like to check if you agree or have retested the fix since you raised it?

@aphorise
Copy link
Contributor

aphorise commented Sep 9, 2022

Closing due to no response. Please re-open if relevant.

@aphorise aphorise closed this as completed Sep 9, 2022
@michaeljs1990
Copy link
Contributor

This issue still exists.

@heatherezell
Copy link
Contributor

This issue still exists.

Thank you, I will re-open and ask the UI team to take a look!

@heatherezell heatherezell reopened this May 23, 2023
@michaeljs1990
Copy link
Contributor

This issue still exists.

Thank you, I will re-open and ask the UI team to take a look!

Thanks! Not a huge issue unless you create secrets via the UI but it did leave me confused for a bit yesterday when I was trying to validate a change and it kept showing me 10 😆

@aphorise
Copy link
Contributor

aphorise commented Jun 6, 2023

I think I now understand the issue thanks to comments from @michaeljs1990

The default UI view for secret creation that's with the value of 10 has no effect unless other options in that sub-panel are set or if the value is adjusted manually (to read 10).

Default 10 value

However in recent versions (1.11 on wards) all data related to versions and other properties reside in Metadata that are correctly reading current values.

Metadata

If I've misunderstood anything then I'd welcome a screen capture of the issue.

@michaeljs1990
Copy link
Contributor

Correct that was exactly the issue I was running into.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Used to indicate a potential bug ui
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants