diff options
author | Julien Boeuf <jboeuf@google.com> | 2015-01-15 16:44:13 -0800 |
---|---|---|
committer | Julien Boeuf <jboeuf@google.com> | 2015-01-20 22:18:15 -0800 |
commit | 8fbcc4391ef8ea178520f2e15c07a505621244a6 (patch) | |
tree | fb55328c7de9e66c534a2e987f561794fc2e3ee3 /src/core/security/credentials.h | |
parent | 18d4a86982178ff7bbec345a9772184c713cda35 (diff) |
Changing the SSL (Server) Credentials API.
- Changed the unsigned char * + size to NULL terminated strings which
makes sense for the PEM format. I may change TSI later (but the impact
will hopefully be much more limited).
- Added a way to pass multiple key/cert pairs to servers which is needed
when hosting more than one domain.
- Removed the C++ SSL credentials tests as we are going to have an
option to not specify the roots which will then be derived from the
environment (well-known platform dependent locations and/or
environment variable).
- Fixed the php build which is the only one added in the run_test.py.
This change will certainly break node, python and ruby.
Diffstat (limited to 'src/core/security/credentials.h')
-rw-r--r-- | src/core/security/credentials.h | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/src/core/security/credentials.h b/src/core/security/credentials.h index 4a2532d7c4..8a9ff41e10 100644 --- a/src/core/security/credentials.h +++ b/src/core/security/credentials.h @@ -137,10 +137,17 @@ struct grpc_server_credentials { const char *type; }; -/* TODO(jboeuf): Have an ssl_server_config that can contain multiple key/cert - pairs. */ +typedef struct { + unsigned char **pem_private_keys; + size_t *pem_private_keys_sizes; + unsigned char **pem_cert_chains; + size_t *pem_cert_chains_sizes; + size_t num_key_cert_pairs; + unsigned char *pem_root_certs; + size_t pem_root_certs_size; +} grpc_ssl_server_config; -const grpc_ssl_config *grpc_ssl_server_credentials_get_config( +const grpc_ssl_server_config *grpc_ssl_server_credentials_get_config( const grpc_server_credentials *ssl_creds); #endif /* __GRPC_INTERNAL_SECURITY_CREDENTIALS_H__ */ |