ProtectedConfigurationProviderとは? わかりやすく解説

ProtectedConfigurationProvider クラス

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

保護された構成データの暗号化と復号化を行うプロバイダを作成する基本クラスです。

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

Public MustInherit Class
 ProtectedConfigurationProvider
    Inherits ProviderBase
Dim instance As ProtectedConfigurationProvider
public abstract class ProtectedConfigurationProvider
 : ProviderBase
public ref class ProtectedConfigurationProvider
 abstract : public ProviderBase
public abstract class ProtectedConfigurationProvider
 extends ProviderBase
public abstract class ProtectedConfigurationProvider
 extends ProviderBase
解説解説

構成ファイルのセクションを暗号化して、アプリケーションで使用する機密情報を保護できます。これにより、たとえ攻撃者が構成ファイルにアクセスできたとしても、未承認のアクセスを行うのが難しくなるため、セキュリティが向上します。

.NET Framework には、構成ファイルのセクションの暗号化に使用できる保護された構成プロバイダが 2 つ用意されています。1 つは構成セクションの暗号化に RSACryptoServiceProvider を使用する RSAProtectedConfigurationProvider で、もう 1 つは構成セクションの暗号化に Windows データ保護 API (DPAPI: Data Protection API) を使用する DPAPIProtectedConfigurationProvider です。

RSA プロバイダまたは DPAPI プロバイダ以外のアルゴリズムを使用して機密情報を暗号する必要がある場合もあります。この場合、カスタムの保護された構成プロバイダを作成します。ProtectedConfigurationProvider は、独自の保護された構成プロバイダを作成するために継承する必要がある抽象基本クラスです。

標準プロバイダとカスタム プロバイダのどちらを使用する場合も、そのプロバイダが configProtectedData 構成セクションの providers セクション内にある add 要素を使用して構成されていることを確認する必要があります (次の例を参照してください)。

詳細については、「保護された構成プロバイダの実装」を参照してください。

メモメモ

ASP.NET は、暗号化された構成データを検出すると、構成済みのプロバイダを使用して透過的に復号化を実行します。必要なプロバイダを構成していることを確認する以外には、何もする必要はありません。

使用例使用例

カスタム ProtectedConfigurationProvider を実装する方法を次の例に示します。

このプロバイダを構成できるようにするには、次の構成の抜粋で示すように、このプロバイダをグローバル アセンブリ キャッシュ (GAC: Global Assembly Cache) にインストールする必要があります。詳細については、「保護された構成プロバイダの実装」を参照してください。

Imports System
Imports System.Xml
Imports System.Security.Cryptography
Imports System.IO
Imports System.Text
Imports System.Configuration.Provider
Imports System.Collections.Specialized
Imports System.Configuration


' Show how to use the ProtectedConfigurationProvider
' to create a custom protected configuration
' provider.

Public Class TripleDESProtectedConfigurationProvider
   Inherits ProtectedConfigurationProvider
   
    Private des _
    As New TripleDESCryptoServiceProvider()
   
   Private pKeyFilePath As String
   Private pName As String
   
   ' Gets the path of the file
   ' containing the key used to
   ' encrypt/decrypt.
   
   Public ReadOnly Property
 KeyFilePath() As String
      Get
         Return pKeyFilePath
      End Get
   End Property 
   
   ' Gets the provider name.
   
   Public Overrides ReadOnly
 Property Name() As String
      Get
         Return pName
      End Get
   End Property
    
   
   ' Performs provider initialization.
    Public Overrides Sub
 Initialize( _
    ByVal name As String,
 _
    ByVal config As NameValueCollection)
        pName = name
        pKeyFilePath = config("keyContainerName")
        ReadKey(KeyFilePath)
    End Sub 'Initialize
   
   
   ' Performs encryption.
    Public Overrides Function
 Encrypt( _
    ByVal node As XmlNode) As
 XmlNode
        Dim encryptedData As String
 = _
        EncryptString(node.OuterXml)

        Dim xmlDoc As New
 XmlDocument()
        xmlDoc.PreserveWhitespace = True
        xmlDoc.LoadXml( _
        ("<EncryptedData>" + encryptedData +
 _
        "</EncryptedData>"))

        Return xmlDoc.DocumentElement
    End Function 'Encrypt

   ' Performs decryption.
    Public Overrides Function
 Decrypt( _
    ByVal encryptedNode As XmlNode) As
 XmlNode
        Dim decryptedData As String
 = _
        DecryptString(encryptedNode.InnerText)

        Dim xmlDoc As New
 XmlDocument()
        xmlDoc.PreserveWhitespace = True
        xmlDoc.LoadXml(decryptedData)

        Return xmlDoc.DocumentElement
    End Function 'Decrypt

   
   
   ' Encrypts a configuration section and returns 
   ' the encrypted XML as a string.
    Private Function EncryptString( _
    ByVal encryptValue As String)
 As String
        Dim valBytes As Byte()
 = _
        Encoding.Unicode.GetBytes(encryptValue)

        Dim transform As ICryptoTransform =
 _
        des.CreateEncryptor()

        Dim ms As New MemoryStream()
        Dim cs As New CryptoStream(ms,
 _
        transform, CryptoStreamMode.Write)
        cs.Write(valBytes, 0, valBytes.Length)
        cs.FlushFinalBlock()
        Dim returnBytes As Byte()
 = ms.ToArray()
        cs.Close()

        Return Convert.ToBase64String(returnBytes)
    End Function 'EncryptString
   
   
   
   ' Decrypts an encrypted configuration section and 
   ' returns the unencrypted XML as a string.
    Private Function DecryptString( _
    ByVal encryptedValue As String)
 As String
        Dim valBytes As Byte()
 = _
        Convert.FromBase64String(encryptedValue)

        Dim transform As ICryptoTransform =
 _
        des.CreateDecryptor()

        Dim ms As New MemoryStream()
        Dim cs As New CryptoStream(ms,
 _
        transform, CryptoStreamMode.Write)
        cs.Write(valBytes, 0, valBytes.Length)
        cs.FlushFinalBlock()
        Dim returnBytes As Byte()
 = ms.ToArray()
        cs.Close()

        Return Encoding.Unicode.GetString(returnBytes)
    End Function 'DecryptString
   
   
   ' Generates a new TripleDES key and vector and 
   ' writes them to the supplied file path.
   Public Sub CreateKey(filePath As
 String)
      des.GenerateKey()
      des.GenerateIV()
      
      Dim sw As New StreamWriter(filePath,
 False)
      sw.WriteLine(ByteToHex(des.Key))
      sw.WriteLine(ByteToHex(des.IV))
      sw.Close()
   End Sub 'CreateKey
   
   
   
   ' Reads in the TripleDES key and vector from 
   ' the supplied file path and sets the Key 
   ' and IV properties of the 
   ' TripleDESCryptoServiceProvider.
   Private Sub ReadKey(filePath As
 String)
      Dim sr As New StreamReader(filePath)
      Dim keyValue As String
 = sr.ReadLine()
      Dim ivValue As String
 = sr.ReadLine()
      des.Key = HexToByte(keyValue)
      des.IV = HexToByte(ivValue)
   End Sub 'ReadKey
   
   
   
   ' Converts a byte array to a hexadecimal string.
    Private Function ByteToHex( _
    ByVal byteArray() As Byte)
 As String
        Dim outString As String
 = ""

        Dim b As [Byte]
        For Each b In byteArray
            outString += b.ToString("X2")
        Next b
        Return outString
    End Function 'ByteToHex
   
   
   ' Converts a hexadecimal string to a byte array.
   Private Function HexToByte(hexString As
 String) As Byte()
      Dim returnBytes(hexString.Length / 2) As
 Byte
      Dim i As Integer
      For i = 0 To returnBytes.Length - 1
            returnBytes(i) = _
            Convert.ToByte(hexString.Substring(i * 2, 2), 16)
      Next i
      Return returnBytes
   End Function 'HexToByte
End Class 'TripleDESProtectedConfigurationProvider
 

using System;
using System.Xml;
using System.Security.Cryptography;
using System.IO;
using System.Text;
using System.Configuration.Provider;
using System.Collections.Specialized;
using System.Configuration;

namespace Samples.AspNet.Configuration
{
    // Show how to use the ProtectedConfigurationProvider
    // to create a custom protected configuration
    // provider.
    public class TripleDESProtectedConfigurationProvider
 :
        ProtectedConfigurationProvider
    {

        private TripleDESCryptoServiceProvider des =
            new TripleDESCryptoServiceProvider();

        private string pKeyFilePath;
        private string pName;

        // Gets the path of the file
        // containing the key used to
        // encrypt/decrypt.
        public string KeyFilePath
        {
            get { return pKeyFilePath; }
        }


        // Gets the provider name.
        public override string Name
        {
            get { return pName; }
        }


        // Performs provider initialization.
        public override void Initialize(string
 name,
            NameValueCollection config)
        {
            pName = name;
            pKeyFilePath = config["keyContainerName"];
            ReadKey(KeyFilePath);
        }


        // Performs encryption.
        public override XmlNode Encrypt(XmlNode node)
        {
            string encryptedData = EncryptString(node.OuterXml);

            XmlDocument xmlDoc = new XmlDocument();
            xmlDoc.PreserveWhitespace = true;
            xmlDoc.LoadXml("<EncryptedData>" +
                encryptedData + "</EncryptedData>");

            return xmlDoc.DocumentElement;
        }

        // Performs decryption.
        public override XmlNode Decrypt(XmlNode encryptedNode)
        {
            string decryptedData =
                DecryptString(encryptedNode.InnerText);

            XmlDocument xmlDoc = new XmlDocument();
            xmlDoc.PreserveWhitespace = true;
            xmlDoc.LoadXml(decryptedData);

            return xmlDoc.DocumentElement;
        }

        // Encrypts a configuration section and returns 
        // the encrypted XML as a string.
        private string EncryptString(string
 encryptValue)
        {
            byte[] valBytes =
                Encoding.Unicode.GetBytes(encryptValue);

            ICryptoTransform transform = des.CreateEncryptor();

            MemoryStream ms = new MemoryStream();
            CryptoStream cs = new CryptoStream(ms,
                transform, CryptoStreamMode.Write);
            cs.Write(valBytes, 0, valBytes.Length);
            cs.FlushFinalBlock();
            byte[] returnBytes = ms.ToArray();
            cs.Close();

            return Convert.ToBase64String(returnBytes);
        }


        // Decrypts an encrypted configuration section and 
        // returns the unencrypted XML as a string.
        private string DecryptString(string
 encryptedValue)
        {
            byte[] valBytes =
                Convert.FromBase64String(encryptedValue);

            ICryptoTransform transform = des.CreateDecryptor();

            MemoryStream ms = new MemoryStream();
            CryptoStream cs = new CryptoStream(ms,
                transform, CryptoStreamMode.Write);
            cs.Write(valBytes, 0, valBytes.Length);
            cs.FlushFinalBlock();
            byte[] returnBytes = ms.ToArray();
            cs.Close();

            return Encoding.Unicode.GetString(returnBytes);
        }

        // Generates a new TripleDES key and vector and 
        // writes them to the supplied file path.
        public void CreateKey(string
 filePath)
        {
            des.GenerateKey();
            des.GenerateIV();

            StreamWriter sw = new StreamWriter(filePath, false);
            sw.WriteLine(ByteToHex(des.Key));
            sw.WriteLine(ByteToHex(des.IV));
            sw.Close();
        }


        // Reads in the TripleDES key and vector from 
        // the supplied file path and sets the Key 
        // and IV properties of the 
        // TripleDESCryptoServiceProvider.
        private void ReadKey(string
 filePath)
        {
            StreamReader sr = new StreamReader(filePath);
            string keyValue = sr.ReadLine();
            string ivValue = sr.ReadLine();
            des.Key = HexToByte(keyValue);
            des.IV = HexToByte(ivValue);
        }


        // Converts a byte array to a hexadecimal string.
        private string ByteToHex(byte[] byteArray)
        {
            string outString = "";

            foreach (Byte b in byteArray)
                outString += b.ToString("X2");

            return outString;
        }

        // Converts a hexadecimal string to a byte array.
        private byte[] HexToByte(string hexString)
        {
            byte[] returnBytes = new byte[hexString.Length / 2];
            for (int i = 0; i < returnBytes.Length;
 i++)
                returnBytes[i] =
                    Convert.ToByte(hexString.Substring(i * 2, 2), 16);
            return returnBytes;
        }

    }

}

前のカスタム ProtectedConfigurationProvider を使用する方法を次の例に示します。

Imports System
Imports System.Xml
Imports System.Security.Cryptography
Imports System.IO
Imports System.Text
Imports System.Configuration.Provider
Imports System.Collections.Specialized
Imports System.Configuration


' Show how to use the ProtectedConfigurationProvider
' to create a custom protected configuration
' provider.

Public Class TripleDESProtectedConfigurationProvider
   Inherits ProtectedConfigurationProvider
   
    Private des _
    As New TripleDESCryptoServiceProvider()
   
   Private pKeyFilePath As String
   Private pName As String
   
   ' Gets the path of the file
   ' containing the key used to
   ' encrypt/decrypt.
   
   Public ReadOnly Property
 KeyFilePath() As String
      Get
         Return pKeyFilePath
      End Get
   End Property 
   
   ' Gets the provider name.
   
   Public Overrides ReadOnly
 Property Name() As String
      Get
         Return pName
      End Get
   End Property
    
   
   ' Performs provider initialization.
    Public Overrides Sub
 Initialize( _
    ByVal name As String,
 _
    ByVal config As NameValueCollection)
        pName = name
        pKeyFilePath = config("keyContainerName")
        ReadKey(KeyFilePath)
    End Sub 'Initialize
   
   
   ' Performs encryption.
    Public Overrides Function
 Encrypt( _
    ByVal node As XmlNode) As
 XmlNode
        Dim encryptedData As String
 = _
        EncryptString(node.OuterXml)

        Dim xmlDoc As New
 XmlDocument()
        xmlDoc.PreserveWhitespace = True
        xmlDoc.LoadXml( _
        ("<EncryptedData>" + encryptedData +
 _
        "</EncryptedData>"))

        Return xmlDoc.DocumentElement
    End Function 'Encrypt

   ' Performs decryption.
    Public Overrides Function
 Decrypt( _
    ByVal encryptedNode As XmlNode) As
 XmlNode
        Dim decryptedData As String
 = _
        DecryptString(encryptedNode.InnerText)

        Dim xmlDoc As New
 XmlDocument()
        xmlDoc.PreserveWhitespace = True
        xmlDoc.LoadXml(decryptedData)

        Return xmlDoc.DocumentElement
    End Function 'Decrypt

   
   
   ' Encrypts a configuration section and returns 
   ' the encrypted XML as a string.
    Private Function EncryptString( _
    ByVal encryptValue As String)
 As String
        Dim valBytes As Byte()
 = _
        Encoding.Unicode.GetBytes(encryptValue)

        Dim transform As ICryptoTransform =
 _
        des.CreateEncryptor()

        Dim ms As New MemoryStream()
        Dim cs As New CryptoStream(ms,
 _
        transform, CryptoStreamMode.Write)
        cs.Write(valBytes, 0, valBytes.Length)
        cs.FlushFinalBlock()
        Dim returnBytes As Byte()
 = ms.ToArray()
        cs.Close()

        Return Convert.ToBase64String(returnBytes)
    End Function 'EncryptString
   
   
   
   ' Decrypts an encrypted configuration section and 
   ' returns the unencrypted XML as a string.
    Private Function DecryptString( _
    ByVal encryptedValue As String)
 As String
        Dim valBytes As Byte()
 = _
        Convert.FromBase64String(encryptedValue)

        Dim transform As ICryptoTransform =
 _
        des.CreateDecryptor()

        Dim ms As New MemoryStream()
        Dim cs As New CryptoStream(ms,
 _
        transform, CryptoStreamMode.Write)
        cs.Write(valBytes, 0, valBytes.Length)
        cs.FlushFinalBlock()
        Dim returnBytes As Byte()
 = ms.ToArray()
        cs.Close()

        Return Encoding.Unicode.GetString(returnBytes)
    End Function 'DecryptString
   
   
   ' Generates a new TripleDES key and vector and 
   ' writes them to the supplied file path.
   Public Sub CreateKey(filePath As
 String)
      des.GenerateKey()
      des.GenerateIV()
      
      Dim sw As New StreamWriter(filePath,
 False)
      sw.WriteLine(ByteToHex(des.Key))
      sw.WriteLine(ByteToHex(des.IV))
      sw.Close()
   End Sub 'CreateKey
   
   
   
   ' Reads in the TripleDES key and vector from 
   ' the supplied file path and sets the Key 
   ' and IV properties of the 
   ' TripleDESCryptoServiceProvider.
   Private Sub ReadKey(filePath As
 String)
      Dim sr As New StreamReader(filePath)
      Dim keyValue As String
 = sr.ReadLine()
      Dim ivValue As String
 = sr.ReadLine()
      des.Key = HexToByte(keyValue)
      des.IV = HexToByte(ivValue)
   End Sub 'ReadKey
   
   
   
   ' Converts a byte array to a hexadecimal string.
    Private Function ByteToHex( _
    ByVal byteArray() As Byte)
 As String
        Dim outString As String
 = ""

        Dim b As [Byte]
        For Each b In byteArray
            outString += b.ToString("X2")
        Next b
        Return outString
    End Function 'ByteToHex
   
   
   ' Converts a hexadecimal string to a byte array.
   Private Function HexToByte(hexString As
 String) As Byte()
      Dim returnBytes(hexString.Length / 2) As
 Byte
      Dim i As Integer
      For i = 0 To returnBytes.Length - 1
            returnBytes(i) = _
            Convert.ToByte(hexString.Substring(i * 2, 2), 16)
      Next i
      Return returnBytes
   End Function 'HexToByte
