• R/O
  • SSH
  • HTTPS

ttssh2: Commit


Commit MetaInfo

Revision6571 (tree)
Time2017-01-15 15:05:35
Author(del#24082)

Log Message

EVP_PKEY 構造体のtypeメンバー取得を関数化した。

Change Summary

Incremental Difference

--- branches/openssl_1_1_0/ttssh2/ttxssh/keyfiles.c (revision 6570)
+++ branches/openssl_1_1_0/ttssh2/ttxssh/keyfiles.c (revision 6571)
@@ -641,6 +641,7 @@
641641 Key *result = NULL;
642642 EVP_PKEY *pk = NULL;
643643 unsigned long err = 0;
644+ int pk_type;
644645
645646 OpenSSL_add_all_algorithms();
646647 ERR_load_crypto_strings();
@@ -662,7 +663,8 @@
662663 goto error;
663664 }
664665
665- switch (pk->type) {
666+ pk_type = EVP_PKEY_id(pk);
667+ switch (pk_type) {
666668 case EVP_PKEY_RSA: // RSA key
667669 result->type = KEY_RSA;
668670 result->rsa = EVP_PKEY_get1_RSA(pk);
Show on old repository browser