Get Object Lock Configuration (Flex WORM only)
Gets the Object Lock configuration for a bucket.
Request Syntax
GET /{bucket}?object-lock HTTP/1.1
Host: msdps3.server:8443
Request Parameters
Bucket
The bucket for which you want to retrieve Object Lock configuration.
Required: Yes
Type: String
Response Syntax
HTTP/1.1 200
<?xml version="1.0" encoding="UTF-8"?>
<ObjectLockConfiguration>
<ObjectLockEnabled>string</ObjectLockEnabled>
<Rule>
<DefaultRetention>
<Days>integer</Days>
<Mode>string</Mode>
<Years>integer</Years>
</DefaultRetention>
</Rule>
</ObjectLockConfiguration>
Response body
ObjectLockConfiguration
Root level tag for the ObjectLockConfiguration parameters.
Required: Yes
ObjectLockEnabled
Indicates whether this bucket has an Object Lock configuration enabled. Enable ObjectLockEnabled when you apply ObjectLockConfiguration to a bucket.
Valid Values: Enabled
Required: No
Type: String
Rule
Specifies the Object Lock rule for the specified objects. Enable the rule when you apply ObjectLockConfiguration to a bucket.
The settings require both a mode and a period. The period can be either Days or Years. You cannot specify Days and Years at the same time.
Required: No
Type: ObjectLockRule data type
Possible Error Response
Success
HTTP status code 200.
AccessDenied
Access Denied.
HTTP status code 403.
NoSuchBucket
The specified bucket does not exist.
HTTP status code 404.
S3srvExtObjectLockConfigurationNotFound
Object Lock configuration does not exist for this bucket.
HTTP status code 404.
InvalidRequest
The error may occur for some reasons. For details, please refer the error messages.
HTTP status code 400.