mirror of
https://github.com/pgsty/minio.git
synced 2026-07-23 22:16:15 +03:00
crypto: implement Stringer for S3 and SSEC (#6216)
This commit adds a `fmt.Stringer` implementation for SSE-S3 and SSE-C. The string representation is the domain used for object key sealing. See: `ObjectKey.Seal(...)` and `ObjectKey.Unseal(...)`
This commit is contained in:
committed by
kannappanr
parent
b16e33bcf5
commit
a7c9058375
@@ -65,6 +65,14 @@ const (
|
||||
InsecureSealAlgorithm = "DARE-SHA256"
|
||||
)
|
||||
|
||||
// String returns the SSE domain as string. For SSE-S3 the
|
||||
// domain is "SSE-S3".
|
||||
func (s3) String() string { return "SSE-S3" }
|
||||
|
||||
// String returns the SSE domain as string. For SSE-C the
|
||||
// domain is "SSE-C".
|
||||
func (ssec) String() string { return "SSE-C" }
|
||||
|
||||
// EncryptSinglePart encrypts an io.Reader which must be the
|
||||
// the body of a single-part PUT request.
|
||||
func EncryptSinglePart(r io.Reader, key ObjectKey) io.Reader {
|
||||
|
||||
Reference in New Issue
Block a user