diff options
author | EKR <ekr@rtfm.com> | 2016-08-15 09:08:51 -0700 |
---|---|---|
committer | EKR <ekr@rtfm.com> | 2016-08-15 09:08:51 -0700 |
commit | 0109d246f164cefc3e680492457ea582f299b609 (patch) | |
tree | f25128e24d93e7852aaee5dd6b5dc99bf23857df | |
parent | d0001b7c26609e0173af596de9ea16aa63c505df (diff) | |
download | nss-hg-0109d246f164cefc3e680492457ea582f299b609.tar.gz |
Bustage fix. clang-format. r=me
-rw-r--r-- | lib/ssl/ssl3con.c | 10 | ||||
-rw-r--r-- | lib/ssl/ssl3ext.c | 32 | ||||
-rw-r--r-- | lib/ssl/sslimpl.h | 2 | ||||
-rw-r--r-- | lib/ssl/tls13con.c | 4 |
4 files changed, 24 insertions, 24 deletions
diff --git a/lib/ssl/ssl3con.c b/lib/ssl/ssl3con.c index eb6809916..4e7d36d63 100644 --- a/lib/ssl/ssl3con.c +++ b/lib/ssl/ssl3con.c @@ -3852,7 +3852,7 @@ ssl3_HandleAlert(sslSocket *ss, sslBuffer *buf) if (ss->version >= SSL_LIBRARY_VERSION_TLS_1_3) { /* TLS 1.3 requires all but "end of data" alerts to be * treated as fatal. */ - switch (desc){ + switch (desc) { case close_notify: case user_canceled: case end_of_early_data: @@ -7165,8 +7165,8 @@ ssl3_HandleServerHello(sslSocket *ss, SSL3Opaque *b, PRUint32 length) downgradeCheckVersion > ss->version) { /* Both sections use the same sentinel region. */ unsigned char *downgrade_sentinel = - ss->ssl3.hs.server_random.rand + - SSL3_RANDOM_LENGTH - sizeof(tls13_downgrade_random); + ss->ssl3.hs.server_random.rand + + SSL3_RANDOM_LENGTH - sizeof(tls13_downgrade_random); if (!PORT_Memcmp(downgrade_sentinel, tls13_downgrade_random, sizeof(tls13_downgrade_random)) || @@ -8975,8 +8975,8 @@ ssl3_HandleClientHello(sslSocket *ss, SSL3Opaque *b, PRUint32 length) */ if (ss->vrange.max > ss->version) { unsigned char *downgrade_sentinel = - ss->ssl3.hs.server_random.rand + - SSL3_RANDOM_LENGTH - sizeof(tls13_downgrade_random); + ss->ssl3.hs.server_random.rand + + SSL3_RANDOM_LENGTH - sizeof(tls13_downgrade_random); switch (ss->vrange.max) { case SSL_LIBRARY_VERSION_TLS_1_3: diff --git a/lib/ssl/ssl3ext.c b/lib/ssl/ssl3ext.c index 8ac9edadb..9a869f18d 100644 --- a/lib/ssl/ssl3ext.c +++ b/lib/ssl/ssl3ext.c @@ -1143,7 +1143,7 @@ ssl3_ClientSendStatusRequestXtn(sslSocket *ss, PRBool append, */ SECStatus ssl3_EncodeSessionTicket(sslSocket *ss, - const NewSessionTicket* ticket, + const NewSessionTicket *ticket, SECItem *ticket_data) { PRUint32 i; @@ -1259,21 +1259,21 @@ ssl3_EncodeSessionTicket(sslSocket *ss, } ciphertext_length = - sizeof(PRUint16) /* ticket_version */ - + sizeof(SSL3ProtocolVersion) /* ssl_version */ - + sizeof(ssl3CipherSuite) /* ciphersuite */ - + 1 /* compression */ - + 10 /* cipher spec parameters */ - + 1 /* certType arguments */ - + 1 /* SessionTicket.ms_is_wrapped */ - + 4 /* msWrapMech */ - + 2 /* master_secret.length */ - + ms_item.len /* master_secret */ - + 1 /* client_auth_type */ - + cert_length /* cert */ - + 1 /* server name type */ - + srvNameLen /* name len + length field */ - + 1 /* extendedMasterSecretUsed */ + sizeof(PRUint16) /* ticket_version */ + + sizeof(SSL3ProtocolVersion) /* ssl_version */ + + sizeof(ssl3CipherSuite) /* ciphersuite */ + + 1 /* compression */ + + 10 /* cipher spec parameters */ + + 1 /* certType arguments */ + + 1 /* SessionTicket.ms_is_wrapped */ + + 4 /* msWrapMech */ + + 2 /* master_secret.length */ + + ms_item.len /* master_secret */ + + 1 /* client_auth_type */ + + cert_length /* cert */ + + 1 /* server name type */ + + srvNameLen /* name len + length field */ + + 1 /* extendedMasterSecretUsed */ + sizeof(ticket->ticket_lifetime_hint) + sizeof(ticket->flags) + 1 + alpnSelection.len; /* npn value + length field. */ padding_length = AES_BLOCK_SIZE - (ciphertext_length % diff --git a/lib/ssl/sslimpl.h b/lib/ssl/sslimpl.h index 21889c639..b44d5d9bd 100644 --- a/lib/ssl/sslimpl.h +++ b/lib/ssl/sslimpl.h @@ -1855,7 +1855,7 @@ extern PRBool ssl3_ExtensionNegotiated(sslSocket *ss, PRUint16 ex_type); extern void ssl3_SetSIDSessionTicket(sslSessionID *sid, /*in/out*/ NewSessionTicket *session_ticket); SECStatus ssl3_EncodeSessionTicket(sslSocket *ss, - const NewSessionTicket* ticket_input, + const NewSessionTicket *ticket_input, SECItem *ticket_data); extern PRBool ssl_GetSessionTicketKeys(unsigned char *keyName, unsigned char *encKey, unsigned char *macKey); diff --git a/lib/ssl/tls13con.c b/lib/ssl/tls13con.c index d865ae72d..6dac7d92a 100644 --- a/lib/ssl/tls13con.c +++ b/lib/ssl/tls13con.c @@ -3017,7 +3017,7 @@ tls13_SendNewSessionTicket(sslSocket *ss) SECItem ticket_data = { 0, NULL, 0 }; PRUint32 flags = ticket_allow_dhe_resumption; SECStatus rv; - NewSessionTicket ticket = {0}; + NewSessionTicket ticket = { 0 }; ticket.flags = 0; if (ss->opt.enable0RttData) { @@ -3025,7 +3025,7 @@ tls13_SendNewSessionTicket(sslSocket *ss) } ticket.ticket_lifetime_hint = TLS_EX_SESS_TICKET_LIFETIME_HINT; /* Generate a random value to add to ticket age. */ - rv = PK11_GenerateRandom((PRUint8*)&ticket.ticket_age_add, + rv = PK11_GenerateRandom((PRUint8 *)&ticket.ticket_age_add, sizeof(ticket.ticket_age_add)); if (rv != SECSuccess) goto loser; |