Files
versitygw/tests/integration
niksis02 1b9fedb7e6 fix: enforce object lock on browser-based POST object uploads
`POSTObject` wrote directly to the backend without the `CheckObjectAccess` object lock check that `PutObject`, `CopyObject` and `CompleteMultipartUpload` perform. In a versioning-disabled bucket, a browser-based `POST` could therefore silently overwrite an object protected by a legal hold, a `COMPLIANCE` retention or a `GOVERNANCE` retention. S3 has no such gap: it allows object lock only on versioned buckets, where an overwrite creates a new version.

`POSTObject` now calls `auth.CheckObjectAccess` with `BypassOverwrite` just before writing to the backend, matching `PutObject`. A legal hold or `COMPLIANCE` retention always blocks the overwrite. A `GOVERNANCE` retention blocks it unless the caller, root included, has an explicit `s3:BypassGovernanceRetention` grant. Versioning-enabled buckets skip the check because the upload creates a new version.
2026-09-23 18:13:25 +04:00
..
2026-03-10 09:47:37 -07:00
2026-05-21 23:49:34 +04:00
2026-05-21 23:49:34 +04:00
2026-05-21 23:49:34 +04:00
2026-08-25 01:03:22 +04:00
2026-05-21 23:49:34 +04:00
2026-05-21 23:49:34 +04:00
2026-05-21 23:49:34 +04:00
2026-08-29 12:06:50 +05:00
2026-06-15 14:48:31 +04:00