Unverified Commit 34aa9a07 authored by Nick Cabatoff's avatar Nick Cabatoff Committed by GitHub
Browse files

Fix regression in returning empty value for approle cidrlist. (#13235) (#13251)

parent 3b8ac395
Branches unavailable v1.9.6 v1.9.5 v1.9.4 v1.9.3 v1.9.2 v1.9.1
No related merge requests found
Showing with 8 additions and 0 deletions
+8 -0
......@@ -118,6 +118,11 @@ func decodeSecretIDStorageEntry(entry *logical.StorageEntry) (*secretIDStorageEn
}
cleanup := func(in []string) []string {
if len(in) == 0 {
// Don't change unnecessarily, if it was empty list leave as empty list
// instead of making it nil.
return in
}
var out []string
for _, s := range in {
out = append(out, parseip.TrimLeadingZeroesCIDR(s))
......
```release-note:bug
auth/approle: Fix regression where unset cidrlist is returned as nil instead of zero-length array.
```
\ No newline at end of file
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment