forked from docs/doc-exports
Reviewed-by: Sabelnikov, Dmitriy <dmitriy.sabelnikov@t-systems.com> Co-authored-by: zhangyue <zhangyue164@huawei.com> Co-committed-by: zhangyue <zhangyue164@huawei.com>
63 lines
8.1 KiB
HTML
63 lines
8.1 KiB
HTML
<a name="obs_40_0029"></a><a name="obs_40_0029"></a>
|
|
|
|
<h1 class="topictitle1">Granting Other Accounts Specific Permissions for Specific Objects</h1>
|
|
<div id="body1588765301379"><div class="section" id="obs_40_0029__section43491717165116"><h4 class="sectiontitle">Scenario</h4><p id="obs_40_0029__p1829466339">This section describes how to grant other accounts the permissions to download an object from a bucket.</p>
|
|
<p id="obs_40_0029__p131221236151420">To grant other permissions, select required actions from <strong id="obs_40_0029__b96795611191">Action Name</strong> in the bucket policy. For details about the actions supported by OBS, see <a href="obs_40_0041.html#obs_40_0041__en-us_topic_0118394684_section1623516525350">Action/NotAction</a>.</p>
|
|
<p id="obs_40_0029__p3431154410448">For details about how to grant permissions to an IAM user, see <a href="obs_40_0027.html">Granting IAM Users Under an Account the Access to a Bucket and the Resources in It</a>.</p>
|
|
</div>
|
|
<div class="section" id="obs_40_0029__section106520378518"><h4 class="sectiontitle">Recommended Configuration</h4><p id="obs_40_0029__p103657437515">Use bucket policies to grant permissions to other accounts.</p>
|
|
</div>
|
|
<div class="section" id="obs_40_0029__section786219432319"><h4 class="sectiontitle">Precautions</h4><p id="obs_40_0029__p4883191595712">After configuration, they can download objects using APIs. However, if they download objects using OBS Console or OBS Browser+, a message will be displayed indicating that they do not have required permissions.</p>
|
|
<p id="obs_40_0029__p3603656113417">When they log in to OBS Console or OBS Browser+, APIs (such as <strong id="obs_40_0029__b16431925203612">ListAllMyBuckets</strong> and <strong id="obs_40_0029__b06441825183618">ListBucket</strong>) are called to load the bucket list and object list and some other APIs will also be called on other pages, but their permissions do not cover those APIs. In such case, the message is displayed.</p>
|
|
</div>
|
|
<div class="section" id="obs_40_0029__section18368164564"><h4 class="sectiontitle">Procedure</h4><ol id="obs_40_0029__ol170633855216"><li id="obs_40_0029__li724955124912"><span>In the navigation pane of OBS Console, choose <strong id="obs_40_0029__b1591195314582">Object Storage</strong>.</span></li><li id="obs_40_0029__li32491951194912"><span>In the bucket list, click the bucket name you want to go to the <strong id="obs_40_0029__b51079271323834">Overview</strong> page.</span></li><li id="obs_40_0029__li5249145194918"><span>In the navigation pane, choose <strong id="obs_40_0029__b11470415329058">Permissions</strong>.</span></li><li id="obs_40_0029__li1568715376490"><span>On the <strong id="obs_40_0029__b99977311234">Bucket Policies</strong> page, click <strong id="obs_40_0029__b499853111312">Create Bucket Policy</strong> under <strong id="obs_40_0029__b109980314316">Custom Bucket Policies</strong>.</span></li><li id="obs_40_0029__li3552175452220"><span>Configure a bucket policy.</span><p><div class="fignone" id="obs_40_0029__fig0845620144418"><span class="figcap"><b>Figure 1 </b>Configuring a bucket policy</span><br><span><img id="obs_40_0029__image1984812015445" src="en-us_image_0000001386185594.png"></span></div>
|
|
|
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="obs_40_0029__table374341792315" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameters for creating a bucket policy</caption><thead align="left"><tr id="obs_40_0029__row27504174239"><th align="left" class="cellrowborder" valign="top" width="23.599999999999998%" id="mcps1.3.4.2.5.2.2.2.3.1.1"><p id="obs_40_0029__p107559176234"><strong id="obs_40_0029__b118020145734854">Parameter</strong></p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="76.4%" id="mcps1.3.4.2.5.2.2.2.3.1.2"><p id="obs_40_0029__p1976317170239"><strong id="obs_40_0029__b195497138634854">Description</strong></p>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody><tr id="obs_40_0029__row1246385816164"><td class="cellrowborder" valign="top" width="23.599999999999998%" headers="mcps1.3.4.2.5.2.2.2.3.1.1 "><p id="obs_40_0029__p04631584161">Policy Mode</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="76.4%" headers="mcps1.3.4.2.5.2.2.2.3.1.2 "><p id="obs_40_0029__p19463175819166">Select <strong id="obs_40_0029__b107684298334854">Customized</strong>.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="obs_40_0029__row169652214311"><td class="cellrowborder" valign="top" width="23.599999999999998%" headers="mcps1.3.4.2.5.2.2.2.3.1.1 "><p id="obs_40_0029__p136964228313">Effect</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="76.4%" headers="mcps1.3.4.2.5.2.2.2.3.1.2 "><p id="obs_40_0029__p106961221034">Select <strong id="obs_40_0029__b16179744334854">Allow</strong>.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="obs_40_0029__row8783617122317"><td class="cellrowborder" valign="top" width="23.599999999999998%" headers="mcps1.3.4.2.5.2.2.2.3.1.1 "><p id="obs_40_0029__p478519172231">Principal</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="76.4%" headers="mcps1.3.4.2.5.2.2.2.3.1.2 "><ul id="obs_40_0029__ul1341145419174"><li id="obs_40_0029__li6417546174">Select <strong id="obs_40_0029__b26863363234854">Include</strong> > <strong id="obs_40_0029__b157525699634854">Other account</strong>.</li><li id="obs_40_0029__li106259549386"><strong id="obs_40_0029__b1928953110544">Account ID</strong>: Enter the ID of the account which you want to grant permissions to. You can obtain it from the <strong id="obs_40_0029__b112897315540">My Credentials</strong> page of the account.</li><li id="obs_40_0029__li1530533711817"><strong id="obs_40_0029__b164461950622">User ID</strong>: Enter the account ID. You can obtain it from the <strong id="obs_40_0029__b2044617509214">My Credentials</strong> page of the account.<div class="note" id="obs_40_0029__note8498202544611"><span class="notetitle"> NOTE: </span><div class="notebody"><p id="obs_40_0029__p15498192594615">In this example, permissions are granted to an account, excluding any IAM user under the account. Therefore, the user ID is the same as the account ID.</p>
|
|
</div></div>
|
|
</li></ul>
|
|
</td>
|
|
</tr>
|
|
<tr id="obs_40_0029__row081741752319"><td class="cellrowborder" valign="top" width="23.599999999999998%" headers="mcps1.3.4.2.5.2.2.2.3.1.1 "><p id="obs_40_0029__p15821617102320">Resources</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="76.4%" headers="mcps1.3.4.2.5.2.2.2.3.1.2 "><ul id="obs_40_0029__ul15636626173616"><li id="obs_40_0029__li1963652623617">Choose <strong id="obs_40_0029__b118248141834854">Include</strong> > <strong id="obs_40_0029__b39214308434854">Specific resources</strong>.</li><li id="obs_40_0029__li1338101719199"><strong id="obs_40_0029__b70432035734854">Resource Name</strong>: Enter the object or the set of objects that will be accessed.<p id="obs_40_0029__p12830717162315">For one object, enter <em id="obs_40_0029__i383261716237">object name</em>.</p>
|
|
<p id="obs_40_0029__p68341917112319">For a set of objects, enter <em id="obs_40_0029__i17317115934854">object name prefix + *, * + object name suffix, or *</em>.</p>
|
|
</li></ul>
|
|
</td>
|
|
</tr>
|
|
<tr id="obs_40_0029__row3951641158"><td class="cellrowborder" valign="top" width="23.599999999999998%" headers="mcps1.3.4.2.5.2.2.2.3.1.1 "><p id="obs_40_0029__p10952134114519">Actions</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="76.4%" headers="mcps1.3.4.2.5.2.2.2.3.1.2 "><ul id="obs_40_0029__ul1663065817513"><li id="obs_40_0029__li1563025812519"><strong id="obs_40_0029__b193520098934854">Include</strong></li><li id="obs_40_0029__li10224301466">Action Name: Select <strong id="obs_40_0029__b132905828534854">GetObject</strong>.</li></ul>
|
|
<p id="obs_40_0029__p175400381720">To configure other permissions, select the corresponding actions. For details about the actions supported by OBS, see <a href="obs_40_0041.html#obs_40_0041__en-us_topic_0118394684_section1623516525350">Action/NotAction</a>.</p>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</p></li><li id="obs_40_0029__li4406132611218"><span>Click <strong id="obs_40_0029__b164104890034854">OK</strong>.</span></li></ol>
|
|
</div>
|
|
</div>
|
|
<div>
|
|
<div class="familylinks">
|
|
<div class="parentlink"><strong>Parent topic:</strong> <a href="obs_40_0024.html">Granting Permissions to Other Accounts</a></div>
|
|
</div>
|
|
</div>
|
|
|