キーを派生させるために使用するパスワードおよびキー salt を指定して、PasswordDeriveBytes クラスの新しいインスタンスを初期化します。
名前空間: System.Security.Cryptography
アセンブリ: mscorlib (mscorlib.dll 内)
構文
'宣言
Public Sub New ( _
strPassword As String, _
rgbSalt As Byte() _
)
'使用
Dim strPassword As String
Dim rgbSalt As Byte()
Dim instance As New PasswordDeriveBytes(strPassword, rgbSalt)
public PasswordDeriveBytes (
string strPassword,
byte[] rgbSalt
)
public:
PasswordDeriveBytes (
String^ strPassword,
array<unsigned char>^ rgbSalt
)
public PasswordDeriveBytes (
String strPassword,
byte[] rgbSalt
)
public function PasswordDeriveBytes (
strPassword : String,
rgbSalt : byte[]
)
適用できません。
パラメータ
- strPassword
キーを派生させる対象のパスワード。
- rgbSalt
キーを派生させるために使用するキー salt。
解説
![]() |
---|
パスワードをソース コード内にハードコーディングすることは絶対に避けてください。ハードコーディングされたパスワードは、MSIL 逆アセンブラ (Ildasm.exe) ツールや 16 進エディタを使用したり、アセンブリを notepad.exe などのテキスト エディタで開いたりすることによって簡単にアセンブリから取得されてしまいます。 |
プラットフォーム
Windows 98,Windows Server 2000 SP4,Windows CE,Windows Millennium Edition,Windows Mobile for Pocket PC,Windows Mobile for Smartphone,Windows Server 2003,Windows XP Media Center Edition,Windows XP Professional x64 Edition,Windows XP SP2,Windows XP Starter Edition
Microsoft .NET Framework 3.0 は Windows Vista,Microsoft Windows XP SP2,および Windows Server 2003 SP1 でサポートされています。
バージョン情報
.NET Framework
サポート対象 : 3.0,2.0,1.1,1.0
参照
関連項目
PasswordDeriveBytes クラス
PasswordDeriveBytes メンバ
System.Security.Cryptography 名前空間