title: How to enable server side SSL for gRPC?
body: <p>New to gRPC and couldn't really find any example on how to enable SSL on the server side.  I generated a key pair using openssl but it complains that the private key is invalid.</p>
  
  <pre><code>D0608 16:18:31.390303 Grpc.Core.Internal.UnmanagedLibrary Attempting to load native library "...\grpc_csharp_ext.dll"
  D0608 16:18:31.424331 Grpc.Core.Internal.NativeExtension gRPC native library loaded successfully.
  E0608 16:18:43.307324 0 ..\src\core\lib\tsi\ssl_transport_security.c:644: Invalid private key.
  E0608 16:18:43.307824 0 ..\src\core\lib\security\security_connector.c:821: Handshaker factory creation failed with TSI_INVALID_ARGUMENT.
  E0608 16:18:43.307824 0 ..\src\core\ext\transport\chttp2\server\secure\server_secure_chttp2.c:188: Unable to create secure server with credentials of type Ssl.
  </code></pre>
  
  <p>Here's my code</p>
  
  <pre><code>var keypair = new KeyCertificatePair(
              File.ReadAllText(@"root-ca.pem"),
              File.ReadAllText(@"ssl-private.key"));
  SslServerCredentials creds = new SslServerCredentials(new List&lt;KeyCertificatePair&gt;() {keypair});
  Server server = new Server
  {
      Services = { GrpcTest.BindService(new GrpcTestImpl()) },
      Ports = { new ServerPort("127.0.0.1", Port, creds) }
  };
  </code></pre>