Changeset 989 for vendor/current/libcli
- Timestamp:
- Nov 25, 2016, 8:04:54 PM (9 years ago)
- Location:
- vendor/current/libcli
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
vendor/current/libcli/auth/msrpc_parse.c
r988 r989 263 263 ps = va_arg(ap, char **); 264 264 if (len1 == 0 && len2 == 0) { 265 *ps = (char *)discard_const(""); 265 *ps = talloc_strdup(mem_ctx, ""); 266 if (*ps == NULL) { 267 ret = false; 268 goto cleanup; 269 } 266 270 } else { 267 271 /* make sure its in the right format - be strict */ … … 290 294 } 291 295 } else { 292 (*ps) = (char *)discard_const(""); 296 *ps = talloc_strdup(mem_ctx, ""); 297 if (*ps == NULL) { 298 ret = false; 299 goto cleanup; 300 } 293 301 } 294 302 } … … 303 311 /* make sure its in the right format - be strict */ 304 312 if (len1 == 0 && len2 == 0) { 305 *ps = (char *)discard_const(""); 313 *ps = talloc_strdup(mem_ctx, ""); 314 if (*ps == NULL) { 315 ret = false; 316 goto cleanup; 317 } 306 318 } else { 307 319 if ((len1 != len2) || (ptr + len1 < ptr) || (ptr + len1 < len1) || (ptr + len1 > blob->length)) { … … 326 338 } 327 339 } else { 328 (*ps) = (char *)discard_const(""); 340 *ps = talloc_strdup(mem_ctx, ""); 341 if (*ps == NULL) { 342 ret = false; 343 goto cleanup; 344 } 329 345 } 330 346 } -
vendor/current/libcli/cldap/cldap.c
r988 r989 586 586 talloc_set_destructor(state, cldap_search_state_destructor); 587 587 588 if (state->caller.cldap == NULL) { 589 tevent_req_nterror(req, NT_STATUS_INVALID_PARAMETER); 590 goto post; 591 } 592 588 593 if (io->in.dest_address) { 589 594 if (cldap->connected) { -
vendor/current/libcli/smb/smbXcli_base.c
r988 r989 5313 5313 } 5314 5314 5315 if (session->conn->mandatory_signing) { 5316 return false; 5317 } 5318 5315 5319 if (session->conn->protocol >= PROTOCOL_SMB2_02) { 5316 5320 if (session->smb2->session_flags & SMB2_SESSION_FLAG_IS_GUEST) { … … 5523 5527 } 5524 5528 5529 uint16_t smb2cli_session_current_channel_sequence(struct smbXcli_session *session) 5530 { 5531 return session->smb2->channel_sequence; 5532 } 5533 5525 5534 void smb2cli_session_start_replay(struct smbXcli_session *session) 5526 5535 { … … 5567 5576 { 5568 5577 struct smbXcli_conn *conn = session->conn; 5569 uint16_t no_sign_flags ;5578 uint16_t no_sign_flags = 0; 5570 5579 uint8_t session_key[16]; 5571 5580 bool check_signature = true; … … 5592 5601 } 5593 5602 5594 no_sign_flags = SMB2_SESSION_FLAG_IS_GUEST | SMB2_SESSION_FLAG_IS_NULL; 5603 if (!conn->mandatory_signing) { 5604 /* 5605 * only allow guest sessions without 5606 * mandatory signing. 5607 * 5608 * If we try an authentication with username != "" 5609 * and the server let us in without verifying the 5610 * password we don't have a negotiated session key 5611 * for signing. 5612 */ 5613 no_sign_flags = SMB2_SESSION_FLAG_IS_GUEST; 5614 } 5595 5615 5596 5616 if (session->smb2->session_flags & no_sign_flags) { -
vendor/current/libcli/smb/smbXcli_base.h
r988 r989 414 414 uint16_t smb2cli_session_reset_channel_sequence(struct smbXcli_session *session, 415 415 uint16_t channel_sequence); 416 uint16_t smb2cli_session_current_channel_sequence(struct smbXcli_session *session); 416 417 void smb2cli_session_start_replay(struct smbXcli_session *session); 417 418 void smb2cli_session_stop_replay(struct smbXcli_session *session);
Note:
See TracChangeset
for help on using the changeset viewer.