Bucket encryption checkbox and endpoints for Console (#343)
Co-authored-by: Daniel Valdivia <hola@danielvaldivia.com>
This commit is contained in:
@@ -222,6 +222,101 @@ func init() {
|
||||
}
|
||||
}
|
||||
},
|
||||
"/buckets/{bucket_name}/encryption/disable": {
|
||||
"post": {
|
||||
"tags": [
|
||||
"UserAPI"
|
||||
],
|
||||
"summary": "Disable bucket encryption.",
|
||||
"operationId": "DisableBucketEncryption",
|
||||
"parameters": [
|
||||
{
|
||||
"type": "string",
|
||||
"name": "bucket_name",
|
||||
"in": "path",
|
||||
"required": true
|
||||
}
|
||||
],
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "A successful response."
|
||||
},
|
||||
"default": {
|
||||
"description": "Generic error response.",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/error"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"/buckets/{bucket_name}/encryption/enable": {
|
||||
"post": {
|
||||
"tags": [
|
||||
"UserAPI"
|
||||
],
|
||||
"summary": "Enable bucket encryption.",
|
||||
"operationId": "EnableBucketEncryption",
|
||||
"parameters": [
|
||||
{
|
||||
"type": "string",
|
||||
"name": "bucket_name",
|
||||
"in": "path",
|
||||
"required": true
|
||||
},
|
||||
{
|
||||
"name": "body",
|
||||
"in": "body",
|
||||
"required": true,
|
||||
"schema": {
|
||||
"$ref": "#/definitions/bucketEncryptionRequest"
|
||||
}
|
||||
}
|
||||
],
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "A successful response."
|
||||
},
|
||||
"default": {
|
||||
"description": "Generic error response.",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/error"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"/buckets/{bucket_name}/encryption/info": {
|
||||
"get": {
|
||||
"tags": [
|
||||
"UserAPI"
|
||||
],
|
||||
"summary": "Get bucket encryption information.",
|
||||
"operationId": "GetBucketEncryptionInfo",
|
||||
"parameters": [
|
||||
{
|
||||
"type": "string",
|
||||
"name": "bucket_name",
|
||||
"in": "path",
|
||||
"required": true
|
||||
}
|
||||
],
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "A successful response.",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/bucketEncryptionInfo"
|
||||
}
|
||||
},
|
||||
"default": {
|
||||
"description": "Generic error response.",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/error"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"/buckets/{bucket_name}/events": {
|
||||
"get": {
|
||||
"tags": [
|
||||
@@ -2781,6 +2876,36 @@ func init() {
|
||||
"CUSTOM"
|
||||
]
|
||||
},
|
||||
"bucketEncryptionInfo": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"algorithm": {
|
||||
"type": "string"
|
||||
},
|
||||
"kmsMasterKeyID": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
},
|
||||
"bucketEncryptionRequest": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"encType": {
|
||||
"$ref": "#/definitions/bucketEncryptionType"
|
||||
},
|
||||
"kmsKeyID": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
},
|
||||
"bucketEncryptionType": {
|
||||
"type": "string",
|
||||
"default": "sse-s3",
|
||||
"enum": [
|
||||
"sse-s3",
|
||||
"sse-kms"
|
||||
]
|
||||
},
|
||||
"bucketEventRequest": {
|
||||
"type": "object",
|
||||
"required": [
|
||||
@@ -4902,6 +5027,101 @@ func init() {
|
||||
}
|
||||
}
|
||||
},
|
||||
"/buckets/{bucket_name}/encryption/disable": {
|
||||
"post": {
|
||||
"tags": [
|
||||
"UserAPI"
|
||||
],
|
||||
"summary": "Disable bucket encryption.",
|
||||
"operationId": "DisableBucketEncryption",
|
||||
"parameters": [
|
||||
{
|
||||
"type": "string",
|
||||
"name": "bucket_name",
|
||||
"in": "path",
|
||||
"required": true
|
||||
}
|
||||
],
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "A successful response."
|
||||
},
|
||||
"default": {
|
||||
"description": "Generic error response.",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/error"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"/buckets/{bucket_name}/encryption/enable": {
|
||||
"post": {
|
||||
"tags": [
|
||||
"UserAPI"
|
||||
],
|
||||
"summary": "Enable bucket encryption.",
|
||||
"operationId": "EnableBucketEncryption",
|
||||
"parameters": [
|
||||
{
|
||||
"type": "string",
|
||||
"name": "bucket_name",
|
||||
"in": "path",
|
||||
"required": true
|
||||
},
|
||||
{
|
||||
"name": "body",
|
||||
"in": "body",
|
||||
"required": true,
|
||||
"schema": {
|
||||
"$ref": "#/definitions/bucketEncryptionRequest"
|
||||
}
|
||||
}
|
||||
],
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "A successful response."
|
||||
},
|
||||
"default": {
|
||||
"description": "Generic error response.",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/error"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"/buckets/{bucket_name}/encryption/info": {
|
||||
"get": {
|
||||
"tags": [
|
||||
"UserAPI"
|
||||
],
|
||||
"summary": "Get bucket encryption information.",
|
||||
"operationId": "GetBucketEncryptionInfo",
|
||||
"parameters": [
|
||||
{
|
||||
"type": "string",
|
||||
"name": "bucket_name",
|
||||
"in": "path",
|
||||
"required": true
|
||||
}
|
||||
],
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "A successful response.",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/bucketEncryptionInfo"
|
||||
}
|
||||
},
|
||||
"default": {
|
||||
"description": "Generic error response.",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/error"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"/buckets/{bucket_name}/events": {
|
||||
"get": {
|
||||
"tags": [
|
||||
@@ -7984,6 +8204,36 @@ func init() {
|
||||
"CUSTOM"
|
||||
]
|
||||
},
|
||||
"bucketEncryptionInfo": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"algorithm": {
|
||||
"type": "string"
|
||||
},
|
||||
"kmsMasterKeyID": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
},
|
||||
"bucketEncryptionRequest": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"encType": {
|
||||
"$ref": "#/definitions/bucketEncryptionType"
|
||||
},
|
||||
"kmsKeyID": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
},
|
||||
"bucketEncryptionType": {
|
||||
"type": "string",
|
||||
"default": "sse-s3",
|
||||
"enum": [
|
||||
"sse-s3",
|
||||
"sse-kms"
|
||||
]
|
||||
},
|
||||
"bucketEventRequest": {
|
||||
"type": "object",
|
||||
"required": [
|
||||
|
||||
Reference in New Issue
Block a user