(/home/sate/Testcases/c/cve/dovecot-1.2.0/src/auth/passdb.c) |
| |
| 131 | | | void passdb_handle_credentials(enum passdb_result result, |
| 132 | | | const char *password, const char *scheme, |
| 133 | | | lookup_credentials_callback_t *callback, |
| 134 | | | struct auth_request *auth_request) |
| 135 | | | { |
| 136 | | | const unsigned char *credentials; |
| 137 | | | size_t size = 0; |
| 138 | | | |
| 139 | | | if (result != PASSDB_RESULT_OK) { |
Event 1:
Skipping " if". result != PASSDB_RESULT_OK evaluates to false.
hide
|
|
| 140 | | | callback(result, NULL, 0, auth_request); |
| 141 | | | return; |
| 142 | | | } |
| 143 | | | |
| 144 | | | if (password == NULL) { |
Event 2:
Taking true branch. password == (void *)0 evaluates to true.
hide
|
|
| 145 | | | auth_request_log_info(auth_request, "password", |
| 146 | | | "Requested %s scheme, but we have a NULL password", |
| 147 | | | auth_request->credentials_scheme); |
| 148 | | | result = PASSDB_RESULT_SCHEME_NOT_AVAILABLE; |
| 149 | | | } else if (!passdb_get_credentials(auth_request, password, scheme, |
| 150 | | | &credentials, &size)) { |
| 151 | | | result = PASSDB_RESULT_SCHEME_NOT_AVAILABLE; |
| 152 | | | } |
| 153 | | | |
| 154 | | | callback(result, credentials, size, auth_request); |
Uninitialized Variable
credentials was not initialized. The issue can occur if the highlighted code executes. Show: All events | Only primary events |
|
| |