TSSslSecretSet¶
Set the data associated with a secret name specified in the config.
Synopsis¶
#include <ts/ts.h>
-
TSReturnCode TSSslSecretSet(const char *secret_name, int secret_name_length, const char *secret_data, int secret_data_length)¶
Description¶
TSSslSecretSet()
updates the current secret map. Generally the secret name corresponds to the name of a certificate or a key.
Future creation of SSL_CTX objects that use the secret will use the newly specified data. It can be useful to call this function
from the TS_LIFECYCLE_SSL_SECRET_HOOK
.
TSSslSecretGet¶
Get the data associated with a secret name specified in the config.
Synopsis¶
#include <ts/ts.h>
-
char *TSSslSecretGet(const char *secret_name, int secret_name_length, int *secret_data_length)¶
Description¶
TSSslSecretGet()
fetches the named secret from the current secret map. If there is no secret with the
given name, the returned pointer will be null, and the secret_data_length output parameter will be set to zero. If
the returned pointer is not null, it points to a buffer containing the secret data. The secret_data_length output
parameter will be set to the length of the secret data. The buffer containing the data must be freed by
calling TSfree()
.
TSSslSecretUpdate¶
Tell Traffic Server to update the SSL objects dependent on the secret.
Synopsis¶
#include <ts/ts.h>
-
TSReturnCode TSSslSecretUpdate(const char *secret_name, int secret_name_length)¶
Description¶
TSSslSecretUpdate()
causes Traffic Server to update the SSL objects that depend on the specified secret. This enables a plugin to look for
multiple secret updates and make calls to TSSslSecretSet()
to update the secret table. Then once everything is updated call
TSSslSecretUpdate()
to update the SSL objects with a consistent updated set of secrets.