diff options
| author | Fabiano Fidêncio <fidencio@redhat.com> | 2015-09-17 10:26:05 +0200 |
|---|---|---|
| committer | Fabiano Fidêncio <fidencio@redhat.com> | 2015-10-12 13:56:21 +0200 |
| commit | 7ca95beaf3b73355ee1227a46f73d269197851a2 (patch) | |
| tree | a9fa58c7e8f16f8473038136cfc7744399e38b1d /src/server.c | |
| parent | 2f0ba0e574ed0968091e3dacc63712220a2ceb25 (diff) | |
| download | libssh-7ca95beaf3b73355ee1227a46f73d269197851a2.tar.gz libssh-7ca95beaf3b73355ee1227a46f73d269197851a2.tar.xz libssh-7ca95beaf3b73355ee1227a46f73d269197851a2.zip | |
cleanup: use ssh_ prefix in the dh (non-static) functions
Having "ssh_" prefix in the functions' name will avoid possible clashes
when compiling libssh statically.
Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com>
Diffstat (limited to 'src/server.c')
| -rw-r--r-- | src/server.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/server.c b/src/server.c index 351bae44..15ffd738 100644 --- a/src/server.c +++ b/src/server.c @@ -160,7 +160,7 @@ static int ssh_server_kexdh_init(ssh_session session, ssh_buffer packet){ ssh_set_error(session, SSH_FATAL, "No e number in client request"); return -1; } - if (dh_import_e(session, e) < 0) { + if (ssh_dh_import_e(session, e) < 0) { ssh_set_error(session, SSH_FATAL, "Cannot import e number"); session->session_state=SSH_SESSION_STATE_ERROR; } else { @@ -258,7 +258,7 @@ int ssh_get_key_params(ssh_session session, ssh_key *privkey){ return -1; } - dh_import_pubkey(session, pubkey_blob); + ssh_dh_import_pubkey(session, pubkey_blob); return SSH_OK; } @@ -268,16 +268,16 @@ static int dh_handshake_server(ssh_session session) { ssh_string f; int rc; - if (dh_generate_y(session) < 0) { + if (ssh_dh_generate_y(session) < 0) { ssh_set_error(session, SSH_FATAL, "Could not create y number"); return -1; } - if (dh_generate_f(session) < 0) { + if (ssh_dh_generate_f(session) < 0) { ssh_set_error(session, SSH_FATAL, "Could not create f number"); return -1; } - f = dh_get_f(session); + f = ssh_dh_get_f(session); if (f == NULL) { ssh_set_error(session, SSH_FATAL, "Could not get the f number"); return -1; @@ -288,13 +288,13 @@ static int dh_handshake_server(ssh_session session) { return -1; } - if (dh_build_k(session) < 0) { + if (ssh_dh_build_k(session) < 0) { ssh_set_error(session, SSH_FATAL, "Could not import the public key"); ssh_string_free(f); return -1; } - if (make_sessionid(session) != SSH_OK) { + if (ssh_make_sessionid(session) != SSH_OK) { ssh_set_error(session, SSH_FATAL, "Could not create a session id"); ssh_string_free(f); return -1; @@ -432,7 +432,7 @@ static void ssh_server_connection_callback(ssh_session session){ break; case SSH_SESSION_STATE_DH: if(session->dh_handshake_state==DH_STATE_FINISHED){ - if (generate_session_keys(session) < 0) { + if (ssh_generate_session_keys(session) < 0) { goto error; } |
