Skip to content

Commit

Permalink
lib-auth: Include ssl protocol details in request when present
Browse files Browse the repository at this point in the history
  • Loading branch information
cmouse committed Dec 28, 2017
1 parent ff2f20b commit 8c79de4
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 0 deletions.
13 changes: 13 additions & 0 deletions src/lib-auth/auth-client-request.c
Expand Up @@ -88,6 +88,19 @@ static void auth_server_send_new_request(struct auth_server_connection *conn,
str_append(str, "\tlocal_name=");
str_append_tabescaped(str, info->local_name);
}
if (info->ssl_cipher_bits != 0 && info->ssl_cipher != NULL) {
str_append(str, "\tssl_cipher=");
str_append_tabescaped(str, info->ssl_cipher);
str_printfa(str, "\tssl_cipher_bits=%u", info->ssl_cipher_bits);
if (info->ssl_pfs != NULL) {
str_append(str, "\tssl_pfs=");
str_append_tabescaped(str, info->ssl_pfs);
}
}
if (info->ssl_protocol != NULL) {
str_append(str, "\tssl_protocol=");
str_append_tabescaped(str, info->ssl_protocol);
}
if (info->client_id != NULL &&
*info->client_id != '\0') {
str_append(str, "\tclient_id=");
Expand Down
6 changes: 6 additions & 0 deletions src/lib-auth/auth-client.h
Expand Up @@ -46,6 +46,12 @@ struct auth_request_info {
const char *local_name;
const char *client_id;
const char *forward_fields;

unsigned int ssl_cipher_bits;
const char *ssl_cipher;
const char *ssl_pfs;
const char *ssl_protocol;

enum auth_request_flags flags;

struct ip_addr local_ip, remote_ip, real_local_ip, real_remote_ip;
Expand Down

0 comments on commit 8c79de4

Please sign in to comment.