mirror of
https://github.com/fofolee/uTools-Manuals.git
synced 2025-07-08 10:46:28 +08:00
252 lines
12 KiB
HTML
252 lines
12 KiB
HTML
<div class="header">
|
||
<div class="subTitle">
|
||
compact1, compact2, compact3
|
||
</div>
|
||
<div class="subTitle">
|
||
javax.security.auth
|
||
</div>
|
||
<h2 class="title" title="Class AuthPermission">Class AuthPermission</h2>
|
||
</div><div class="contentContainer">
|
||
<ul class="inheritance">
|
||
<li><a href="../../../java/lang/Object.html" title="class in java.lang">java.lang.Object</a></li>
|
||
<li>
|
||
<ul class="inheritance">
|
||
<li><a href="../../../java/security/Permission.html" title="class in java.security">java.security.Permission</a></li>
|
||
<li>
|
||
<ul class="inheritance">
|
||
<li><a href="../../../java/security/BasicPermission.html" title="class in java.security">java.security.BasicPermission</a></li>
|
||
<li>
|
||
<ul class="inheritance">
|
||
<li>javax.security.auth.AuthPermission</li>
|
||
</ul> </li>
|
||
</ul> </li>
|
||
</ul> </li>
|
||
</ul>
|
||
<div class="description">
|
||
<ul class="blockList">
|
||
<li class="blockList">
|
||
<dl>
|
||
<dt>
|
||
All Implemented Interfaces:
|
||
</dt>
|
||
<dd>
|
||
<span><a href="../../../java/io/Serializable.html" title="java.io中的接口">Serializable</a> , <a href="../../../java/security/Guard.html" title="java.security中的接口">Guard</a></span>
|
||
</dd>
|
||
</dl>
|
||
<hr/> <br/> <pre>public final class <span class="typeNameLabel">AuthPermission</span>
|
||
extends <a href="../../../java/security/BasicPermission.html" title="class in java.security">BasicPermission</a></pre>
|
||
<div class="block">
|
||
<span>此类用于验证权限。</span>
|
||
<span>AuthPermission包含一个名称(也称为“目标名称”),但没有操作列表;</span>
|
||
<span>你有指定的权限,或者你没有。</span>
|
||
<p> <span>目标名称是安全配置参数的名称(见下文)。</span> <span>目前,AuthPermission对象用于保护对Policy,Subject,LoginContext和Configuration对象的访问。</span> </p>
|
||
<p> <span>身份验证权限的可能目标名称为:</span> </p>
|
||
<pre> <span>doAs - allow the caller to invoke the
|
||
<code> Subject.doAs</code> methods.
|
||
|
||
doAsPrivileged - allow the caller to invoke the
|
||
<code> Subject.doAsPrivileged</code> methods.
|
||
|
||
getSubject - allow for the retrieval of the
|
||
Subject(s) associated with the
|
||
current Thread.
|
||
|
||
getSubjectFromDomainCombiner - allow for the retrieval of the
|
||
Subject associated with the
|
||
a <code> SubjectDomainCombiner</code>.
|
||
|
||
setReadOnly - allow the caller to set a Subject
|
||
to be read-only.
|
||
|
||
modifyPrincipals - allow the caller to modify the <code> Set</code>
|
||
of Principals associated with a
|
||
<code> Subject</code>
|
||
|
||
modifyPublicCredentials - allow the caller to modify the
|
||
<code> Set</code> of public credentials
|
||
associated with a <code> Subject</code>
|
||
|
||
modifyPrivateCredentials - allow the caller to modify the
|
||
<code> Set</code> of private credentials
|
||
associated with a <code> Subject</code>
|
||
|
||
refreshCredential - allow code to invoke the <code> refresh</code>
|
||
method on a credential which implements
|
||
the <code> Refreshable</code> interface.
|
||
|
||
destroyCredential - allow code to invoke the <code> destroy</code>
|
||
method on a credential <code> object</code>
|
||
which implements the <code> Destroyable</code>
|
||
interface.
|
||
|
||
createLoginContext.{name} - allow code to instantiate a
|
||
<code> LoginContext</code> with the
|
||
specified <i>name</i>. <i>name</i>
|
||
is used as the index into the installed login
|
||
<code> Configuration</code>
|
||
(that returned by
|
||
<code> Configuration.getConfiguration()</code>).
|
||
<i>name</i> can be wildcarded (set to '*')
|
||
to allow for any name.
|
||
|
||
getLoginConfiguration - allow for the retrieval of the system-wide
|
||
login Configuration.
|
||
|
||
createLoginConfiguration.{type} - allow code to obtain a Configuration
|
||
object via
|
||
<code> Configuration.getInstance</code>.
|
||
|
||
setLoginConfiguration - allow for the setting of the system-wide
|
||
login Configuration.
|
||
|
||
refreshLoginConfiguration - allow for the refreshing of the system-wide
|
||
login Configuration.</span> </pre>
|
||
<p> <span>以下目标名称已被弃用,赞成<code>createLoginContext.{name}</code> 。</span> </p>
|
||
<pre> <span>createLoginContext - allow code to instantiate a
|
||
<code> LoginContext</code>.</span> </pre>
|
||
<p> <span><code>javax.security.auth.Policy</code>已被弃用赞成<code>java.security.Policy</code> 。</span> <span>因此,以下目标名称也已被弃用:</span> </p>
|
||
<pre> <span>getPolicy - allow the caller to retrieve the system-wide
|
||
Subject-based access control policy.
|
||
|
||
setPolicy - allow the caller to set the system-wide
|
||
Subject-based access control policy.
|
||
|
||
refreshPolicy - allow the caller to refresh the system-wide
|
||
Subject-based access control policy.</span> </pre>
|
||
</div>
|
||
<dl>
|
||
<dt>
|
||
<span class="seeLabel">另请参见:</span>
|
||
</dt>
|
||
<dd>
|
||
<a href="../../../serialized-form.html#javax.security.auth.AuthPermission">Serialized Form</a>
|
||
</dd>
|
||
</dl> </li>
|
||
</ul>
|
||
</div>
|
||
<div class="summary">
|
||
<ul class="blockList">
|
||
<li class="blockList">
|
||
<!-- ======== CONSTRUCTOR SUMMARY ======== -->
|
||
<ul class="blockList">
|
||
<li class="blockList"><a name="constructor.summary">
|
||
<!-- --> </a> <h3>构造方法摘要</h3>
|
||
<table border="0" cellpadding="3" cellspacing="0" class="memberSummary" summary="Constructor Summary table, listing constructors, and an explanation">
|
||
<caption>
|
||
<span>构造方法</span>
|
||
<span class="tabEnd"> </span>
|
||
</caption>
|
||
<tbody>
|
||
<tr>
|
||
<th class="colOne" scope="col">Constructor and Description</th>
|
||
</tr>
|
||
<tr class="altColor">
|
||
<td class="colOne"><code><span class="memberNameLink"><a href="../../../javax/security/auth/AuthPermission.html#AuthPermission-java.lang.String-">AuthPermission</a></span>(<a href="../../../java/lang/String.html" title="class in java.lang">String</a> name)</code>
|
||
<div class="block">
|
||
创建一个具有指定名称的新AuthPermission。
|
||
</div> </td>
|
||
</tr>
|
||
<tr class="rowColor">
|
||
<td class="colOne"><code><span class="memberNameLink"><a href="../../../javax/security/auth/AuthPermission.html#AuthPermission-java.lang.String-java.lang.String-">AuthPermission</a></span>(<a href="../../../java/lang/String.html" title="class in java.lang">String</a> name, <a href="../../../java/lang/String.html" title="class in java.lang">String</a> actions)</code>
|
||
<div class="block">
|
||
创建一个具有指定名称的新AuthPermission对象。
|
||
</div> </td>
|
||
</tr>
|
||
</tbody>
|
||
</table> </li>
|
||
</ul>
|
||
<!-- ========== METHOD SUMMARY =========== -->
|
||
<ul class="blockList">
|
||
<li class="blockList"><a name="method.summary">
|
||
<!-- --> </a> <h3>方法摘要</h3>
|
||
<ul class="blockList">
|
||
<li class="blockList"><a name="methods.inherited.from.class.java.security.BasicPermission">
|
||
<!-- --> </a> <h3>Methods inherited from class java.security.<a href="../../../java/security/BasicPermission.html" title="class in java.security">BasicPermission</a></h3> <code><a href="../../../java/security/BasicPermission.html#equals-java.lang.Object-">equals</a>, <a href="../../../java/security/BasicPermission.html#getActions--">getActions</a>, <a href="../../../java/security/BasicPermission.html#hashCode--">hashCode</a>, <a href="../../../java/security/BasicPermission.html#implies-java.security.Permission-">implies</a>, <a href="../../../java/security/BasicPermission.html#newPermissionCollection--">newPermissionCollection</a></code></li>
|
||
</ul>
|
||
<ul class="blockList">
|
||
<li class="blockList"><a name="methods.inherited.from.class.java.security.Permission">
|
||
<!-- --> </a> <h3>Methods inherited from class java.security.<a href="../../../java/security/Permission.html" title="class in java.security">Permission</a></h3> <code><a href="../../../java/security/Permission.html#checkGuard-java.lang.Object-">checkGuard</a>, <a href="../../../java/security/Permission.html#getName--">getName</a>, <a href="../../../java/security/Permission.html#toString--">toString</a></code></li>
|
||
</ul>
|
||
<ul class="blockList">
|
||
<li class="blockList"><a name="methods.inherited.from.class.java.lang.Object">
|
||
<!-- --> </a> <h3>Methods inherited from class java.lang.<a href="../../../java/lang/Object.html" title="class in java.lang">Object</a></h3> <code><a href="../../../java/lang/Object.html#clone--">clone</a>, <a href="../../../java/lang/Object.html#finalize--">finalize</a>, <a href="../../../java/lang/Object.html#getClass--">getClass</a>, <a href="../../../java/lang/Object.html#notify--">notify</a>, <a href="../../../java/lang/Object.html#notifyAll--">notifyAll</a>, <a href="../../../java/lang/Object.html#wait--">wait</a>, <a href="../../../java/lang/Object.html#wait-long-">wait</a>, <a href="../../../java/lang/Object.html#wait-long-int-">wait</a></code></li>
|
||
</ul> </li>
|
||
</ul> </li>
|
||
</ul>
|
||
</div>
|
||
<div class="details">
|
||
<ul class="blockList">
|
||
<li class="blockList">
|
||
<!-- ========= CONSTRUCTOR DETAIL ======== -->
|
||
<ul class="blockList">
|
||
<li class="blockList"><a name="constructor.detail">
|
||
<!-- --> </a> <h3>构造方法详细信息</h3> <a name="AuthPermission-java.lang.String-">
|
||
<!-- --> </a>
|
||
<ul class="blockList">
|
||
<li class="blockList"> <h4>AuthPermission</h4> <pre>public AuthPermission(<a href="../../../java/lang/String.html" title="class in java.lang">String</a> name)</pre>
|
||
<div class="block">
|
||
<span>创建一个具有指定名称的新AuthPermission。</span>
|
||
<span>该名称是AuthPermission的符号名称。</span>
|
||
<p></p>
|
||
</div>
|
||
<dl>
|
||
<dt>
|
||
<span class="paramLabel">参数</span>
|
||
</dt>
|
||
<dd>
|
||
<code>name</code> -
|
||
<code>name</code>的名称
|
||
</dd>
|
||
<dt>
|
||
<span class="throwsLabel">异常</span>
|
||
</dt>
|
||
<dd>
|
||
<code><a href="../../../java/lang/NullPointerException.html" title="class in java.lang">NullPointerException</a></code> - 如果
|
||
<code>name</code>是
|
||
<code>null</code> 。
|
||
</dd>
|
||
<dd>
|
||
<code><a href="../../../java/lang/IllegalArgumentException.html" title="class in java.lang">IllegalArgumentException</a></code> - 如果
|
||
<code>name</code>为空。
|
||
</dd>
|
||
</dl> </li>
|
||
</ul> <a name="AuthPermission-java.lang.String-java.lang.String-">
|
||
<!-- --> </a>
|
||
<ul class="blockListLast">
|
||
<li class="blockList"> <h4>AuthPermission</h4> <pre>public AuthPermission(<a href="../../../java/lang/String.html" title="class in java.lang">String</a> name,
|
||
<a href="../../../java/lang/String.html" title="class in java.lang">String</a> actions)</pre>
|
||
<div class="block">
|
||
<span>创建一个具有指定名称的新AuthPermission对象。</span>
|
||
<span>该名称是AuthPermission的符号名称,并且操作String当前未使用,应为null。</span>
|
||
<p></p>
|
||
</div>
|
||
<dl>
|
||
<dt>
|
||
<span class="paramLabel">参数</span>
|
||
</dt>
|
||
<dd>
|
||
<code>name</code> -
|
||
<code>name</code>的名称
|
||
<p></p>
|
||
</dd>
|
||
<dd>
|
||
<code>actions</code> - 应为null。
|
||
</dd>
|
||
<dt>
|
||
<span class="throwsLabel">异常</span>
|
||
</dt>
|
||
<dd>
|
||
<code><a href="../../../java/lang/NullPointerException.html" title="class in java.lang">NullPointerException</a></code> - 如果
|
||
<code>name</code>是
|
||
<code>null</code> 。
|
||
</dd>
|
||
<dd>
|
||
<code><a href="../../../java/lang/IllegalArgumentException.html" title="class in java.lang">IllegalArgumentException</a></code> - 如果
|
||
<code>name</code>为空。
|
||
</dd>
|
||
</dl> </li>
|
||
</ul> </li>
|
||
</ul> </li>
|
||
</ul>
|
||
</div>
|
||
</div> |