Expand description
Object-storage key normalization helpers.
These helpers keep object keys relative, slash-separated, and safe to join with storage prefixes. They reject path escape attempts while preserving existing prefix placement rules that may matter for S3 bucket policies or migrated objects.
Functionsยง
- join_
key_ prefix - Join a storage prefix and object key without producing duplicate separators.
- normalize_
object_ key - Normalizes an object key and rejects the storage namespace root.
- normalize_
object_ prefix - Normalizes a storage prefix.
- normalize_
relative_ key - Normalize an external object key into a slash-separated relative key.
- strip_
key_ prefix - Strip
prefixfromkeyonly when the prefix matches a complete slash-separated segment.