Bläddra i källkod

tls_change_cipher() can complain about null cipher and digest

algorithms; we only need the pubkey check disabled (and only because
pubkey algorithms are not yet integrated into the crypto_algorithm
subsystem).
tags/v0.9.3
Michael Brown 17 år sedan
förälder
incheckning
847ac4f336
1 ändrade filer med 2 tillägg och 4 borttagningar
  1. 2
    4
      src/net/tls.c

+ 2
- 4
src/net/tls.c Visa fil

@@ -498,16 +498,14 @@ static int tls_change_cipher ( struct tls_session *tls,
498 498
 			       struct tls_cipherspec *pending,
499 499
 			       struct tls_cipherspec *active ) {
500 500
 
501
-	/* FIXME: Why is this disabled? */
502
-#if 0
503 501
 	/* Sanity check */
504
-	if ( ( pending->pubkey == &crypto_null ) ||
502
+	if ( /* FIXME (when pubkey is not hard-coded to RSA):
503
+	      * ( pending->pubkey == &crypto_null ) || */
505 504
 	     ( pending->cipher == &crypto_null ) ||
506 505
 	     ( pending->digest == &crypto_null ) ) {
507 506
 		DBGC ( tls, "TLS %p refusing to use null cipher\n", tls );
508 507
 		return -ENOTSUP;
509 508
 	}
510
-#endif
511 509
 
512 510
 	tls_clear_cipher ( tls, active );
513 511
 	memswap ( active, pending, sizeof ( *active ) );

Laddar…
Avbryt
Spara