From 04ce17415f25dbf10eba954212c8428ae630df88 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sandro=20J=C3=A4ckel?= Date: Wed, 26 Oct 2022 11:31:22 +0200 Subject: Format with go 1.19 --- capabilities.go | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'capabilities.go') diff --git a/capabilities.go b/capabilities.go index 69d6183..62290d9 100644 --- a/capabilities.go +++ b/capabilities.go @@ -18,14 +18,14 @@ package schwift -//Capabilities describes a subset of the capabilities that Swift can report -//under its /info endpoint. This struct is obtained through the -//Account.Capabilities() method. To query capabilities not represented in this -//struct, see Account.QueryCapabilities(). +// Capabilities describes a subset of the capabilities that Swift can report +// under its /info endpoint. This struct is obtained through the +// Account.Capabilities() method. To query capabilities not represented in this +// struct, see Account.QueryCapabilities(). // -//All direct members of struct Capabilities, except for "Swift", are pointers. -//If any of these is nil, it indicates that the middleware corresponding to -//that field is not available on this server. +// All direct members of struct Capabilities, except for "Swift", are pointers. +// If any of these is nil, it indicates that the middleware corresponding to +// that field is not available on this server. type Capabilities struct { BulkDelete *struct { MaximumDeletesPerRequest uint `json:"max_deletes_per_request"` @@ -82,7 +82,7 @@ type Capabilities struct { } `json:"tempurl"` } -//StoragePolicySpec is a subtype that appears in struct Capabilities. +// StoragePolicySpec is a subtype that appears in struct Capabilities. type StoragePolicySpec struct { Name string `json:"name"` Aliases string `json:"aliases"` -- cgit v1.2.3 From 82de494f495481b5ae016038c7020898a135c8dc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sandro=20J=C3=A4ckel?= Date: Wed, 26 Oct 2022 15:23:24 +0200 Subject: Generate digest preferable with sha2, then sha512 and fallback to insecure sha1 --- capabilities.go | 1 + 1 file changed, 1 insertion(+) (limited to 'capabilities.go') diff --git a/capabilities.go b/capabilities.go index 62290d9..26a3532 100644 --- a/capabilities.go +++ b/capabilities.go @@ -74,6 +74,7 @@ type Capabilities struct { AccountACLs bool `json:"account_acls"` } `json:"tempauth"` TempURL *struct { + AllowedDigests []string `json:"allowed_digests"` IncomingAllowHeaders []string `json:"incoming_allow_headers"` IncomingRemoveHeaders []string `json:"incoming_remove_headers"` Methods []string `json:"methods"` -- cgit v1.2.3