From c47721aa4dc8bce3e929a5e84cc8e97e9d006094 Mon Sep 17 00:00:00 2001 From: Matt Sicker Date: Fri, 28 Jan 2022 13:46:28 -0600 Subject: [PATCH] fix(gate/web): Add explicit name property to AccountDefinition This fixes an authorization check error where Jackson knows how to handle the `name` property of an account definition, but SpEL does not see the property. Now the PostFilter annotation should work equivalently to the same filter check in Clouddriver. --- .../gate/services/internal/ClouddriverService.java | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/gate-core/src/main/java/com/netflix/spinnaker/gate/services/internal/ClouddriverService.java b/gate-core/src/main/java/com/netflix/spinnaker/gate/services/internal/ClouddriverService.java index 27de803b95..742be81edb 100644 --- a/gate-core/src/main/java/com/netflix/spinnaker/gate/services/internal/ClouddriverService.java +++ b/gate-core/src/main/java/com/netflix/spinnaker/gate/services/internal/ClouddriverService.java @@ -524,6 +524,7 @@ public void setCloudProvider(String cloudProvider) { class AccountDefinition { private final Map details = new HashMap<>(); private String type; + private String name; @JsonAnyGetter public Map details() { @@ -544,5 +545,13 @@ public String getType() { public void setType(String type) { this.type = type; } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } } }