You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by mt...@apache.org on 2012/11/14 06:25:18 UTC
svn commit: r1409080 - in /tomcat/native/trunk/native/src: ssl.c
sslcontext.c sslext.c sslnetwork.c sslutils.c
Author: mturk
Date: Wed Nov 14 05:25:16 2012
New Revision: 1409080
URL: http://svn.apache.org/viewvc?rev=1409080&view=rev
Log:
Trim trailing spaces - No functional change
Modified:
tomcat/native/trunk/native/src/ssl.c
tomcat/native/trunk/native/src/sslcontext.c
tomcat/native/trunk/native/src/sslext.c
tomcat/native/trunk/native/src/sslnetwork.c
tomcat/native/trunk/native/src/sslutils.c
Modified: tomcat/native/trunk/native/src/ssl.c
URL: http://svn.apache.org/viewvc/tomcat/native/trunk/native/src/ssl.c?rev=1409080&r1=1409079&r2=1409080&view=diff
==============================================================================
--- tomcat/native/trunk/native/src/ssl.c (original)
+++ tomcat/native/trunk/native/src/ssl.c Wed Nov 14 05:25:16 2012
@@ -370,10 +370,10 @@ static struct CRYPTO_dynlock_value *ssl_
apr_pool_t *p;
apr_status_t rv;
- /*
+ /*
* We need a pool to allocate our mutex. Since we can't clear
* allocated memory from a pool, create a subpool that we can blow
- * away in the destruction callback.
+ * away in the destruction callback.
*/
rv = apr_pool_create(&p, dynlockpool);
if (rv != APR_SUCCESS) {
Modified: tomcat/native/trunk/native/src/sslcontext.c
URL: http://svn.apache.org/viewvc/tomcat/native/trunk/native/src/sslcontext.c?rev=1409080&r1=1409079&r2=1409080&view=diff
==============================================================================
--- tomcat/native/trunk/native/src/sslcontext.c (original)
+++ tomcat/native/trunk/native/src/sslcontext.c Wed Nov 14 05:25:16 2012
@@ -438,7 +438,7 @@ TCN_IMPLEMENT_CALL(void, SSLContext, set
X509_STORE_set_flags(c->store, 0);
}
else {
- /* XXX: See if this is fatal */
+ /* XXX: See if this is fatal */
}
}
Modified: tomcat/native/trunk/native/src/sslext.c
URL: http://svn.apache.org/viewvc/tomcat/native/trunk/native/src/sslext.c?rev=1409080&r1=1409079&r2=1409080&view=diff
==============================================================================
--- tomcat/native/trunk/native/src/sslext.c (original)
+++ tomcat/native/trunk/native/src/sslext.c Wed Nov 14 05:25:16 2012
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-/** SSL extensions - used for specialized taks - distributed session reuse,
+/** SSL extensions - used for specialized taks - distributed session reuse,
* NPN, etc. TODO: also add SNI.
*
* @author Costin Manolache
@@ -446,7 +446,7 @@ TCN_IMPLEMENT_CALL( jlong, SSLExt, sslSe
TCN_IMPLEMENT_CALL( jlong, SSLExt, sslCtxSetMode)(TCN_STDARGS, jlong tc_ssl_ctx, jlong jmode)
{
tcn_ssl_ctxt_t *sslctx = J2P(tc_ssl_ctx, tcn_ssl_ctxt_t *);
-
+
return (jlong) SSL_CTX_set_mode(sslctx->ctx, (long) jmode);
}
@@ -534,7 +534,7 @@ TCN_IMPLEMENT_CALL(jint, SSLExt, setSNI)
}
#endif
-#ifdef OPENSSL_NPN_NEGOTIATED
+#ifdef OPENSSL_NPN_NEGOTIATED
/* See ssl_client_socket_openssl.cc
tools/flip_server/spdy_ssl.cc
*/
@@ -592,7 +592,7 @@ TCN_IMPLEMENT_CALL(jint, SSLExt, setNPN)
return 0;
}
-/** Only valid after handshake
+/** Only valid after handshake
*/
TCN_IMPLEMENT_CALL(jint, SSLExt, getNPN)(TCN_STDARGS, jlong tcsock, jbyteArray buf)
{
Modified: tomcat/native/trunk/native/src/sslnetwork.c
URL: http://svn.apache.org/viewvc/tomcat/native/trunk/native/src/sslnetwork.c?rev=1409080&r1=1409079&r2=1409080&view=diff
==============================================================================
--- tomcat/native/trunk/native/src/sslnetwork.c (original)
+++ tomcat/native/trunk/native/src/sslnetwork.c Wed Nov 14 05:25:16 2012
@@ -103,7 +103,7 @@ static apr_status_t ssl_cleanup(void *da
con->pollset = NULL;
if (con->ssl) {
SSL *ssl = con->ssl;
- con->ssl = NULL;
+ con->ssl = NULL;
ssl_smart_shutdown(ssl, con->shutdown_type);
SSL_free(ssl);
}
@@ -180,19 +180,19 @@ static apr_status_t wait_for_io_or_timeo
apr_os_sock_t sock;
if (!con->pollset)
- return APR_ENOPOLL;
+ return APR_ENOPOLL;
if (!con->sock)
- return APR_ENOTSOCK;
+ return APR_ENOTSOCK;
if (con->reneg_state == RENEG_ABORT) {
con->shutdown_type = SSL_SHUTDOWN_TYPE_UNCLEAN;
return APR_ECONNABORTED;
}
-
+
/* Check if the socket was already closed
- */
- apr_os_sock_get(&sock, con->sock);
+ */
+ apr_os_sock_get(&sock, con->sock);
if (sock == APR_INVALID_SOCKET)
- return APR_ENOTSOCK;
+ return APR_ENOTSOCK;
/* Figure out the the poll direction */
switch (for_what) {
@@ -355,13 +355,13 @@ TCN_IMPLEMENT_CALL(jint, SSLSocket, hand
}
if (!con->ssl)
return APR_ENOTSOCK;
-
+
/*
* Check for failed client authentication
*/
if (con->ctx->verify_mode != SSL_VERIFY_NONE &&
(vr = SSL_get_verify_result(con->ssl)) != X509_V_OK) {
-
+
if (SSL_VERIFY_ERROR_IS_OPTIONAL(vr) &&
con->ctx->verify_mode == SSL_CVERIFY_OPTIONAL_NO_CA) {
/* TODO: Log optionalNoCA */
@@ -405,7 +405,7 @@ ssl_socket_recv(apr_socket_t *sock, char
apr_status_t os = apr_get_netos_error();
if (!con->ssl)
return os == APR_SUCCESS ? APR_ENOTSOCK : os;
-
+
i = SSL_get_error(con->ssl, s);
/* Special case if the "close notify" alert send by peer */
if (s == 0 && (con->ssl->shutdown & SSL_RECEIVED_SHUTDOWN)) {
@@ -477,7 +477,7 @@ ssl_socket_send(apr_socket_t *sock, cons
apr_status_t os = apr_get_netos_error();
if (!con->ssl)
return os == APR_SUCCESS ? APR_ENOTSOCK : os;
-
+
i = SSL_get_error(con->ssl, s);
switch (i) {
case SSL_ERROR_ZERO_RETURN:
@@ -581,8 +581,8 @@ TCN_IMPLEMENT_CALL(jint, SSLSocket, atta
if ((rv = apr_os_sock_get(&oss, s->sock)) != APR_SUCCESS)
return rv;
if (oss == APR_INVALID_SOCKET)
- return APR_ENOTSOCK;
-
+ return APR_ENOTSOCK;
+
if ((con = ssl_create(e, c, s->pool)) == NULL)
return APR_EGENERAL;
con->sock = s->sock;
@@ -617,15 +617,15 @@ TCN_IMPLEMENT_CALL(jint, SSLSocket, rene
* ssl->state = SSL_ST_ACCEPT
* SSL_do_handshake()
*/
-
+
/* Toggle the renegotiation state to allow the new
* handshake to proceed.
*/
- con->reneg_state = RENEG_ALLOW;
+ con->reneg_state = RENEG_ALLOW;
retVal = SSL_renegotiate(con->ssl);
if (retVal <= 0)
return APR_EGENERAL;
-
+
retVal = SSL_do_handshake(con->ssl);
if (retVal <= 0)
return APR_EGENERAL;
@@ -651,7 +651,7 @@ TCN_IMPLEMENT_CALL(jint, SSLSocket, rene
break;
}
con->reneg_state = RENEG_REJECT;
-
+
if (SSL_get_state(con->ssl) != SSL_ST_OK) {
return APR_EGENERAL;
}
Modified: tomcat/native/trunk/native/src/sslutils.c
URL: http://svn.apache.org/viewvc/tomcat/native/trunk/native/src/sslutils.c?rev=1409080&r1=1409079&r2=1409080&view=diff
==============================================================================
--- tomcat/native/trunk/native/src/sslutils.c (original)
+++ tomcat/native/trunk/native/src/sslutils.c Wed Nov 14 05:25:16 2012
@@ -693,8 +693,8 @@ void SSL_callback_handshake(const SSL *s
* read. */
if ((where & SSL_CB_ACCEPT_LOOP) && con->reneg_state == RENEG_REJECT) {
int state = SSL_get_state(ssl);
-
- if (state == SSL3_ST_SR_CLNT_HELLO_A
+
+ if (state == SSL3_ST_SR_CLNT_HELLO_A
|| state == SSL23_ST_SR_CLNT_HELLO_A) {
con->reneg_state = RENEG_ABORT;
/* XXX: rejecting client initiated renegotiation
@@ -708,5 +708,5 @@ void SSL_callback_handshake(const SSL *s
}
}
-
+
#endif
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org