AsymmetricKeyAlgorithmProvider.CreateKeyPairWithCurveName(String) Méthode
Définition
Important
Certaines informations portent sur la préversion du produit qui est susceptible d’être en grande partie modifiée avant sa publication. Microsoft exclut toute garantie, expresse ou implicite, concernant les informations fournies ici.
Crée une paire de clés publique/privée à l’aide d’un nom de courbe algorithmique.
public:
virtual CryptographicKey ^ CreateKeyPairWithCurveName(Platform::String ^ curveName) = CreateKeyPairWithCurveName;
CryptographicKey CreateKeyPairWithCurveName(winrt::hstring const& curveName);
public CryptographicKey CreateKeyPairWithCurveName(string curveName);
function createKeyPairWithCurveName(curveName)
Public Function CreateKeyPairWithCurveName (curveName As String) As CryptographicKey
Paramètres
- curveName
-
String
Platform::String
winrt::hstring
Nom de la courbe.
Retours
Représente la paire de clés asymétriques ECDSA (Elliptic Curve Digital Signature Algorithm) générée.
Exemples
L’exemple suivant crée une courbe ECDSA à partir de CurveName.
AsymmetricKeyAlgorithmProvider eccAlgorithmProvider =
AsymmetricKeyAlgorithmProvider.OpenAlgorithm(AsymmetricAlgorithmNames.EcdsaSha256);
CryptographicKey keyPair = eccAlgorithmProvider.CreateKeyPairWithCurveName(EccCurveNames.Secp160k1);
AsymmetricKeyAlgorithmProvider^ eccAlgorithmProvider = AsymmetricKeyAlgorithmProvider::OpenAlgorithm(
AsymmetricAlgorithmNames::EcdsaSha256);
CryptographicKey^ keyPair = eccAlgorithmProvider->CreateKeyPairWithCurveName(EccCurveNames::Secp160k1);
S’applique à
Commentaires
https://aka.ms/ContentUserFeedback.
Bientôt disponible : Tout au long de 2024, nous allons supprimer progressivement GitHub Issues comme mécanisme de commentaires pour le contenu et le remplacer par un nouveau système de commentaires. Pour plus d’informations, consultezEnvoyer et afficher des commentaires pour