mirror of
https://github.com/samba-team/samba.git
synced 2025-01-19 10:03:58 +03:00
r13245: Don't segfault if we don't have a credentials structure on this gensec
context. Andrew Bartlett
This commit is contained in:
parent
8866aa06ff
commit
1e840aa436
@ -104,12 +104,15 @@ struct gensec_security_ops **gensec_security_mechs(struct gensec_security *gense
|
||||
talloc_reference(mem_ctx, backends);
|
||||
return backends;
|
||||
} else {
|
||||
enum credentials_use_kerberos use_kerberos;
|
||||
struct cli_credentials *creds = gensec_get_credentials(gensec_security);
|
||||
enum credentials_use_kerberos use_kerberos
|
||||
= cli_credentials_get_kerberos_state(creds);
|
||||
if (!creds) {
|
||||
talloc_reference(mem_ctx, backends);
|
||||
return backends;
|
||||
}
|
||||
use_kerberos = cli_credentials_get_kerberos_state(creds);
|
||||
return gensec_use_kerberos_mechs(mem_ctx, backends, use_kerberos);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
static const struct gensec_security_ops *gensec_security_by_authtype(struct gensec_security *gensec_security,
|
||||
|
Loading…
x
Reference in New Issue
Block a user