Accessing OBS Using a Temporary URL
You can use a temporary URL to access OBS and perform operations such as bucket creation or object upload and download. This section describes how to share objects using a temporary URL.
Sharing Objects
You can share objects (files or folders) stored in OBS with all users within a specified period.
Sharing a file
All URLs generated during file sharing are temporary and remain valid for a limited period of time.
A temporary URL uses V4 temporarily authorized requests. The following is a temporary URL sample:
https://oss.regionid.prod-cloud-ocb.orange-business.com/bucketname/objectname?X-Amz-Algorithm=xxx&X-Amz-Credential=xxx&X-Amz-Date=xxx&X-Amz-Expires=900&X-Amz-Signature=xxx&X-Amz-SignedHeaders=xxx&response-content-disposition=xxx
After you share an object by choosing More > Copy Object URL on OBS Console, the system will generate a URL that contains the temporary authentication information, valid for 900 seconds since its generation by default. Each time you click Copy Object URL, OBS will obtain the authentication information again to generate a new sharing URL whose validity period is reset.
Sharing a folder
Folder sharing is temporary and has a validity period. You need to prepare a six-digit extraction code before sharing a folder. After the sharing task is created, OBS aggregates the download links of all objects in the folder to a static website that is hosted by a public OBS bucket. Then anyone who has the created temporary URL and access code can access the static website and download the shared files.
Limitations and Constraints
- The validity period of files shared through OBS Console is fixed at 900s. If you want a file to be accessed permanently, you can configure a bucket policy to grant the public read permission on the file to anonymous users.
- A folder shared through OBS Console is valid for one minute to 18 hours. If you need a longer validity period for a shared folder, use the client tool OBS Browser+ that allows a validity period of up to one year. If you want a folder to be accessed permanently, you can configure a bucket policy to grant the public read permission on the folder to anonymous users.
- Only buckets 3.0 support file and folder sharing. You can view the bucket version in the Basic Information area on the Overview page of a bucket.
- To share a cold object, restore it first.
Configuration Procedure
For details about how to share files, see Temporarily Sharing Objects with Anonymous Users.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot