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

Weblio 辞書 > コンピュータ > IT用語辞典 > PublicKeyの意味・解説 

パブリックキー

別名:公開鍵
【英】public key

パブリックキーとは、データ暗号化用いられる「鍵」(暗号化手順制御する情報)のひとつで、公開鍵暗号方式において一般に公開される鍵のことである。1976年考案された。

公開鍵暗号では、暗号化暗号解読復号)にそれぞれ別の鍵を用いる。パブリックキーは暗号化するための鍵で、暗号化するとパブリックキーでは復号することはできない通信相手がパブリックキーで暗号化したデータ復号するためには、復号鍵としてシークレットキー用いられるシークレットキーは鍵の所有者本人か持つことができないこのため、パブリックキーを通信相手渡しても(万が一第3者漏れても)暗号化されたデータ復号されて読まれる恐れがない。


参照リンク
公開鍵暗号方式 -the internet VAW(CYBER-LINKS Co.,Ltd)
セキュリティのほかの用語一覧
暗号化方式:  E2EE  Freenet  ハッシュ関数  パブリックキー  ペアリング暗号  非対称鍵暗号  秘密鍵暗号

PublicKey クラス

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

証明書公開キー情報表します。このクラス継承できません。

名前空間: System.Security.Cryptography.X509Certificates
アセンブリ: System (system.dll 内)
構文構文

Public NotInheritable Class
 PublicKey
public sealed class PublicKey
public final class PublicKey
解説解説
使用例使用例

証明書ファイル引数として受け取り、その証明書の各種プロパティコンソール出力するコマンド ライン形式実行可能ファイル作成するコード例次に示します

#using <System.dll>

using namespace System;
using namespace System::Security::Cryptography;
using namespace System::Security::Permissions;
using namespace System::IO;
using namespace System::Security::Cryptography::X509Certificates;

//Reads a file.
array<Byte>^ ReadFile( String^ fileName )
{
   FileStream^ f = gcnew FileStream( fileName,FileMode::Open,FileAccess::Read );
   int size = (int)f->Length;
   array<Byte>^data = gcnew array<Byte>(size);
   size = f->Read( data, 0, size );
   f->Close();
   return data;
}

int main()
{
   array<String^>^args = Environment::GetCommandLineArgs();
   
   //Test for correct number of arguments.
   if ( args->Length < 2 )
   {
      Console::WriteLine( "Usage: CertInfo <filename>" );
      return  -1;
   }

   try
   {
      System::Security::Cryptography::X509Certificates::X509Certificate2 ^ x509 =
 
            gcnew System::Security::Cryptography::X509Certificates::X509Certificate2;
      
      //Create X509Certificate2 object from .cer file.
      array<Byte>^rawData = ReadFile( args[ 1 ] );
      x509->Import(rawData);
      
      //Print to console information contained in the certificate.
      Console::WriteLine( "{0}Subject: {1}{0}", Environment::NewLine, x509->Subject
 );
      Console::WriteLine( "{0}Issuer: {1}{0}", Environment::NewLine, x509->Issuer
 );
      Console::WriteLine( "{0}Version: {1}{0}", Environment::NewLine, x509->Version
 );
      Console::WriteLine( "{0}Valid Date: {1}{0}", Environment::NewLine,
 x509->NotBefore );
      Console::WriteLine( "{0}Expiry Date: {1}{0}", Environment::NewLine,
 x509->NotAfter );
      Console::WriteLine( "{0}Thumbprint: {1}{0}", Environment::NewLine,
 x509->Thumbprint );
      Console::WriteLine( "{0}Serial Number: {1}{0}", Environment::NewLine,
 x509->SerialNumber );
      Console::WriteLine( "{0}Friendly Name: {1}{0}", Environment::NewLine,
 x509->PublicKey->Oid->FriendlyName );
      Console::WriteLine( "{0}Public Key Format: {1}{0}", Environment::NewLine,
 x509->PublicKey->EncodedKeyValue->Format(true) );
      Console::WriteLine( "{0}Raw Data Length: {1}{0}", Environment::NewLine,
 x509->RawData->Length );
      Console::WriteLine( "{0}Certificate to string: {1}{0}",
 Environment::NewLine, x509->ToString( true ) );
      Console::WriteLine( "{0}Certificate to XML String: {1}{0}", Environment::NewLine,
 x509->PublicKey->Key->ToXmlString( false ) );
      
      //Add the certificate to a X509Store.
      X509Store ^ store = gcnew X509Store;
      store->Open( OpenFlags::MaxAllowed );
      store->Add( x509 );
      store->Close();
   }
   catch ( DirectoryNotFoundException^ ) 
   {
      Console::WriteLine( "Error: The directory specified could not be found."
 );
   }
   catch ( IOException^ ) 
   {
      Console::WriteLine( "Error: A file in the directory
 could not be accessed." );
   }
   catch ( NullReferenceException^ ) 
   {
      Console::WriteLine( "File must be a .cer file. Program does not have access
 to that type of file." );
   }

}

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

PublicKey コンストラクタ

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

公開キー公開キー パラメータASN.1 エンコードされた表現、および公開キー値の ASN.1 エンコードされた表現オブジェクト識別子 (OID) を使用して、PublicKey クラス新しインスタンス初期化します。

名前空間: System.Security.Cryptography.X509Certificates
アセンブリ: System (system.dll 内)
構文構文

Public Sub New ( _
    oid As Oid, _
    parameters As AsnEncodedData, _
    keyValue As AsnEncodedData _
)
Dim oid As Oid
Dim parameters As AsnEncodedData
Dim keyValue As AsnEncodedData

Dim instance As New PublicKey(oid,
 parameters, keyValue)
public PublicKey (
    Oid oid,
    AsnEncodedData parameters,
    AsnEncodedData keyValue
)
public:
PublicKey (
    Oid^ oid, 
    AsnEncodedData^ parameters, 
    AsnEncodedData^ keyValue
)
public PublicKey (
    Oid oid, 
    AsnEncodedData parameters, 
    AsnEncodedData keyValue
)
public function PublicKey (
    oid : Oid, 
    parameters : AsnEncodedData, 
    keyValue : AsnEncodedData
)

パラメータ

oid

公開キーを表すオブジェクト識別子 (OID) オブジェクト

parameters

公開キー パラメータASN.1 エンコードされた表現

keyValue

公開キー値の ASN.1 エンコードされた表現

プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照
関連項目
PublicKey クラス
PublicKey メンバ
System.Security.Cryptography.X509Certificates 名前空間

PublicKey プロパティ


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

参照参照

関連項目

PublicKey クラス
System.Security.Cryptography.X509Certificates 名前空間

PublicKey メソッド


PublicKey メンバ

証明書公開キー情報表します。このクラス継承できません。

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


パブリック コンストラクタパブリック コンストラクタ
パブリック プロパティパブリック プロパティ
パブリック メソッドパブリック メソッド
プロテクト メソッドプロテクト メソッド
参照参照

関連項目

PublicKey クラス
System.Security.Cryptography.X509Certificates 名前空間

「public key」の例文・使い方・用例・文例

Weblio日本語例文用例辞書はプログラムで機械的に例文を生成しているため、不適切な項目が含まれていることもあります。ご了承くださいませ。


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

辞書ショートカット

すべての辞書の索引

「PublicKey」の関連用語

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

   

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



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

   
IT用語辞典バイナリIT用語辞典バイナリ
Copyright © 2005-2025 Weblio 辞書 IT用語辞典バイナリさくいん。 この記事は、IT用語辞典バイナリの【パブリックキー】の記事を利用しております。
日本マイクロソフト株式会社日本マイクロソフト株式会社
© 2025 Microsoft.All rights reserved.
Tanaka Corpusのコンテンツは、特に明示されている場合を除いて、次のライセンスに従います:
 Creative Commons Attribution (CC-BY) 2.0 France.
この対訳データはCreative Commons Attribution 3.0 Unportedでライセンスされています。
浜島書店 Catch a Wave
Copyright © 1995-2025 Hamajima Shoten, Publishers. All rights reserved.
株式会社ベネッセコーポレーション株式会社ベネッセコーポレーション
Copyright © Benesse Holdings, Inc. All rights reserved.
研究社研究社
Copyright (c) 1995-2025 Kenkyusha Co., Ltd. All rights reserved.
日本語WordNet日本語WordNet
日本語ワードネット1.1版 (C) 情報通信研究機構, 2009-2010 License All rights reserved.
WordNet 3.0 Copyright 2006 by Princeton University. All rights reserved. License
日外アソシエーツ株式会社日外アソシエーツ株式会社
Copyright (C) 1994- Nichigai Associates, Inc., All rights reserved.
「斎藤和英大辞典」斎藤秀三郎著、日外アソシエーツ辞書編集部編
EDRDGEDRDG
This page uses the JMdict dictionary files. These files are the property of the Electronic Dictionary Research and Development Group, and are used in conformance with the Group's licence.

©2025 GRAS Group, Inc.RSS