I am trying to start gRPC secure (SSL) server as a new thread in my
application. But it crashes with following stack. There are no file and
line numbers in the stack info. Did I miss any compile options ?
#0 0x0000000000aaa083 in ssl_create_cipher_list ()
#1 0x0000000000aac063 in SSL_CTX_new ()
#2 0x0000000000a9a3bc in tsi_create_ssl_server_handshaker_factory_ex ()
#3 0x0000000000a9706f in grpc_ssl_server_security_connector_create ()
#4 0x0000000000a85b35 in grpc_server_add_secure_http2_port ()
#5 0x0000000000a6aee8 in grpc::ServerBuilder::BuildAndStart() ()
If I use insecure server then everything works fine. Here is my server code.
grpc::SslServerCredentialsOptions::PemKeyCertPair pkcp;
pkcp.private_key = key_str; // value is correct
pkcp.cert_chain = cert_str; // value is correct
grpc::SslServerCredentialsOptions ssl_opts;
ssl_opts.pem_root_certs="";
ssl_opts.pem_key_cert_pairs.push_back(pkcp);
std::shared_ptr<grpc::ServerCredentials> creds;
creds = grpc::SslServerCredentials(ssl_opts);
// creds = grpc::InsecureServerCredentials();
MyService service;
grpc::ServerBuilder builder;
builder.AddListeningPort(server_address, creds);
builder.RegisterService(&service);
std::unique_ptr<grpc::Server> server(builder.BuildAndStart());
What is wrong here in my code ?
--
You received this message because you are subscribed to the Google Groups
"grpc.io" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/grpc-io.
To view this discussion on the web visit
https://groups.google.com/d/msgid/grpc-io/ade15c96-9163-4f2f-995d-e140779a4e77%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.