End Class 'TripleDESProtectedConfigurationProvider
 

using System;
using System.Xml;
using System.Security.Cryptography;
using System.IO;
using System.Text;
using System.Configuration.Provider;
using System.Collections.Specialized;
using System.Configuration;

namespace Samples.AspNet.Configuration
{
    // Show how to use the ProtectedConfigurationProvider
    // to create a custom protected configuration
    // provider.
    public class TripleDESProtectedConfigurationProvider
 :
        ProtectedConfigurationProvider
    {

        private TripleDESCryptoServiceProvider des =
            new TripleDESCryptoServiceProvider();

        private string pKeyFilePath;
        private string pName;

        // Gets the path of the file
        // containing the key used to
        // encrypt/decrypt.
        public string KeyFilePath
        {
            get { return pKeyFilePath; }
        }


        // Gets the provider name.
        public override string Name
        {
            get { return pName; }
        }


        // Performs provider initialization.
        public override void Initialize(string
 name,
            NameValueCollection config)
        {
            pName = name;
            pKeyFilePath = config["keyContainerName"];
            ReadKey(KeyFilePath);
        }


        // Performs encryption.
        public override XmlNode Encrypt(XmlNode node)
        {
            string encryptedData = EncryptString(node.OuterXml);

            XmlDocument xmlDoc = new XmlDocument();
            xmlDoc.PreserveWhitespace = true;
            xmlDoc.LoadXml("<EncryptedData>" +
                encryptedData + "</EncryptedData>");

            return xmlDoc.DocumentElement;
        }

        // Performs decryption.
        public override XmlNode Decrypt(XmlNode encryptedNode)
        {
            string decryptedData =
                DecryptString(encryptedNode.InnerText);

            XmlDocument xmlDoc = new XmlDocument();
            xmlDoc.PreserveWhitespace = true;
            xmlDoc.LoadXml(decryptedData);

            return xmlDoc.DocumentElement;
        }

        // Encrypts a configuration section and returns 
        // the encrypted XML as a string.
        private string EncryptString(string
 encryptValue)
        {
            byte[] valBytes =
                Encoding.Unicode.GetBytes(encryptValue);

            ICryptoTransform transform = des.CreateEncryptor();

            MemoryStream ms = new MemoryStream();
            CryptoStream cs = new CryptoStream(ms,
                transform, CryptoStreamMode.Write);
            cs.Write(valBytes, 0, valBytes.Length);
            cs.FlushFinalBlock();
            byte[] returnBytes = ms.ToArray();
            cs.Close();

            return Convert.ToBase64String(returnBytes);
        }


        // Decrypts an encrypted configuration section and 
        // returns the unencrypted XML as a string.
        private string DecryptString(string
 encryptedValue)
        {
            byte[] valBytes =
                Convert.FromBase64String(encryptedValue);

            ICryptoTransform transform = des.CreateDecryptor();

            MemoryStream ms = new MemoryStream();
            CryptoStream cs = new CryptoStream(ms,
                transform, CryptoStreamMode.Write);
            cs.Write(valBytes, 0, valBytes.Length);
            cs.FlushFinalBlock();
            byte[] returnBytes = ms.ToArray();
            cs.Close();

            return Encoding.Unicode.GetString(returnBytes);
        }

        // Generates a new TripleDES key and vector and 
        // writes them to the supplied file path.
        public void CreateKey(string
 filePath)
        {
            des.GenerateKey();
            des.GenerateIV();

            StreamWriter sw = new StreamWriter(filePath, false);
            sw.WriteLine(ByteToHex(des.Key));
            sw.WriteLine(ByteToHex(des.IV));
            sw.Close();
        }


        // Reads in the TripleDES key and vector from 
        // the supplied file path and sets the Key 
        // and IV properties of the 
        // TripleDESCryptoServiceProvider.
        private void ReadKey(string
 filePath)
        {
            StreamReader sr = new StreamReader(filePath);
            string keyValue = sr.ReadLine();
            string ivValue = sr.ReadLine();
            des.Key = HexToByte(keyValue);
            des.IV = HexToByte(ivValue);
        }


        // Converts a byte array to a hexadecimal string.
        private string ByteToHex(byte[] byteArray)
        {
            string outString = "";

            foreach (Byte b in byteArray)
                outString += b.ToString("X2");

            return outString;
        }

        // Converts a hexadecimal string to a byte array.
        private byte[] HexToByte(string hexString)
        {
            byte[] returnBytes = new byte[hexString.Length / 2];
            for (int i = 0; i < returnBytes.Length;
 i++)
                returnBytes[i] =
                    Convert.ToByte(hexString.Substring(i * 2, 2), 16);
            return returnBytes;
        }

    }

}

上記の例で使用する構成ファイルの抜粋を次に示します。

<?xml version="1.0" encoding="utf-8" ?>
<configuration>

  <configProtectedData >
    <providers>
      <clear />
      <add keyContainerName="pcKey.txt" 
        name="TripleDESProtectedConfigurationProvider"
type="Samples.Aspnet.Configuration.TripleDESProtectedConfigurationProvider, protectedconfigurationproviderlib,
 Version=1.0.0.0, Culture=neutral, PublicKeyToken=79e01ae0f5cfc66f, processorArchitecture=MSIL"
 />
    </providers>

     

  </configProtectedData >

  <connectionStrings>
    <add name="NorthwindConnectionString" 
      connectionString="Data Source=webnetue2;Initial Catalog=Northwind;User ID=aspnet_test;Password=test"
providerName="System.Data.SqlClient" />
  </connectionStrings>

</configuration>
継承階層継承階層
System.Object
   System.Configuration.Provider.ProviderBase
    System.Configuration.ProtectedConfigurationProvider
       System.Configuration.DpapiProtectedConfigurationProvider
       System.Configuration.RsaProtectedConfigurationProvider
スレッド セーフスレッド セーフ
この型の public static (Visual Basic では Shared) メンバはすべて、スレッド セーフです。インスタンス メンバの場合は、スレッド セーフであるとは限りません。
プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照
関連項目
ProtectedConfigurationProvider メンバ
System.Configuration 名前空間
ProtectedConfigurationProviderCollection
ProtectedConfiguration クラス
ProtectedConfigurationSection
DpapiProtectedConfigurationProvider クラス
RSAProtectedConfigurationProvider
その他の技術情報
保護された構成を使用した構成情報の暗号化

