Fix shadowed trustedroot (#178) #296
Annotations
7 errors and 1 warning
Verify codegen
Process completed with exit code 1.
|
Verify codegen:
third_party/VENDOR-LICENSE/github.com/hashicorp/vault/api/sys_seal.go#L0
Please run ./hack/update-codegen.sh.
diff --git a/third_party/VENDOR-LICENSE/github.com/hashicorp/vault/api/sys_seal.go b/third_party/VENDOR-LICENSE/github.com/hashicorp/vault/api/sys_seal.go
index 62002496..d5548aef 100644
--- a/third_party/VENDOR-LICENSE/github.com/hashicorp/vault/api/sys_seal.go
+++ b/third_party/VENDOR-LICENSE/github.com/hashicorp/vault/api/sys_seal.go
@@ -96,24 +96,25 @@ func sealStatusRequestWithContext(ctx context.Context, c *Sys, r *Request) (*Sea
}
type SealStatusResponse struct {
- Type string `json:"type"`
- Initialized bool `json:"initialized"`
- Sealed bool `json:"sealed"`
- T int `json:"t"`
- N int `json:"n"`
- Progress int `json:"progress"`
- Nonce string `json:"nonce"`
- Version string `json:"version"`
- BuildDate string `json:"build_date"`
- Migration bool `json:"migration"`
- ClusterName string `json:"cluster_name,omitempty"`
- ClusterID string `json:"cluster_id,omitempty"`
- RecoverySeal bool `json:"recovery_seal"`
- RecoverySealType string `json:"recovery_seal_type,omitempty"`
- StorageType string `json:"storage_type,omitempty"`
- HCPLinkStatus string `json:"hcp_link_status,omitempty"`
- HCPLinkResourceID string `json:"hcp_link_resource_ID,omitempty"`
- Warnings []string `json:"warnings,omitempty"`
+ Type string `json:"type"`
+ Initialized bool `json:"initialized"`
+ Sealed bool `json:"sealed"`
+ T int `json:"t"`
+ N int `json:"n"`
+ Progress int `json:"progress"`
+ Nonce string `json:"nonce"`
+ Version string `json:"version"`
+ BuildDate string `json:"build_date"`
+ Migration bool `json:"migration"`
+ ClusterName string `json:"cluster_name,omitempty"`
+ ClusterID string `json:"cluster_id,omitempty"`
+ RecoverySeal bool `json:"recovery_seal"`
+ RecoverySealType string `json:"recovery_seal_type,omitempty"`
+ StorageType string `json:"storage_type,omitempty"`
+ HCPLinkStatus string `json:"hcp_link_status,omitempty"`
+ HCPLinkResourceID string `json:"hcp_link_resource_ID,omitempty"`
+ RemovedFromCluster *bool `json:"removed_from_cluster,omitempty"`
+ Warnings []string `json:"warnings,omitempty"`
}
type UnsealOpts struct {
|
Verify codegen:
third_party/VENDOR-LICENSE/github.com/hashicorp/vault/api/sys_mounts.go#L0
Please run ./hack/update-codegen.sh.
diff --git a/third_party/VENDOR-LICENSE/github.com/hashicorp/vault/api/sys_mounts.go b/third_party/VENDOR-LICENSE/github.com/hashicorp/vault/api/sys_mounts.go
index 64529986..7775c67f 100644
--- a/third_party/VENDOR-LICENSE/github.com/hashicorp/vault/api/sys_mounts.go
+++ b/third_party/VENDOR-LICENSE/github.com/hashicorp/vault/api/sys_mounts.go
@@ -290,23 +290,23 @@ type MountInput struct {
}
type MountConfigInput struct {
- Options map[string]string `json:"options" mapstructure:"options"`
- DefaultLeaseTTL string `json:"default_lease_ttl" mapstructure:"default_lease_ttl"`
- Description *string `json:"description,omitempty" mapstructure:"description"`
- MaxLeaseTTL string `json:"max_lease_ttl" mapstructure:"max_lease_ttl"`
- ForceNoCache bool `json:"force_no_cache" mapstructure:"force_no_cache"`
- AuditNonHMACRequestKeys []string `json:"audit_non_hmac_request_keys,omitempty" mapstructure:"audit_non_hmac_request_keys"`
- AuditNonHMACResponseKeys []string `json:"audit_non_hmac_response_keys,omitempty" mapstructure:"audit_non_hmac_response_keys"`
- ListingVisibility string `json:"listing_visibility,omitempty" mapstructure:"listing_visibility"`
- PassthroughRequestHeaders []string `json:"passthrough_request_headers,omitempty" mapstructure:"passthrough_request_headers"`
- AllowedResponseHeaders []string `json:"allowed_response_headers,omitempty" mapstructure:"allowed_response_headers"`
- TokenType string `json:"token_type,omitempty" mapstructure:"token_type"`
- AllowedManagedKeys []string `json:"allowed_managed_keys,omitempty" mapstructure:"allowed_managed_keys"`
- PluginVersion string `json:"plugin_version,omitempty"`
- UserLockoutConfig *UserLockoutConfigInput `json:"user_lockout_config,omitempty"`
- DelegatedAuthAccessors []string `json:"delegated_auth_accessors,omitempty" mapstructure:"delegated_auth_accessors"`
- IdentityTokenKey string `json:"identity_token_key,omitempty" mapstructure:"identity_token_key"`
-
+ Options map[string]string `json:"options" mapstructure:"options"`
+ DefaultLeaseTTL string `json:"default_lease_ttl" mapstructure:"default_lease_ttl"`
+ Description *string `json:"description,omitempty" mapstructure:"description"`
+ MaxLeaseTTL string `json:"max_lease_ttl" mapstructure:"max_lease_ttl"`
+ ForceNoCache bool `json:"force_no_cache" mapstructure:"force_no_cache"`
+ AuditNonHMACRequestKeys []string `json:"audit_non_hmac_request_keys,omitempty" mapstructure:"audit_non_hmac_request_keys"`
+ AuditNonHMACResponseKeys []string `json:"audit_non_hmac_response_keys,omitempty" mapstructure:"audit_non_hmac_response_keys"`
+ ListingVisibility string `json:"listing_visibility,omitempty" mapstructure:"listing_visibility"`
+ PassthroughRequestHeaders []string `json:"passthrough_request_headers,omitempty" mapstructure:"passthrough_request_headers"`
+ AllowedResponseHeaders []string `json:"allowed_response_headers,omitempty" mapstructure:"allowed_response_headers"`
+ TokenType string `json:"token_type,omitempty" mapstructure:"token_type"`
+ AllowedManagedKeys []string `json:"allowed_managed_keys,omitempty" mapstructure:"allowed_managed_keys"`
+ PluginVersion string `json:"plugin_version,omitempty"`
+ UserLockoutConfig *UserLockoutConfigInput `json:"user_lockout_config,omitempty"`
+ DelegatedAuthAccessors []string `json:"delegated_auth_accessors,omitempty" mapstr
|
Verify codegen:
third_party/VENDOR-LICENSE/github.com/hashicorp/vault/api/sys_health.go#L0
Please run ./hack/update-codegen.sh.
diff --git a/third_party/VENDOR-LICENSE/github.com/hashicorp/vault/api/sys_health.go b/third_party/VENDOR-LICENSE/github.com/hashicorp/vault/api/sys_health.go
index 6868b96d..4379e8e0 100644
--- a/third_party/VENDOR-LICENSE/github.com/hashicorp/vault/api/sys_health.go
+++ b/third_party/VENDOR-LICENSE/github.com/hashicorp/vault/api/sys_health.go
@@ -25,6 +25,8 @@ func (c *Sys) HealthWithContext(ctx context.Context) (*HealthResponse, error) {
r.Params.Add("standbycode", "299")
r.Params.Add("drsecondarycode", "299")
r.Params.Add("performancestandbycode", "299")
+ r.Params.Add("removedcode", "299")
+ r.Params.Add("haunhealthycode", "299")
resp, err := c.c.rawRequestWithContext(ctx, r)
if err != nil {
@@ -38,19 +40,22 @@ func (c *Sys) HealthWithContext(ctx context.Context) (*HealthResponse, error) {
}
type HealthResponse struct {
- Initialized bool `json:"initialized"`
- Sealed bool `json:"sealed"`
- Standby bool `json:"standby"`
- PerformanceStandby bool `json:"performance_standby"`
- ReplicationPerformanceMode string `json:"replication_performance_mode"`
- ReplicationDRMode string `json:"replication_dr_mode"`
- ServerTimeUTC int64 `json:"server_time_utc"`
- Version string `json:"version"`
- ClusterName string `json:"cluster_name,omitempty"`
- ClusterID string `json:"cluster_id,omitempty"`
- LastWAL uint64 `json:"last_wal,omitempty"`
- Enterprise bool `json:"enterprise"`
- EchoDurationMillis int64 `json:"echo_duration_ms"`
- ClockSkewMillis int64 `json:"clock_skew_ms"`
- ReplicationPrimaryCanaryAgeMillis int64 `json:"replication_primary_canary_age_ms"`
+ Initialized bool `json:"initialized"`
+ Sealed bool `json:"sealed"`
+ Standby bool `json:"standby"`
+ PerformanceStandby bool `json:"performance_standby"`
+ ReplicationPerformanceMode string `json:"replication_performance_mode"`
+ ReplicationDRMode string `json:"replication_dr_mode"`
+ ServerTimeUTC int64 `json:"server_time_utc"`
+ Version string `json:"version"`
+ ClusterName string `json:"cluster_name,omitempty"`
+ ClusterID string `json:"cluster_id,omitempty"`
+ LastWAL uint64 `json:"last_wal,omitempty"`
+ Enterprise bool `json:"enterprise"`
+ EchoDurationMillis int64 `json:"echo_duration_ms"`
+ ClockSkewMillis int64 `json:"clock_skew_ms"`
+ ReplicationPrimaryCanaryAgeMillis int64 `json:"replication_primary_canary_age_ms"`
+ RemovedFromCluster *bool `json:"removed_from_cluster,omitempty"`
+ HAConnectionHealthy *bool `json:"ha_connection_healthy,omitempty"`
+ LastRequestForwardingHeartbeatMillis int64 `json:"last_request_forwarding_heartbeat_ms,omitempty"`
}
|
Verify codegen:
third_party/VENDOR-LICENSE/github.com/hashicorp/vault/api/secret.go#L0
Please run ./hack/update-codegen.sh.
diff --git a/third_party/VENDOR-LICENSE/github.com/hashicorp/vault/api/secret.go b/third_party/VENDOR-LICENSE/github.com/hashicorp/vault/api/secret.go
index 7df9f66a..b7165c7c 100644
--- a/third_party/VENDOR-LICENSE/github.com/hashicorp/vault/api/secret.go
+++ b/third_party/VENDOR-LICENSE/github.com/hashicorp/vault/api/secret.go
@@ -6,6 +6,7 @@ package api
import (
"bytes"
"encoding/json"
+ "errors"
"fmt"
"io"
"reflect"
@@ -380,7 +381,7 @@ func ParseSecret(r io.Reader) (*Secret, error) {
if err := json.Unmarshal(errBytes, &errStrArray); err != nil {
return nil, err
}
- return nil, fmt.Errorf(strings.Join(errStrArray, " "))
+ return nil, errors.New(strings.Join(errStrArray, " "))
}
// if any raw data is present in resp.Body, add it to secret
|
Verify codegen:
third_party/VENDOR-LICENSE/github.com/hashicorp/vault/api/output_string.go#L0
Please run ./hack/update-codegen.sh.
diff --git a/third_party/VENDOR-LICENSE/github.com/hashicorp/vault/api/output_string.go b/third_party/VENDOR-LICENSE/github.com/hashicorp/vault/api/output_string.go
index d7777712..dbf37e8b 100644
--- a/third_party/VENDOR-LICENSE/github.com/hashicorp/vault/api/output_string.go
+++ b/third_party/VENDOR-LICENSE/github.com/hashicorp/vault/api/output_string.go
@@ -8,7 +8,7 @@ import (
"net/http"
"strings"
- retryablehttp "github.com/hashicorp/go-retryablehttp"
+ "github.com/hashicorp/go-retryablehttp"
)
const (
@@ -25,6 +25,10 @@ type OutputStringError struct {
finalCurlString string
}
+// Error is here so that we can return this struct as an error from client.rawRequestWithContext(). Note that
+// the ErrOutputStringRequest constant is never actually used and is completely irrelevant to how this all functions.
+// We could've just as easily returned an empty string. What matters is the machinery that happens before then where
+// the curl string is built. So yes, this is confusing, but yes, this is also on purpose, and it is not incorrect.
func (d *OutputStringError) Error() string {
if d.finalCurlString == "" {
cs, err := d.buildCurlString()
|
Verify codegen:
third_party/VENDOR-LICENSE/github.com/hashicorp/vault/api/client.go#L0
Please run ./hack/update-codegen.sh.
diff --git a/third_party/VENDOR-LICENSE/github.com/hashicorp/vault/api/client.go b/third_party/VENDOR-LICENSE/github.com/hashicorp/vault/api/client.go
index 0090321c..d7e61c11 100644
--- a/third_party/VENDOR-LICENSE/github.com/hashicorp/vault/api/client.go
+++ b/third_party/VENDOR-LICENSE/github.com/hashicorp/vault/api/client.go
@@ -1467,6 +1467,12 @@ START:
}
if outputCurlString {
+ // Note that although we're building this up here and returning it as an error object, the Error()
+ // interface method on it only gets called in a context where the actual string returned from that
+ // method is irrelevant, because it gets swallowed by an error buffer that's never output to the user.
+ // That's on purpose, not a bug, because in this case, OutputStringError is not really an _error_, per se.
+ // It's just a way of aborting the control flow so that requests don't actually execute, and instead,
+ // we can detect what's happened back in the CLI machinery and show the actual curl string to the user.
LastOutputStringError = &OutputStringError{
Request: req,
TLSSkipVerify: c.config.HttpClient.Transport.(*http.Transport).TLSClientConfig.InsecureSkipVerify,
|
Verify codegen
Restore cache failed: Dependencies file is not found in /home/runner/work/policy-controller/policy-controller. Supported file pattern: go.sum
|