"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "src/main/cb.c" between
freeradius-server-3.0.22.tar.bz2 and freeradius-server-3.0.23.tar.bz2

About: FreeRADIUS Server Project - a high performance and highly configurable RADIUS server.

cb.c  (freeradius-server-3.0.22.tar.bz2):cb.c  (freeradius-server-3.0.23.tar.bz2)
/* /*
* cb.c * cb.c
* *
* Version: $Id: cd0d3b6c99909db98b0785f366ba0ac77d68f8be $ * Version: $Id: ec8e77aa006ec06a98a9aa8db4c73c7fd087d901 $
* *
* This program is free software; you can redistribute it and/or modify * This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by * it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or * the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version. * (at your option) any later version.
* *
* This program is distributed in the hope that it will be useful, * This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of * but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details. * GNU General Public License for more details.
* *
* You should have received a copy of the GNU General Public License * You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software * along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
* *
* Copyright 2001 hereUare Communications, Inc. <raghud@hereuare.com> * Copyright 2001 hereUare Communications, Inc. <raghud@hereuare.com>
* Copyright 2006 The FreeRADIUS server project * Copyright 2006 The FreeRADIUS server project
*/ */
RCSID("$Id: cd0d3b6c99909db98b0785f366ba0ac77d68f8be $") RCSID("$Id: ec8e77aa006ec06a98a9aa8db4c73c7fd087d901 $")
USES_APPLE_DEPRECATED_API /* OpenSSL API has been deprecated by Apple */ USES_APPLE_DEPRECATED_API /* OpenSSL API has been deprecated by Apple */
#include <freeradius-devel/radiusd.h> #include <freeradius-devel/radiusd.h>
#ifdef WITH_TLS #ifdef WITH_TLS
void cbtls_info(SSL const *s, int where, int ret) void cbtls_info(SSL const *s, int where, int ret)
{ {
char const *role, *state; char const *role, *state;
REQUEST *request = SSL_get_ex_data(s, FR_TLS_EX_INDEX_REQUEST); REQUEST *request = SSL_get_ex_data(s, FR_TLS_EX_INDEX_REQUEST);
skipping to change at line 61 skipping to change at line 61
STACK_OF(SSL_CIPHER) *client_ciphers; STACK_OF(SSL_CIPHER) *client_ciphers;
STACK_OF(SSL_CIPHER) *server_ciphers; STACK_OF(SSL_CIPHER) *server_ciphers;
#endif #endif
/* /*
* Trim crappy OpenSSL state strings... * Trim crappy OpenSSL state strings...
*/ */
len = strlen(abbrv); len = strlen(abbrv);
if ((len > 1) && (abbrv[len - 1] == ' ')) len--; if ((len > 1) && (abbrv[len - 1] == ' ')) len--;
RDEBUG3("(TLS) Handshake state [%.*s] - %s%s", (int)len, RDEBUG3("(TLS) Handshake state [%.*s] - %s%s (%d)",
abbrv, role, state); (int)len, abbrv, role, state, SSL_get_state(s));
/* /*
* After a ClientHello, list all the proposed cipher s from the client * After a ClientHello, list all the proposed cipher s from the client
*/ */
#if OPENSSL_VERSION_NUMBER >= 0x10100000L #if OPENSSL_VERSION_NUMBER >= 0x10100000L
if (SSL_get_state(s) == TLS_ST_SR_CLNT_HELLO) { if (SSL_get_state(s) == TLS_ST_SR_CLNT_HELLO) {
int i; int i;
int num_ciphers; int num_ciphers;
const SSL_CIPHER *this_cipher; const SSL_CIPHER *this_cipher;
skipping to change at line 94 skipping to change at line 95
RDEBUG3("Client preferred ciphers (by pri ority)"); RDEBUG3("Client preferred ciphers (by pri ority)");
num_ciphers = sk_SSL_CIPHER_num(client_ci phers); num_ciphers = sk_SSL_CIPHER_num(client_ci phers);
for (i = 0; i < num_ciphers; i++) { for (i = 0; i < num_ciphers; i++) {
this_cipher = sk_SSL_CIPHER_value (client_ciphers, i); this_cipher = sk_SSL_CIPHER_value (client_ciphers, i);
RDEBUG3("(TLS) [%i] %s", i, SS L_CIPHER_get_name(this_cipher)); RDEBUG3("(TLS) [%i] %s", i, SS L_CIPHER_get_name(this_cipher));
} }
} }
} }
#endif #endif
} else { } else {
RDEBUG2("(TLS) Handshake state - %s%s (%i)", role, state, SSL_get_state(s)); RDEBUG2("(TLS) Handshake state - %s%s", role, state);
} }
RDEBUG3("(TLS) %s: %s", role, state);
return; return;
} }
if (where & SSL_CB_ALERT) { if (where & SSL_CB_ALERT) {
if ((ret & 0xff) == SSL_AD_CLOSE_NOTIFY) return; if ((ret & 0xff) == SSL_AD_CLOSE_NOTIFY) return;
RERROR("(TLS) Alert %s:%s:%s", (where & SSL_CB_READ) ? "read": "w rite", RERROR("(TLS) Alert %s:%s:%s", (where & SSL_CB_READ) ? "read": "w rite",
SSL_alert_type_string_long(ret), SSL_alert_desc_string_lon g(ret)); SSL_alert_type_string_long(ret), SSL_alert_desc_string_lon g(ret));
return; return;
} }
 End of changes. 5 change blocks. 
6 lines changed or deleted 5 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)