ProtectedConfigurationProvider コンストラクタ


ProtectedConfigurationProvider プロパティ


パブリック プロパティパブリック プロパティ

参照参照

関連項目

ProtectedConfigurationProvider クラス
System.Configuration 名前空間
ProtectedConfigurationProviderCollection
ProtectedConfiguration クラス
ProtectedConfigurationSection
DpapiProtectedConfigurationProvider クラス
RSAProtectedConfigurationProvider

その他の技術情報

保護された構成を使用した構成情報の暗号化

ProtectedConfigurationProvider メソッド


パブリック メソッドパブリック メソッド

プロテクト メソッドプロテクト メソッド
参照参照

関連項目

ProtectedConfigurationProvider クラス
System.Configuration 名前空間
ProtectedConfigurationProviderCollection
ProtectedConfiguration クラス
ProtectedConfigurationSection
DpapiProtectedConfigurationProvider クラス
RSAProtectedConfigurationProvider

その他の技術情報

保護された構成を使用した構成情報の暗号化

ProtectedConfigurationProvider メンバ

保護された構成データの暗号化と復号化を行うプロバイダを作成する基本クラスです。

ProtectedConfigurationProvider データ型で公開されるメンバを以下の表に示します。


プロテクト コンストラクタプロテクト コンストラクタ
  名前 説明
プロテクト メソッド ProtectedConfigurationProvider 既定の設定を使用して ProtectedConfigurationProvider クラスの新しいインスタンスを初期化します。
パブリック プロパティパブリック プロパティ
パブリック メソッドパブリック メソッド
プロテクト メソッドプロテクト メソッド
参照参照

関連項目

ProtectedConfigurationProvider クラス
System.Configuration 名前空間
ProtectedConfigurationProviderCollection
ProtectedConfiguration クラス
ProtectedConfigurationSection
DpapiProtectedConfigurationProvider クラス
RSAProtectedConfigurationProvider

その他の技術情報

保護された構成を使用した構成情報の暗号化



英和和英テキスト翻訳

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

辞書ショートカット

すべての辞書の索引

「ProtectedConfigurationProvider」の関連用語

ProtectedConfigurationProviderのお隣キーワード
検索ランキング

   

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



ProtectedConfigurationProviderのページの著作権

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

©2026 GRAS Group, Inc.RSS