AuthorizationRule クラスとは? わかりやすく解説

AuthorizationRule クラス

メモ : このクラスは、.NET Framework version 2.0新しく追加されたものです。

セキュリティ設定できるオブジェクトへのアクセス決定します。AccessRule 派生クラスおよび AuditRule 派生クラスは、アクセスおよび監査特化した機能提供します

名前空間: System.Security.AccessControl
アセンブリ: mscorlib (mscorlib.dll 内)
構文構文

Public MustInherit Class
 AuthorizationRule
Dim instance As AuthorizationRule
public abstract class AuthorizationRule
public ref class AuthorizationRule abstract
public abstract class AuthorizationRule
public abstract class AuthorizationRule
継承階層継承階層
System.Object
  System.Security.AccessControl.AuthorizationRule
     System.Security.AccessControl.AccessRule
     System.Security.AccessControl.AuditRule
スレッド セーフスレッド セーフ
この型の public static (Visual Basic では Shared) メンバはすべて、スレッド セーフです。インスタンス メンバ場合は、スレッド セーフであるとは限りません。
プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照
関連項目
AuthorizationRule メンバ
System.Security.AccessControl 名前空間

AuthorizationRule クラス

メモ : このクラスは、.NET Framework version 2.0新しく追加されたものです。

AuthorizationRule クラス使用すると、構成ファイルauthorization セクションプログラムかアクセスして変更できます。このクラス継承できません。

名前空間: System.Web.Configuration
アセンブリ: System.Web (system.web.dll 内)
構文構文

Public NotInheritable Class
 AuthorizationRule
    Inherits ConfigurationElement
Dim instance As AuthorizationRule
public sealed class AuthorizationRule : ConfigurationElement
public ref class AuthorizationRule sealed :
 public ConfigurationElement
public final class AuthorizationRule extends
 ConfigurationElement
public final class AuthorizationRule extends
 ConfigurationElement
解説解説

AuthorizationRule クラス使用すると、構成ファイルauthorization セクションプログラムかアクセスして変更できます

この型は、AuthorizationSection 型、AuthorizationRuleCollection 型、AuthorizationRuleAction 型を含むグループ一部です。

メモメモ

AuthorizationSection は、構成階層任意のレベル構成情報更新できます

使用例使用例

AuthorizationRule使用する方法次のコード例示します

メモメモ

credentials セクション使用する場合は、「ASP.NET認証」に説明されているガイドラインに従う必要がありますスケーラビリティセキュリティ機能高めるため、外部データベース使用してユーザー資格情報保管することをお勧めます。安全な ASP.NET アプリケーション構築する方法詳細については、Microsoft MSDN Web サイト (msdn.microsoft.com) で、「Securing Your ASP.NET Application」や「Building Secure ASP.NET Applications: Authentication, Authorization, and Secure Communication」を参照してください

' Create an authorization rule object.
  Dim action As AuthorizationRuleAction = _
  AuthorizationRuleAction.Deny
  Dim authorizationRule = _
  New System.Web.Configuration.AuthorizationRule(action)
// Create an authorization rule object.
AuthorizationRuleAction action =
    AuthorizationRuleAction.Deny;
AuthorizationRule authorizationRule = 
    new System.Web.Configuration.AuthorizationRule(action);
' Using the AuthorizationRuleCollection Add method.
' Set the action property.
  authorizationRule.Action = _
  AuthorizationRuleAction.Allow
' Define the new rule to add to the collection.
authorizationRule.Users.Add("userName")
authorizationRule.Roles.Add("admin")
authorizationRule.Verbs.Add("POST")

' Add the new rule to the collection.
authorizationSection.Rules.Add(authorizationRule)
// Using the AuthorizationRuleCollection Add method.
           
// Set the action property.
authorizationRule.Action = 
   AuthorizationRuleAction.Allow;
// Define the new rule to add to the collection.
authorizationRule.Users.Add("userName");
authorizationRule.Roles.Add("admin");
authorizationRule.Verbs.Add("POST");

// Add the new rule to the collection.
authorizationSection.Rules.Add(authorizationRule);
継承階層継承階層
System.Object
   System.Configuration.ConfigurationElement
    System.Web.Configuration.AuthorizationRule
スレッド セーフスレッド セーフ
この型の public static (Visual Basic では Shared) メンバはすべて、スレッド セーフです。インスタンス メンバ場合は、スレッド セーフであるとは限りません。
プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照



英和和英テキスト翻訳>> Weblio翻訳
英語⇒日本語日本語⇒英語
  

辞書ショートカット

すべての辞書の索引

「AuthorizationRule クラス」の関連用語

AuthorizationRule クラスのお隣キーワード
検索ランキング

   

英語⇒日本語
日本語⇒英語
   



AuthorizationRule クラスのページの著作権
Weblio 辞書 情報提供元は 参加元一覧 にて確認できます。

   
日本マイクロソフト株式会社日本マイクロソフト株式会社
© 2025 Microsoft.All rights reserved.

©2025 GRAS Group, Inc.RSS