Todd Lipcon has submitted this change and it was merged.

Change subject: ca: allow creating a self-signed CA
......................................................................


ca: allow creating a self-signed CA

This adds the ability to initialize a CertSigner in a self-signed mode.
In this mode, the issuer on the generated cert is set to the subject in
the CSR.

This required a bit of reworking of the initialization sequence for
CertSigner. Now instead of exclusively owning a Key/Cert, it uses
shared_ptrs to share ownership.

Along the way, also changed the Init() methods to enforce that they're
only called once. This invalidated one of the existing test cases, but
is simpler to understand, and there weren't any real use cases to do
initialization from multiple threads.

Change-Id: If8bfa3cc014f1c671ced549a8297ba46065e1124
Reviewed-on: http://gerrit.cloudera.org:8080/5765
Tested-by: Kudu Jenkins
Reviewed-by: Alexey Serbin <[email protected]>
Reviewed-by: Dan Burkert <[email protected]>
---
M src/kudu/security/ca/cert_management.cc
M src/kudu/security/ca/cert_management.h
M src/kudu/security/test/cert_management-test.cc
3 files changed, 167 insertions(+), 109 deletions(-)

Approvals:
  Dan Burkert: Looks good to me, approved
  Alexey Serbin: Looks good to me, approved
  Kudu Jenkins: Verified



-- 
To view, visit http://gerrit.cloudera.org:8080/5765
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: If8bfa3cc014f1c671ced549a8297ba46065e1124
Gerrit-PatchSet: 3
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-Owner: Todd Lipcon <[email protected]>
Gerrit-Reviewer: Alexey Serbin <[email protected]>
Gerrit-Reviewer: Dan Burkert <[email protected]>
Gerrit-Reviewer: Kudu Jenkins
Gerrit-Reviewer: Todd Lipcon <[email protected]>

Reply via email to