{"action":"created","comment":{"url":"https://api.github.com/repos/envoyproxy/envoy/pulls/comments/158410618","pull_request_review_id":85220012,"id":158410618,"diff_hunk":"@@ -375,10 +425,41 @@ ServerContextImpl::ServerContextImpl(ContextManagerImpl& parent, const std::stri\n         return dynamic_cast<ServerContextImpl*>(context_impl)->processClientHello(client_hello);\n       });\n \n-  if (!config.caCertFile().empty()) {\n-    bssl::UniquePtr<STACK_OF(X509_NAME)> list(SSL_load_client_CA_file(config.caCertFile().c_str()));\n-    if (nullptr == list) {\n-      throw EnvoyException(fmt::format(\"Failed to load client CA file {}\", config.caCertFile()));\n+  if (!config.caCert().empty()) {\n+    bssl::UniquePtr<BIO> bio(\n+        BIO_new_mem_buf(const_cast<char*>(config.caCert().data()), config.caCert().size()));\n+    RELEASE_ASSERT(bio != nullptr);\n+    // Based on BoringSSL's SSL_add_file_cert_subjects_to_stack().\n+    bssl::UniquePtr<STACK_OF(X509_NAME)> list(sk_X509_NAME_new(\n+        [](const X509_NAME** a, const X509_NAME** b) -> int { return X509_NAME_cmp(*a, *b); }));\n+    RELEASE_ASSERT(list != nullptr);\n+    for (;;) {\n+      bssl::UniquePtr<X509> cert(PEM_read_bio_X509(bio.get(), nullptr, nullptr, nullptr));\n+      if (cert == nullptr) {\n+        break;","path":"source/common/ssl/context_impl.cc","position":120,"original_position":120,"commit_id":"0241759e472629490a50e434ae712c16bb5af7b4","original_commit_id":"0241759e472629490a50e434ae712c16bb5af7b4","user":{"login":"PiotrSikora","id":190297,"avatar_url":"https://avatars3.githubusercontent.com/u/190297?v=4","gravatar_id":"","url":"https://api.github.com/users/PiotrSikora","html_url":"https://github.com/PiotrSikora","followers_url":"https://api.github.com/users/PiotrSikora/followers","following_url":"https://api.github.com/users/PiotrSikora/following{/other_user}","gists_url":"https://api.github.com/users/PiotrSikora/gists{/gist_id}","starred_url":"https://api.github.com/users/PiotrSikora/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/PiotrSikora/subscriptions","organizations_url":"https://api.github.com/users/PiotrSikora/orgs","repos_url":"https://api.github.com/users/PiotrSikora/repos","events_url":"https://api.github.com/users/PiotrSikora/events{/privacy}","received_events_url":"https://api.github.com/users/PiotrSikora/received_events","type":"User","site_admin":false},"body":"Unlikely, I'll add some.","created_at":"2017-12-22T00:53:26Z","updated_at":"2017-12-22T00:53:27Z","html_url":"https://github.com/envoyproxy/envoy/pull/2248#discussion_r158410618","pull_request_url":"https://api.github.com/repos/envoyproxy/envoy/pulls/2248","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/envoyproxy/envoy/pulls/comments/158410618"},"html":{"href":"https://github.com/envoyproxy/envoy/pull/2248#discussion_r158410618"},"pull_request":{"href":"https://api.github.com/repos/envoyproxy/envoy/pulls/2248"}},"in_reply_to_id":158263566},"pull_request":{"url":"https://api.github.com/repos/envoyproxy/envoy/pulls/2248","id":159567841,"html_url":"https://github.com/envoyproxy/envoy/pull/2248","diff_url":"https://github.com/envoyproxy/envoy/pull/2248.diff","patch_url":"https://github.com/envoyproxy/envoy/pull/2248.patch","issue_url":"https://api.github.com/repos/envoyproxy/envoy/issues/2248","number":2248,"state":"open","locked":false,"title":"tls: inline delivery of TLS certificates and private keys.","user":{"login":"PiotrSikora","id":190297,"avatar_url":"https://avatars3.githubusercontent.com/u/190297?v=4","gravatar_id":"","url":"https://api.github.com/users/PiotrSikora","html_url":"https://github.com/PiotrSikora","followers_url":"https://api.github.com/users/PiotrSikora/followers","following_url":"https://api.github.com/users/PiotrSikora/following{/other_user}","gists_url":"https://api.github.com/users/PiotrSikora/gists{/gist_id}","starred_url":"https://api.github.com/users/PiotrSikora/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/PiotrSikora/subscriptions","organizations_url":"https://api.github.com/users/PiotrSikora/orgs","repos_url":"https://api.github.com/users/PiotrSikora/repos","events_url":"https://api.github.com/users/PiotrSikora/events{/privacy}","received_events_url":"https://api.github.com/users/PiotrSikora/received_events","type":"User","site_admin":false},"body":"File-based BoringSSL APIs are no longer used and everything is processed\r\nas if it was delivered inline in order to provide consistent behavior.\r\n\r\nAdditionally, DataSource files are now read during configuration parsing,\r\nwhich means that the configuration is considered invalid if it refers to\r\nnon-existing files.\r\n\r\nFixes #1357.\r\n\r\nSigned-off-by: Piotr Sikora <piotrsikora@google.com>","created_at":"2017-12-21T03:21:33Z","updated_at":"2017-12-22T00:53:27Z","closed_at":null,"merged_at":null,"merge_commit_sha":"35381007ef6a3424f5bc24838928419c559dc7f1","assignee":null,"assignees":[],"requested_reviewers":[],"milestone":null,"commits_url":"https://api.github.com/repos/envoyproxy/envoy/pulls/2248/commits","review_comments_url":"https://api.github.com/repos/envoyproxy/envoy/pulls/2248/comments","review_comment_url":"https://api.github.com/repos/envoyproxy/envoy/pulls/comments{/number}","comments_url":"https://api.github.com/repos/envoyproxy/envoy/issues/2248/comments","statuses_url":"https://api.github.com/repos/envoyproxy/envoy/statuses/0241759e472629490a50e434ae712c16bb5af7b4","head":{"label":"PiotrSikora:ssl_inline","ref":"ssl_inline","sha":"0241759e472629490a50e434ae712c16bb5af7b4","user":{"login":"PiotrSikora","id":190297,"avatar_url":"https://avatars3.githubusercontent.com/u/190297?v=4","gravatar_id":"","url":"https://api.github.com/users/PiotrSikora","html_url":"https://github.com/PiotrSikora","followers_url":"https://api.github.com/users/PiotrSikora/followers","following_url":"https://api.github.com/users/PiotrSikora/following{/other_user}","gists_url":"https://api.github.com/users/PiotrSikora/gists{/gist_id}","starred_url":"https://api.github.com/users/PiotrSikora/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/PiotrSikora/subscriptions","organizations_url":"https://api.github.com/users/PiotrSikora/orgs","repos_url":"https://api.github.com/users/PiotrSikora/repos","events_url":"https://api.github.com/users/PiotrSikora/events{/privacy}","received_events_url":"https://api.github.com/users/PiotrSikora/received_events","type":"User","site_admin":false},"repo":{"id":70318420,"name":"envoy","full_name":"PiotrSikora/envoy","owner":{"login":"PiotrSikora","id":190297,"avatar_url":"https://avatars3.githubusercontent.com/u/190297?v=4","gravatar_id":"","url":"https://api.github.com/users/PiotrSikora","html_url":"https://github.com/PiotrSikora","followers_url":"https://api.github.com/users/PiotrSikora/followers","following_url":"https://api.github.com/users/PiotrSikora/following{/other_user}","gists_url":"https://api.github.com/users/PiotrSikora/gists{/gist_id}","starred_url":"https://api.github.com/users/PiotrSikora/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/PiotrSikora/subscriptions","organizations_url":"https://api.github.com/users/PiotrSikora/orgs","repos_url":"https://api.github.com/users/PiotrSikora/repos","events_url":"https://api.github.com/users/PiotrSikora/events{/privacy}","received_events_url":"https://api.github.com/users/PiotrSikora/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/PiotrSikora/envoy","description":"C++ front/service proxy","fork":true,"url":"https://api.github.com/repos/PiotrSikora/envoy","forks_url":"https://api.github.com/repos/PiotrSikora/envoy/forks","keys_url":"https://api.github.com/repos/PiotrSikora/envoy/keys{/key_id}","collaborators_url":"https://api.github.com/repos/PiotrSikora/envoy/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/PiotrSikora/envoy/teams","hooks_url":"https://api.github.com/repos/PiotrSikora/envoy/hooks","issue_events_url":"https://api.github.com/repos/PiotrSikora/envoy/issues/events{/number}","events_url":"https://api.github.com/repos/PiotrSikora/envoy/events","assignees_url":"https://api.github.com/repos/PiotrSikora/envoy/assignees{/user}","branches_url":"https://api.github.com/repos/PiotrSikora/envoy/branches{/branch}","tags_url":"https://api.github.com/repos/PiotrSikora/envoy/tags","blobs_url":"https://api.github.com/repos/PiotrSikora/envoy/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/PiotrSikora/envoy/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/PiotrSikora/envoy/git/refs{/sha}","trees_url":"https://api.github.com/repos/PiotrSikora/envoy/git/trees{/sha}","statuses_url":"https://api.github.com/repos/PiotrSikora/envoy/statuses/{sha}","languages_url":"https://api.github.com/repos/PiotrSikora/envoy/languages","stargazers_url":"https://api.github.com/repos/PiotrSikora/envoy/stargazers","contributors_url":"https://api.github.com/repos/PiotrSikora/envoy/contributors","subscribers_url":"https://api.github.com/repos/PiotrSikora/envoy/subscribers","subscription_url":"https://api.github.com/repos/PiotrSikora/envoy/subscription","commits_url":"https://api.github.com/repos/PiotrSikora/envoy/commits{/sha}","git_commits_url":"https://api.github.com/repos/PiotrSikora/envoy/git/commits{/sha}","comments_url":"https://api.github.com/repos/PiotrSikora/envoy/comments{/number}","issue_comment_url":"https://api.github.com/repos/PiotrSikora/envoy/issues/comments{/number}","contents_url":"https://api.github.com/repos/PiotrSikora/envoy/contents/{+path}","compare_url":"https://api.github.com/repos/PiotrSikora/envoy/compare/{base}...{head}","merges_url":"https://api.github.com/repos/PiotrSikora/envoy/merges","archive_url":"https://api.github.com/repos/PiotrSikora/envoy/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/PiotrSikora/envoy/downloads","issues_url":"https://api.github.com/repos/PiotrSikora/envoy/issues{/number}","pulls_url":"https://api.github.com/repos/PiotrSikora/envoy/pulls{/number}","milestones_url":"https://api.github.com/repos/PiotrSikora/envoy/milestones{/number}","notifications_url":"https://api.github.com/repos/PiotrSikora/envoy/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/PiotrSikora/envoy/labels{/name}","releases_url":"https://api.github.com/repos/PiotrSikora/envoy/releases{/id}","deployments_url":"https://api.github.com/repos/PiotrSikora/envoy/deployments","created_at":"2016-10-08T08:57:14Z","updated_at":"2016-10-08T08:57:16Z","pushed_at":"2017-12-21T05:29:32Z","git_url":"git://github.com/PiotrSikora/envoy.git","ssh_url":"git@github.com:PiotrSikora/envoy.git","clone_url":"https://github.com/PiotrSikora/envoy.git","svn_url":"https://github.com/PiotrSikora/envoy","homepage":"https://lyft.github.io/envoy","size":12247,"stargazers_count":0,"watchers_count":0,"language":"C++","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":null,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"envoyproxy:master","ref":"master","sha":"28622861b90eb550e8d4f82087f7055b9bac04fa","user":{"login":"envoyproxy","id":30125649,"avatar_url":"https://avatars1.githubusercontent.com/u/30125649?v=4","gravatar_id":"","url":"https://api.github.com/users/envoyproxy","html_url":"https://github.com/envoyproxy","followers_url":"https://api.github.com/users/envoyproxy/followers","following_url":"https://api.github.com/users/envoyproxy/following{/other_user}","gists_url":"https://api.github.com/users/envoyproxy/gists{/gist_id}","starred_url":"https://api.github.com/users/envoyproxy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/envoyproxy/subscriptions","organizations_url":"https://api.github.com/users/envoyproxy/orgs","repos_url":"https://api.github.com/users/envoyproxy/repos","events_url":"https://api.github.com/users/envoyproxy/events{/privacy}","received_events_url":"https://api.github.com/users/envoyproxy/received_events","type":"Organization","site_admin":false},"repo":{"id":65214191,"name":"envoy","full_name":"envoyproxy/envoy","owner":{"login":"envoyproxy","id":30125649,"avatar_url":"https://avatars1.githubusercontent.com/u/30125649?v=4","gravatar_id":"","url":"https://api.github.com/users/envoyproxy","html_url":"https://github.com/envoyproxy","followers_url":"https://api.github.com/users/envoyproxy/followers","following_url":"https://api.github.com/users/envoyproxy/following{/other_user}","gists_url":"https://api.github.com/users/envoyproxy/gists{/gist_id}","starred_url":"https://api.github.com/users/envoyproxy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/envoyproxy/subscriptions","organizations_url":"https://api.github.com/users/envoyproxy/orgs","repos_url":"https://api.github.com/users/envoyproxy/repos","events_url":"https://api.github.com/users/envoyproxy/events{/privacy}","received_events_url":"https://api.github.com/users/envoyproxy/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/envoyproxy/envoy","description":"C++ front/service proxy","fork":false,"url":"https://api.github.com/repos/envoyproxy/envoy","forks_url":"https://api.github.com/repos/envoyproxy/envoy/forks","keys_url":"https://api.github.com/repos/envoyproxy/envoy/keys{/key_id}","collaborators_url":"https://api.github.com/repos/envoyproxy/envoy/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/envoyproxy/envoy/teams","hooks_url":"https://api.github.com/repos/envoyproxy/envoy/hooks","issue_events_url":"https://api.github.com/repos/envoyproxy/envoy/issues/events{/number}","events_url":"https://api.github.com/repos/envoyproxy/envoy/events","assignees_url":"https://api.github.com/repos/envoyproxy/envoy/assignees{/user}","branches_url":"https://api.github.com/repos/envoyproxy/envoy/branches{/branch}","tags_url":"https://api.github.com/repos/envoyproxy/envoy/tags","blobs_url":"https://api.github.com/repos/envoyproxy/envoy/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/envoyproxy/envoy/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/envoyproxy/envoy/git/refs{/sha}","trees_url":"https://api.github.com/repos/envoyproxy/envoy/git/trees{/sha}","statuses_url":"https://api.github.com/repos/envoyproxy/envoy/statuses/{sha}","languages_url":"https://api.github.com/repos/envoyproxy/envoy/languages","stargazers_url":"https://api.github.com/repos/envoyproxy/envoy/stargazers","contributors_url":"https://api.github.com/repos/envoyproxy/envoy/contributors","subscribers_url":"https://api.github.com/repos/envoyproxy/envoy/subscribers","subscription_url":"https://api.github.com/repos/envoyproxy/envoy/subscription","commits_url":"https://api.github.com/repos/envoyproxy/envoy/commits{/sha}","git_commits_url":"https://api.github.com/repos/envoyproxy/envoy/git/commits{/sha}","comments_url":"https://api.github.com/repos/envoyproxy/envoy/comments{/number}","issue_comment_url":"https://api.github.com/repos/envoyproxy/envoy/issues/comments{/number}","contents_url":"https://api.github.com/repos/envoyproxy/envoy/contents/{+path}","compare_url":"https://api.github.com/repos/envoyproxy/envoy/compare/{base}...{head}","merges_url":"https://api.github.com/repos/envoyproxy/envoy/merges","archive_url":"https://api.github.com/repos/envoyproxy/envoy/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/envoyproxy/envoy/downloads","issues_url":"https://api.github.com/repos/envoyproxy/envoy/issues{/number}","pulls_url":"https://api.github.com/repos/envoyproxy/envoy/pulls{/number}","milestones_url":"https://api.github.com/repos/envoyproxy/envoy/milestones{/number}","notifications_url":"https://api.github.com/repos/envoyproxy/envoy/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/envoyproxy/envoy/labels{/name}","releases_url":"https://api.github.com/repos/envoyproxy/envoy/releases{/id}","deployments_url":"https://api.github.com/repos/envoyproxy/envoy/deployments","created_at":"2016-08-08T15:07:24Z","updated_at":"2017-12-22T00:08:14Z","pushed_at":"2017-12-22T00:52:40Z","git_url":"git://github.com/envoyproxy/envoy.git","ssh_url":"git@github.com:envoyproxy/envoy.git","clone_url":"https://github.com/envoyproxy/envoy.git","svn_url":"https://github.com/envoyproxy/envoy","homepage":"https://envoyproxy.github.io/","size":51510,"stargazers_count":3311,"watchers_count":3311,"language":"C++","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":true,"forks_count":391,"mirror_url":null,"archived":false,"open_issues_count":201,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0"},"forks":391,"open_issues":201,"watchers":3311,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/envoyproxy/envoy/pulls/2248"},"html":{"href":"https://github.com/envoyproxy/envoy/pull/2248"},"issue":{"href":"https://api.github.com/repos/envoyproxy/envoy/issues/2248"},"comments":{"href":"https://api.github.com/repos/envoyproxy/envoy/issues/2248/comments"},"review_comments":{"href":"https://api.github.com/repos/envoyproxy/envoy/pulls/2248/comments"},"review_comment":{"href":"https://api.github.com/repos/envoyproxy/envoy/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/envoyproxy/envoy/pulls/2248/commits"},"statuses":{"href":"https://api.github.com/repos/envoyproxy/envoy/statuses/0241759e472629490a50e434ae712c16bb5af7b4"}},"author_association":"MEMBER"}}
{"actor":{"display_login":"PiotrSikora"}}