Documentation
¶
Overview ¶
Package copysource parses the S3 X-Amz-Copy-Source header value shared by CopyObject, UploadPartCopy, and the policy engine's authorization check (which needs the source bucket/key before the handler runs). Kept as its own small package, with no dependency on either the HTTP handler or the policy package, so both can import it without a cycle.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Parse ¶
Parse extracts bucket and key from an X-Amz-Copy-Source header value. Accepts both "/bucket/key" and "bucket/key" forms. The value is percent-decoded (clients URL-encode the source key when it contains spaces or other special characters), and any trailing "?versionId=..." query component is stripped — DirIO doesn't support object versioning yet, so the version is ignored rather than becoming part of the key.
Types ¶
This section is empty.