Describe the bug
With S3, the following error is returned:
HTTP/1.1 400 Bad Request
x-amz-request-id: N67XHR38PFR9AYT6
x-amz-id-2: P/dBJv7ingZGgDm6Ni7kUlx6GA9trStxXd9i4eSl7xm+pJTO8Tam9stX4KizfSZwhIcvFVDiKFQ=
Content-Type: application/xml
Transfer-Encoding: chunked
Date: Tue, 09 Jun 2026 21:58:35 GMT
Connection: close
Server: AmazonS3
<?xml version="1.0" encoding="UTF-8"?>
<Error><Code>InvalidArgument</Code><Message>A version-id marker cannot be specified without a key marker.</Message><ArgumentName>version-id-marker</ArgumentName><ArgumentValue>null</ArgumentValue><RequestId>N67XHR38PFR9AYT6</RequestId><HostId>P/dBJv7ingZGgDm6Ni7kUlx6GA9trStxXd9i4eSl7xm+pJTO8Tam9stX4KizfSZwhIcvFVDiKFQ=</HostId></Error>
versitygw just returns a 200 when a version-id-marker is provided without a key-marker.
To Reproduce
- Start versitygw, e.g.:
./versitygw --access=AKIA**** --secret=******** --region=us-east-1 --cert /Users/lukemccrone/devel/versitygw/tester/cert.pem --key /Users/lukemccrone/devel/versitygw/tester/versitygw.pem posix --versioning-dir /tmp/versioning /tmp/gw-tester
- Create a bucket, e.g.:
curl -ks -w %{http_code} -X PUT https://localhost:7070/versity-gwtest-bucket-one-1-28cd6537-5394-4934-aa91-514a6e0a38c -H Authorization: AWS4-HMAC-SHA256 Credential=AKIA6****/20260609/us-east-1/s3/aws4_request,SignedHeaders=host;x-amz-content-sha256;x-amz-date,Signature=0b1ae3263de358ec77efe1a2ac2f69ed45cb77375bd50fe55d84cdd54a364d1f -H host: localhost:7070 -H x-amz-content-sha256: UNSIGNED-PAYLOAD -H x-amz-date: 20260609T224815Z -o /Users/lukemccrone/devel/versitygw/tester/files/test-file-B62392C1-3B2B-43C5-92E3-63A13FF5B64D
- Add two objects
- Attempt to query with
version-id-marker w/o key-marker, e.g.: curl -ksi https://localhost:7070/versity-gwtest-bucket-one-1-28cd6537-5394-4934-aa91-514a6e0a38c?max-keys=1&version-id-marker=null&versions= -H Authorization: AWS4-HMAC-SHA256 Credential=AKIA6****/20260609/us-east-1/s3/aws4_request,SignedHeaders=host;x-amz-content-sha256;x-amz-date,Signature=ac4d6c0d57509a0da402ce48997bc85fbc569b5cc83af283cf2f666db842128d -H host: localhost:7070 -H x-amz-content-sha256: e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855 -H x-amz-date: 20260609T224816Z -o /Users/lukemccrone/devel/versitygw/tester/files/test-file-4AF52FD6-6518-43EE-9012-D079378AA3AC
Expected behavior
The error above is returned.
Server Version
Version : v1.5.0
Build : cce34bf9
BuildTime: 2026-06-09_10:52:16PM
Darwin Lukes-MacBook-Pro.local 24.6.0 Darwin Kernel Version 24.6.0: Tue Apr 21 20:16:56 PDT 2026; root:xnu-11417.140.69.710.16~1/RELEASE_ARM64_T6030 arm64
Describe the bug
With S3, the following error is returned:
versitygw just returns a 200 when a
version-id-markeris provided without akey-marker.To Reproduce
./versitygw --access=AKIA**** --secret=******** --region=us-east-1 --cert /Users/lukemccrone/devel/versitygw/tester/cert.pem --key /Users/lukemccrone/devel/versitygw/tester/versitygw.pem posix --versioning-dir /tmp/versioning /tmp/gw-testercurl -ks -w %{http_code} -X PUT https://localhost:7070/versity-gwtest-bucket-one-1-28cd6537-5394-4934-aa91-514a6e0a38c -H Authorization: AWS4-HMAC-SHA256 Credential=AKIA6****/20260609/us-east-1/s3/aws4_request,SignedHeaders=host;x-amz-content-sha256;x-amz-date,Signature=0b1ae3263de358ec77efe1a2ac2f69ed45cb77375bd50fe55d84cdd54a364d1f -H host: localhost:7070 -H x-amz-content-sha256: UNSIGNED-PAYLOAD -H x-amz-date: 20260609T224815Z -o /Users/lukemccrone/devel/versitygw/tester/files/test-file-B62392C1-3B2B-43C5-92E3-63A13FF5B64Dversion-id-markerw/okey-marker, e.g.:curl -ksi https://localhost:7070/versity-gwtest-bucket-one-1-28cd6537-5394-4934-aa91-514a6e0a38c?max-keys=1&version-id-marker=null&versions= -H Authorization: AWS4-HMAC-SHA256 Credential=AKIA6****/20260609/us-east-1/s3/aws4_request,SignedHeaders=host;x-amz-content-sha256;x-amz-date,Signature=ac4d6c0d57509a0da402ce48997bc85fbc569b5cc83af283cf2f666db842128d -H host: localhost:7070 -H x-amz-content-sha256: e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855 -H x-amz-date: 20260609T224816Z -o /Users/lukemccrone/devel/versitygw/tester/files/test-file-4AF52FD6-6518-43EE-9012-D079378AA3ACExpected behavior
The error above is returned.
Server Version
Version : v1.5.0
Build : cce34bf9
BuildTime: 2026-06-09_10:52:16PM
Darwin Lukes-MacBook-Pro.local 24.6.0 Darwin Kernel Version 24.6.0: Tue Apr 21 20:16:56 PDT 2026; root:xnu-11417.140.69.710.16~1/RELEASE_ARM64_T6030 arm64