問題タブ [botan]
For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.
c++ - Botan: ECDH 秘密鍵をシリアライズする
を使用して新しいキーペアを作成しました
(RSAに比べて速かったです!)
ここの推奨事項に従って、PKCS#8 を使用してシリアル化しようとしています: https://botan.randombit.net/manual/pubkey.html#serializing-public-keys
例外があります:
ボタンの初期化は次の行を渡しますが:
ECDH_PrivateKey をシリアル化するにはどうすればよいですか?
c++11 - Botan スタティック ライブラリ リンク エラー
オプションを使用してソース ファイルをコンパイルすると、次のようになります。
-イボタン-2
これは、共有ライブラリを使用することを意味し、何も問題はありません。
しかし、オプションに切り替えた後:
-l:libbotan-2.a
つまり、静的ライブラリを使用すると、エラーが発生します。
//usr/local/lib/libbotan-2.a(pubkey_rsa.o): 関数std::future<std::result_of<Botan::Fixed_Exponent_Power_Mod const& (Botan::BigInt const&)>::type> std::async<Botan::Fixed_Exponent_Power_Mod const&, Botan::BigInt const&>(std::launch, Botan::Fixed_Exponent_Power_Mod const&, Botan::BigInt const&)':
rsa.cpp:(.text._ZSt5asyncIRKN5Botan24Fixed_Exponent_Power_ModEJRKNS0_6BigIntEEESt6futureINSt9result_ofIFT_DpT0_EE4typeEESt6launchOS9_DpOSA_[_ZSt5asyncIRKN5Botan24Fixed_Exponent_Power_ModEJRKNS0_6BigIntEEESt6futureINSt9result_ofIFT_DpT0_EE4typeEESt6launchOS9_DpOSA_]+0x379): undefined reference to
pthread_create で「collect2: エラー: ld が 1 つの終了ステータスを返しました」
Ubuntu 16.04 で Botan 2.1.0 と c++11 を使用しています。
何がうまくいかないのですか?
前もって感謝します。