mirror of
https://github.com/zeek/zeek.git
synced 2025-10-02 14:48:21 +00:00
Merge remote-tracking branch 'origin/topic/bernhard/ssl_ciphers_vector'
BIT-1011 #merged * origin/topic/bernhard/ssl_ciphers_vector: Change ciphers in changes ciphers from a set to a vector.
This commit is contained in:
commit
320f2d5ab6
9 changed files with 117 additions and 8 deletions
5
CHANGES
5
CHANGES
|
@ -1,4 +1,9 @@
|
||||||
|
|
||||||
|
2.2-40 | 2013-12-04 12:16:38 -0800
|
||||||
|
|
||||||
|
* ssl_client_hello() now receives a vector of ciphers, instead of a
|
||||||
|
set, to preserve their order. (Bernhard Amann)
|
||||||
|
|
||||||
2.2-38 | 2013-12-04 12:10:54 -0800
|
2.2-38 | 2013-12-04 12:10:54 -0800
|
||||||
|
|
||||||
* New script misc/dump-events.bro, along with core support, that
|
* New script misc/dump-events.bro, along with core support, that
|
||||||
|
|
15
NEWS
15
NEWS
|
@ -4,6 +4,21 @@ release. For an exhaustive list of changes, see the ``CHANGES`` file
|
||||||
(note that submodules, such as BroControl and Broccoli, come with
|
(note that submodules, such as BroControl and Broccoli, come with
|
||||||
their own ``CHANGES``.)
|
their own ``CHANGES``.)
|
||||||
|
|
||||||
|
Bro 2.3
|
||||||
|
=======
|
||||||
|
|
||||||
|
[In progress]
|
||||||
|
|
||||||
|
New Functionality
|
||||||
|
-----------------
|
||||||
|
|
||||||
|
|
||||||
|
Changed Functionality
|
||||||
|
---------------------
|
||||||
|
|
||||||
|
- ssl_client_hello() now receives a vector of ciphers, instead of a
|
||||||
|
set, to preserve their order.
|
||||||
|
|
||||||
Bro 2.2
|
Bro 2.2
|
||||||
=======
|
=======
|
||||||
|
|
||||||
|
|
2
VERSION
2
VERSION
|
@ -1 +1 @@
|
||||||
2.2-38
|
2.2-40
|
||||||
|
|
|
@ -153,7 +153,7 @@ function finish(c: connection)
|
||||||
disable_analyzer(c$id, c$ssl$analyzer_id);
|
disable_analyzer(c$id, c$ssl$analyzer_id);
|
||||||
}
|
}
|
||||||
|
|
||||||
event ssl_client_hello(c: connection, version: count, possible_ts: time, client_random: string, session_id: string, ciphers: count_set) &priority=5
|
event ssl_client_hello(c: connection, version: count, possible_ts: time, client_random: string, session_id: string, ciphers: index_vec) &priority=5
|
||||||
{
|
{
|
||||||
set_session(c);
|
set_session(c);
|
||||||
|
|
||||||
|
|
|
@ -26,7 +26,7 @@
|
||||||
##
|
##
|
||||||
## .. bro:see:: ssl_alert ssl_established ssl_extension ssl_server_hello
|
## .. bro:see:: ssl_alert ssl_established ssl_extension ssl_server_hello
|
||||||
## ssl_session_ticket_handshake x509_certificate x509_error x509_extension
|
## ssl_session_ticket_handshake x509_certificate x509_error x509_extension
|
||||||
event ssl_client_hello%(c: connection, version: count, possible_ts: time, client_random: string, session_id: string, ciphers: count_set%);
|
event ssl_client_hello%(c: connection, version: count, possible_ts: time, client_random: string, session_id: string, ciphers: index_vec%);
|
||||||
|
|
||||||
## Generated for an SSL/TLS server's initial *hello* message. SSL/TLS sessions
|
## Generated for an SSL/TLS server's initial *hello* message. SSL/TLS sessions
|
||||||
## start with an unencrypted handshake, and Bro extracts as much information out
|
## start with an unencrypted handshake, and Bro extracts as much information out
|
||||||
|
|
|
@ -168,19 +168,18 @@ refine connection SSL_Conn += {
|
||||||
else
|
else
|
||||||
std::transform(cipher_suites24->begin(), cipher_suites24->end(), std::back_inserter(*cipher_suites), to_int());
|
std::transform(cipher_suites24->begin(), cipher_suites24->end(), std::back_inserter(*cipher_suites), to_int());
|
||||||
|
|
||||||
TableVal* cipher_set = new TableVal(internal_type("count_set")->AsTableType());
|
VectorVal* cipher_vec = new VectorVal(internal_type("index_vec")->AsVectorType());
|
||||||
for ( unsigned int i = 0; i < cipher_suites->size(); ++i )
|
for ( unsigned int i = 0; i < cipher_suites->size(); ++i )
|
||||||
{
|
{
|
||||||
Val* ciph = new Val((*cipher_suites)[i], TYPE_COUNT);
|
Val* ciph = new Val((*cipher_suites)[i], TYPE_COUNT);
|
||||||
cipher_set->Assign(ciph, 0);
|
cipher_vec->Assign(i, ciph);
|
||||||
Unref(ciph);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
BifEvent::generate_ssl_client_hello(bro_analyzer(), bro_analyzer()->Conn(),
|
BifEvent::generate_ssl_client_hello(bro_analyzer(), bro_analyzer()->Conn(),
|
||||||
version, ts, new StringVal(client_random.length(),
|
version, ts, new StringVal(client_random.length(),
|
||||||
(const char*) client_random.data()),
|
(const char*) client_random.data()),
|
||||||
to_string_val(session_id),
|
to_string_val(session_id),
|
||||||
cipher_set);
|
cipher_vec);
|
||||||
|
|
||||||
delete cipher_suites;
|
delete cipher_suites;
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,81 @@
|
||||||
|
Got 80 cipher suites
|
||||||
|
TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384
|
||||||
|
TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384
|
||||||
|
TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384
|
||||||
|
TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA384
|
||||||
|
TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA
|
||||||
|
TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA
|
||||||
|
TLS_SRP_SHA_DSS_WITH_AES_256_CBC_SHA
|
||||||
|
TLS_SRP_SHA_RSA_WITH_AES_256_CBC_SHA
|
||||||
|
TLS_DHE_DSS_WITH_AES_256_GCM_SHA384
|
||||||
|
TLS_DHE_RSA_WITH_AES_256_GCM_SHA384
|
||||||
|
TLS_DHE_RSA_WITH_AES_256_CBC_SHA256
|
||||||
|
TLS_DHE_DSS_WITH_AES_256_CBC_SHA256
|
||||||
|
TLS_DHE_RSA_WITH_AES_256_CBC_SHA
|
||||||
|
TLS_DHE_DSS_WITH_AES_256_CBC_SHA
|
||||||
|
TLS_DHE_RSA_WITH_CAMELLIA_256_CBC_SHA
|
||||||
|
TLS_DHE_DSS_WITH_CAMELLIA_256_CBC_SHA
|
||||||
|
TLS_ECDH_RSA_WITH_AES_256_GCM_SHA384
|
||||||
|
TLS_ECDH_ECDSA_WITH_AES_256_GCM_SHA384
|
||||||
|
TLS_ECDH_RSA_WITH_AES_256_CBC_SHA384
|
||||||
|
TLS_ECDH_ECDSA_WITH_AES_256_CBC_SHA384
|
||||||
|
TLS_ECDH_RSA_WITH_AES_256_CBC_SHA
|
||||||
|
TLS_ECDH_ECDSA_WITH_AES_256_CBC_SHA
|
||||||
|
TLS_RSA_WITH_AES_256_GCM_SHA384
|
||||||
|
TLS_RSA_WITH_AES_256_CBC_SHA256
|
||||||
|
TLS_RSA_WITH_AES_256_CBC_SHA
|
||||||
|
TLS_RSA_WITH_CAMELLIA_256_CBC_SHA
|
||||||
|
TLS_ECDHE_RSA_WITH_3DES_EDE_CBC_SHA
|
||||||
|
TLS_ECDHE_ECDSA_WITH_3DES_EDE_CBC_SHA
|
||||||
|
TLS_SRP_SHA_DSS_WITH_3DES_EDE_CBC_SHA
|
||||||
|
TLS_SRP_SHA_RSA_WITH_3DES_EDE_CBC_SHA
|
||||||
|
TLS_DHE_RSA_WITH_3DES_EDE_CBC_SHA
|
||||||
|
TLS_DHE_DSS_WITH_3DES_EDE_CBC_SHA
|
||||||
|
TLS_ECDH_RSA_WITH_3DES_EDE_CBC_SHA
|
||||||
|
TLS_ECDH_ECDSA_WITH_3DES_EDE_CBC_SHA
|
||||||
|
TLS_RSA_WITH_3DES_EDE_CBC_SHA
|
||||||
|
TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256
|
||||||
|
TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256
|
||||||
|
TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256
|
||||||
|
TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256
|
||||||
|
TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA
|
||||||
|
TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA
|
||||||
|
TLS_SRP_SHA_DSS_WITH_AES_128_CBC_SHA
|
||||||
|
TLS_SRP_SHA_RSA_WITH_AES_128_CBC_SHA
|
||||||
|
TLS_DHE_DSS_WITH_AES_128_GCM_SHA256
|
||||||
|
TLS_DHE_RSA_WITH_AES_128_GCM_SHA256
|
||||||
|
TLS_DHE_RSA_WITH_AES_128_CBC_SHA256
|
||||||
|
TLS_DHE_DSS_WITH_AES_128_CBC_SHA256
|
||||||
|
TLS_DHE_RSA_WITH_AES_128_CBC_SHA
|
||||||
|
TLS_DHE_DSS_WITH_AES_128_CBC_SHA
|
||||||
|
TLS_DHE_RSA_WITH_SEED_CBC_SHA
|
||||||
|
TLS_DHE_DSS_WITH_SEED_CBC_SHA
|
||||||
|
TLS_DHE_RSA_WITH_CAMELLIA_128_CBC_SHA
|
||||||
|
TLS_DHE_DSS_WITH_CAMELLIA_128_CBC_SHA
|
||||||
|
TLS_ECDH_RSA_WITH_AES_128_GCM_SHA256
|
||||||
|
TLS_ECDH_ECDSA_WITH_AES_128_GCM_SHA256
|
||||||
|
TLS_ECDH_RSA_WITH_AES_128_CBC_SHA256
|
||||||
|
TLS_ECDH_ECDSA_WITH_AES_128_CBC_SHA256
|
||||||
|
TLS_ECDH_RSA_WITH_AES_128_CBC_SHA
|
||||||
|
TLS_ECDH_ECDSA_WITH_AES_128_CBC_SHA
|
||||||
|
TLS_RSA_WITH_AES_128_GCM_SHA256
|
||||||
|
TLS_RSA_WITH_AES_128_CBC_SHA256
|
||||||
|
TLS_RSA_WITH_AES_128_CBC_SHA
|
||||||
|
TLS_RSA_WITH_SEED_CBC_SHA
|
||||||
|
TLS_RSA_WITH_CAMELLIA_128_CBC_SHA
|
||||||
|
TLS_RSA_WITH_IDEA_CBC_SHA
|
||||||
|
TLS_ECDHE_RSA_WITH_RC4_128_SHA
|
||||||
|
TLS_ECDHE_ECDSA_WITH_RC4_128_SHA
|
||||||
|
TLS_ECDH_RSA_WITH_RC4_128_SHA
|
||||||
|
TLS_ECDH_ECDSA_WITH_RC4_128_SHA
|
||||||
|
TLS_RSA_WITH_RC4_128_SHA
|
||||||
|
TLS_RSA_WITH_RC4_128_MD5
|
||||||
|
TLS_DHE_RSA_WITH_DES_CBC_SHA
|
||||||
|
TLS_DHE_DSS_WITH_DES_CBC_SHA
|
||||||
|
TLS_RSA_WITH_DES_CBC_SHA
|
||||||
|
TLS_DHE_RSA_EXPORT_WITH_DES40_CBC_SHA
|
||||||
|
TLS_DHE_DSS_EXPORT_WITH_DES40_CBC_SHA
|
||||||
|
TLS_RSA_EXPORT_WITH_DES40_CBC_SHA
|
||||||
|
TLS_RSA_EXPORT_WITH_RC2_CBC_40_MD5
|
||||||
|
TLS_RSA_EXPORT_WITH_RC4_40_MD5
|
||||||
|
TLS_EMPTY_RENEGOTIATION_INFO_SCSV
|
|
@ -0,0 +1,9 @@
|
||||||
|
# @TEST-EXEC: bro -r $TRACES/tls1.2.trace %INPUT
|
||||||
|
# @TEST-EXEC: btest-diff .stdout
|
||||||
|
|
||||||
|
event ssl_client_hello(c: connection, version: count, possible_ts: time, client_random: string, session_id: string, ciphers: index_vec)
|
||||||
|
{
|
||||||
|
print fmt("Got %d cipher suites", |ciphers|);
|
||||||
|
for ( i in ciphers )
|
||||||
|
print SSL::cipher_desc[ciphers[i]];
|
||||||
|
}
|
|
@ -1,7 +1,7 @@
|
||||||
# @TEST-EXEC: bro -r $TRACES/tls1.2.trace %INPUT
|
# @TEST-EXEC: bro -r $TRACES/tls1.2.trace %INPUT
|
||||||
# @TEST-EXEC: btest-diff .stdout
|
# @TEST-EXEC: btest-diff .stdout
|
||||||
|
|
||||||
event ssl_client_hello(c: connection, version: count, possible_ts: time, client_random: string, session_id: string, ciphers: count_set)
|
event ssl_client_hello(c: connection, version: count, possible_ts: time, client_random: string, session_id: string, ciphers: index_vec)
|
||||||
{
|
{
|
||||||
print client_random;
|
print client_random;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue