mirror of
https://github.com/zeek/zeek.git
synced 2025-10-02 14:48:21 +00:00
ldap: Clean up from code review
Co-authored-by: Benjamin Bannier <benjamin.bannier@corelight.com>
This commit is contained in:
parent
07bf7f8b18
commit
b8e573a3b9
3 changed files with 40 additions and 27 deletions
|
@ -376,17 +376,23 @@ event LDAP::bind_request(c: connection,
|
|||
if ( m?$opcode )
|
||||
Reporter::conn_weird("LDAP_bind_opcode_already_set", c, m$opcode, "LDAP");
|
||||
|
||||
if (authType == LDAP::BindAuthType_BIND_AUTH_SIMPLE) {
|
||||
switch ( authType ) {
|
||||
case LDAP::BindAuthType_BIND_AUTH_SIMPLE:
|
||||
m$opcode = BIND_SIMPLE;
|
||||
} else if (authType == LDAP::BindAuthType_BIND_AUTH_SASL) {
|
||||
break;
|
||||
case LDAP::BindAuthType_BIND_AUTH_SASL:
|
||||
m$opcode = BIND_SASL;
|
||||
} else if (authType == LDAP::BindAuthType_SICILY_NEGOTIATE ) {
|
||||
m$opcode = "sicily_negotiate";
|
||||
} else if (authType == LDAP::BindAuthType_SICILY_RESPONSE ) {
|
||||
m$opcode = "sicily_response";
|
||||
} else {
|
||||
break;
|
||||
case LDAP::BindAuthType_SICILY_NEGOTIATE:
|
||||
m$opcode = BIND_SICILY_NEGOTIATE;
|
||||
break;
|
||||
case LDAP::BindAuthType_SICILY_RESPONSE:
|
||||
m$opcode = BIND_SICILY_RESPONSE;
|
||||
break;
|
||||
default:
|
||||
Reporter::conn_weird("LDAP_unknown_auth_type", c, cat(authType), "LDAP");
|
||||
m$opcode = cat(authType);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue