doc-exports/docs/obs/perms-cfg/obs_40_0009.html
zhangyue 32b9354795 OBS PERMS DOC
Reviewed-by: Sabelnikov, Dmitriy <dmitriy.sabelnikov@t-systems.com>
Reviewed-by: Hasko, Vladimir <vladimir.hasko@t-systems.com>
Co-authored-by: zhangyue <zhangyue164@huawei.com>
Co-committed-by: zhangyue <zhangyue164@huawei.com>
2023-04-18 07:48:10 +00:00

22 lines
4.1 KiB
HTML

<a name="obs_40_0009"></a><a name="obs_40_0009"></a>
<h1 class="topictitle1">Accessing OBS Using a Temporary URL</h1>
<div id="body1588766432188"><p id="obs_40_0009__p8235152911353">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.</p>
<div class="section" id="obs_40_0009__section19994292017"><h4 class="sectiontitle">Sharing Objects</h4><p id="obs_40_0009__p8060118">You can share objects (files or folders) stored in OBS with all users within a specified period.</p>
<p id="obs_40_0009__p485730113312"><strong id="obs_40_0009__b317316469135">Sharing a file</strong></p>
<p id="obs_40_0009__p728652492213">All URLs generated during file sharing are temporary and remain valid for a limited period of time.</p>
<p id="obs_40_0009__p23269357438">A temporary URL uses V4 temporarily authorized requests. The following is a temporary URL sample:</p>
<pre class="screen" id="obs_40_0009__screen732623584313">https://oss.<em id="obs_40_0009__i77546494">regionid</em>.example.region.com/<em id="obs_40_0009__i1717434918">bucketname</em>/<em id="obs_40_0009__i1877416498">objectname</em>?<span style="color:#FF0000;">X-Amz-Algorithm</span>=<em id="obs_40_0009__i1071048494">xxx</em>&amp;<span style="color:#FF0000;">X-Amz-Credential</span>=<em id="obs_40_0009__i11717411494">xxx</em>&amp;<span style="color:#FF0000;">X-Amz-Date</span>=<em id="obs_40_0009__i07047498">xxx</em>&amp;<span style="color:#FF0000;">X-Amz-Expires</span>=900&amp;<span style="color:#FF0000;">X-Amz-Signature</span>=<em id="obs_40_0009__i8713464915">xxx</em>&amp;<span style="color:#FF0000;">X-Amz-SignedHeaders</span>=<em id="obs_40_0009__i1671148498">xxx</em>&amp;<span style="color:#FF0000;">response-content-disposition</span>=<em id="obs_40_0009__i9714484913">xxx</em></pre>
<p id="obs_40_0009__p78796553521">For details about the temporary authentication and parameters, see <a href="https://docs.otc.t-systems.com/en-us/api_obs/obs/en-us_topic_0125560420.html" target="_blank" rel="noopener noreferrer">V4 Temporarily Authorized Request</a> in the <em id="obs_40_0009__i188166914813">Object Storage Service API Reference</em>. A temporary URL also contains the <strong id="obs_40_0009__b1455482495">response-content-disposition</strong> parameter that defines whether an object is directly downloaded or previewed in a browser when it is accessed. This is determined by the browser based on the <strong id="obs_40_0009__b16555621918">Content-Type</strong> of the shared object.</p>
<p id="obs_40_0009__p52403316294">After you share an object by choosing <strong id="obs_40_0009__b10272191912013">More</strong> &gt; <strong id="obs_40_0009__b1727220197208">Copy Object URL</strong> 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 <strong id="obs_40_0009__b17360142022216">Copy Object URL</strong>, OBS will obtain the authentication information again to generate a new sharing URL whose validity period is reset.</p>
</div>
<div class="section" id="obs_40_0009__section2995192554816"><h4 class="sectiontitle">Limitations and Constraints</h4><ul id="obs_40_0009__ul109951125124812"><li id="obs_40_0009__li799542515487">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 href="https://docs.otc.t-systems.com/usermanual/obs/en-us_topic_0045853745.html" target="_blank" rel="noopener noreferrer">a bucket policy or an object policy</a>.</li><li id="obs_40_0009__li1862383053711">Only buckets 3.0 support file and folder sharing. You can view the bucket version in the <strong id="obs_40_0009__b769213043717">Basic Information</strong> area on the <strong id="obs_40_0009__b176922023714">Overview</strong> page of a bucket.</li><li id="obs_40_0009__li1068453183718">To share a cold object, restore it first.</li></ul>
</div>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="obs_40_0006.html">Access Requests</a></div>
</div>
</div>