mirror of
https://gitee.com/dcren/openiddict-documentation.git
synced 2025-07-16 07:59:46 +08:00
Update the documentation pages
This commit is contained in:
parent
d15e1c07b1
commit
d52dd13c07
@ -228,7 +228,40 @@ if (await manager.FindByClientIdAsync("console") == null)
|
|||||||
<p>Scope permissions limit the scopes (standard or custom) a client application is allowed to use.</p>
|
<p>Scope permissions limit the scopes (standard or custom) a client application is allowed to use.</p>
|
||||||
<blockquote><p>The <code>openid</code> and <code>offline_access</code> scopes are special-cased by OpenIddict and don't require explicit permissions.</p>
|
<blockquote><p>The <code>openid</code> and <code>offline_access</code> scopes are special-cased by OpenIddict and don't require explicit permissions.</p>
|
||||||
</blockquote>
|
</blockquote>
|
||||||
<h3 id="example">Example</h3>
|
<h3 id="supported-permissions">Supported permissions</h3>
|
||||||
|
<table>
|
||||||
|
<thead>
|
||||||
|
<tr>
|
||||||
|
<th style="text-align:center">Scope</th>
|
||||||
|
<th style="text-align:center">Constant</th>
|
||||||
|
</tr>
|
||||||
|
</thead>
|
||||||
|
<tbody>
|
||||||
|
<tr>
|
||||||
|
<td style="text-align:center">address</td>
|
||||||
|
<td style="text-align:center"><code>OpenIddictConstants.Permissions.Scopes.Address</code></td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td style="text-align:center">email</td>
|
||||||
|
<td style="text-align:center"><code>OpenIddictConstants.Permissions.Scopes.Email</code></td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td style="text-align:center">phone</td>
|
||||||
|
<td style="text-align:center"><code>OpenIddictConstants.Permissions.Scopes.Phone</code></td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td style="text-align:center">profile</td>
|
||||||
|
<td style="text-align:center"><code>OpenIddictConstants.Permissions.Scopes.Profile</code></td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td style="text-align:center">roles</td>
|
||||||
|
<td style="text-align:center"><code>OpenIddictConstants.Permissions.Scopes.Roles</code></td>
|
||||||
|
</tr>
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
<p>To add a custom scope permission, you can use the following pattern:</p>
|
||||||
|
<pre><code class="lang-csharp">OpenIddictConstants.Permissions.Prefixes.Scope + "custom_scope_name"
|
||||||
|
</code></pre><h3 id="example">Example</h3>
|
||||||
<p>In the following sample, the <code>angular</code> client is allowed to request the <code>address</code>,
|
<p>In the following sample, the <code>angular</code> client is allowed to request the <code>address</code>,
|
||||||
<code>profile</code> and <code>marketing_api</code> scopes: any other scope will result in an error being returned.</p>
|
<code>profile</code> and <code>marketing_api</code> scopes: any other scope will result in an error being returned.</p>
|
||||||
<pre><code class="lang-csharp">if (await manager.FindByClientIdAsync("angular") == null)
|
<pre><code class="lang-csharp">if (await manager.FindByClientIdAsync("angular") == null)
|
||||||
|
@ -9,7 +9,7 @@
|
|||||||
"output": {
|
"output": {
|
||||||
".html": {
|
".html": {
|
||||||
"relative_path": "configuration/application-permissions.html",
|
"relative_path": "configuration/application-permissions.html",
|
||||||
"hash": "bKUoTWvuQdArH/6SAvdCnw=="
|
"hash": "LOmSHldwDeJLrrKM8vU/xA=="
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"is_incremental": false,
|
"is_incremental": false,
|
||||||
@ -232,18 +232,18 @@
|
|||||||
"details": "Processor RestApiDocumentProcessor cannot suppport incremental build because the processor doesn't implement ISupportIncrementalDocumentProcessor interface.",
|
"details": "Processor RestApiDocumentProcessor cannot suppport incremental build because the processor doesn't implement ISupportIncrementalDocumentProcessor interface.",
|
||||||
"incrementalPhase": "build"
|
"incrementalPhase": "build"
|
||||||
},
|
},
|
||||||
"TocDocumentProcessor": {
|
"ResourceDocumentProcessor": {
|
||||||
"can_incremental": false,
|
"can_incremental": false,
|
||||||
"details": "Processor TocDocumentProcessor cannot suppport incremental build because the processor doesn't implement ISupportIncrementalDocumentProcessor interface.",
|
"details": "Processor ResourceDocumentProcessor cannot suppport incremental build because the processor doesn't implement ISupportIncrementalDocumentProcessor interface.",
|
||||||
"incrementalPhase": "build"
|
"incrementalPhase": "build"
|
||||||
},
|
},
|
||||||
"ConceptualDocumentProcessor": {
|
"ConceptualDocumentProcessor": {
|
||||||
"can_incremental": false,
|
"can_incremental": false,
|
||||||
"incrementalPhase": "build"
|
"incrementalPhase": "build"
|
||||||
},
|
},
|
||||||
"ResourceDocumentProcessor": {
|
"TocDocumentProcessor": {
|
||||||
"can_incremental": false,
|
"can_incremental": false,
|
||||||
"details": "Processor ResourceDocumentProcessor cannot suppport incremental build because the processor doesn't implement ISupportIncrementalDocumentProcessor interface.",
|
"details": "Processor TocDocumentProcessor cannot suppport incremental build because the processor doesn't implement ISupportIncrementalDocumentProcessor interface.",
|
||||||
"incrementalPhase": "build"
|
"incrementalPhase": "build"
|
||||||
},
|
},
|
||||||
"ManagedReferenceDocumentProcessor": {
|
"ManagedReferenceDocumentProcessor": {
|
||||||
|
Loading…
Reference in New Issue
Block a user