[SCM] Samba Shared Repository - branch master updated
Andrew Bartlett
abartlet at samba.org
Thu Dec 29 06:15:03 MST 2011
The branch, master has been updated
via c76ffcf s4-toture: Rename memory contexts in rpc.pac for greater clarity
via e3f4a66 s4-gensec: Rename memory contexts in gensec_util for greater clarity
via 5316e86 s4-gensec: Rename memory contexts in gensec_krb5 for greater clarity
via a085446 s4-gensec: Rename memory contexts in gensec_gssapi for greater clarity
via 06bbb8a s4-auth: Rename memory contexts for greater clarity
via 2f0ba14 auth/kerberos: Rename memory contexts for greater clarity
from c2d6509 s4-gensec remove auth_session dep from gensec_gssapi.c
http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master
- Log -----------------------------------------------------------------
commit c76ffcf3c4e6e46a8ca62b355efc90ff3bf48d2d
Author: Andrew Bartlett <abartlet at samba.org>
Date: Thu Dec 29 22:36:14 2011 +1100
s4-toture: Rename memory contexts in rpc.pac for greater clarity
This should better follow the mem_ctx/tmp_ctx pattern used elsewhere in Samba.
Thankyou Simo for the suggestion.
Andrew Bartlett
Autobuild-User: Andrew Bartlett <abartlet at samba.org>
Autobuild-Date: Thu Dec 29 14:14:06 CET 2011 on sn-devel-104
commit e3f4a6692cd2e22ebd5d7be01719d2bc85cabe40
Author: Andrew Bartlett <abartlet at samba.org>
Date: Thu Dec 29 22:34:28 2011 +1100
s4-gensec: Rename memory contexts in gensec_util for greater clarity
This should better follow the mem_ctx/tmp_ctx pattern used elsewhere in Samba.
Thankyou Simo for the suggestion.
Andrew Bartlett
commit 5316e86f5c8e2aaf4cc58d9329c7f9d58156eb88
Author: Andrew Bartlett <abartlet at samba.org>
Date: Thu Dec 29 22:33:27 2011 +1100
s4-gensec: Rename memory contexts in gensec_krb5 for greater clarity
This should better follow the mem_ctx/tmp_ctx pattern used elsewhere in Samba.
Thankyou Simo for the suggestion.
Andrew Bartlett
commit a085446d0c204aecaad2c45b8364dc7c5b1cbc6e
Author: Andrew Bartlett <abartlet at samba.org>
Date: Thu Dec 29 22:31:36 2011 +1100
s4-gensec: Rename memory contexts in gensec_gssapi for greater clarity
This should better follow the mem_ctx/tmp_ctx pattern used elsewhere in Samba.
Thankyou Simo for the suggestion.
Andrew Bartlett
commit 06bbb8a6fb83ab68bb79301a1b3d0c87eec9f997
Author: Andrew Bartlett <abartlet at samba.org>
Date: Thu Dec 29 22:30:07 2011 +1100
s4-auth: Rename memory contexts for greater clarity
This should better follow the mem_ctx/tmp_ctx pattern used elsewhere in Samba.
Thankyou Simo for the suggestion.
Andrew Bartlett
commit 2f0ba1435da970b4a8fd2e1c735a75ee44edf2e2
Author: Andrew Bartlett <abartlet at samba.org>
Date: Thu Dec 29 22:26:06 2011 +1100
auth/kerberos: Rename memory contexts for greater clarity
This should better follow the mem_ctx/tmp_ctx pattern used elsewhere in Samba.
Thankyou Simo for the suggestion.
Andrew Bartlett
-----------------------------------------------------------------------
Summary of changes:
auth/kerberos/kerberos_pac.c | 68 +++++++++++++++++-----------------
source4/auth/auth.h | 2 +-
source4/auth/gensec/gensec_gssapi.c | 32 ++++++++--------
source4/auth/gensec/gensec_krb5.c | 32 ++++++++--------
source4/auth/gensec/gensec_util.c | 4 +-
source4/auth/ntlm/auth.c | 18 +++++-----
source4/torture/rpc/remote_pac.c | 26 +++++++-------
7 files changed, 91 insertions(+), 91 deletions(-)
Changeset truncated at 500 lines:
diff --git a/auth/kerberos/kerberos_pac.c b/auth/kerberos/kerberos_pac.c
index a262c01..97fce73 100644
--- a/auth/kerberos/kerberos_pac.c
+++ b/auth/kerberos/kerberos_pac.c
@@ -77,7 +77,7 @@ krb5_error_code check_pac_checksum(TALLOC_CTX *mem_ctx,
*
* @return - A NTSTATUS error code
*/
-NTSTATUS kerberos_decode_pac(TALLOC_CTX *mem_ctx_out,
+NTSTATUS kerberos_decode_pac(TALLOC_CTX *mem_ctx,
DATA_BLOB pac_data_blob,
krb5_context context,
const krb5_keyblock *krbtgt_keyblock,
@@ -109,8 +109,8 @@ NTSTATUS kerberos_decode_pac(TALLOC_CTX *mem_ctx_out,
bool bool_ret;
- TALLOC_CTX *mem_ctx = talloc_new(mem_ctx_out);
- if (!mem_ctx) {
+ TALLOC_CTX *tmp_ctx = talloc_new(mem_ctx);
+ if (!tmp_ctx) {
return NT_STATUS_NO_MEMORY;
}
@@ -118,12 +118,12 @@ NTSTATUS kerberos_decode_pac(TALLOC_CTX *mem_ctx_out,
*pac_data_out = NULL;
}
- pac_data = talloc(mem_ctx, struct PAC_DATA);
- pac_data_raw = talloc(mem_ctx, struct PAC_DATA_RAW);
- kdc_sig_wipe = talloc(mem_ctx, struct PAC_SIGNATURE_DATA);
- srv_sig_wipe = talloc(mem_ctx, struct PAC_SIGNATURE_DATA);
+ pac_data = talloc(tmp_ctx, struct PAC_DATA);
+ pac_data_raw = talloc(tmp_ctx, struct PAC_DATA_RAW);
+ kdc_sig_wipe = talloc(tmp_ctx, struct PAC_SIGNATURE_DATA);
+ srv_sig_wipe = talloc(tmp_ctx, struct PAC_SIGNATURE_DATA);
if (!pac_data_raw || !pac_data || !kdc_sig_wipe || !srv_sig_wipe) {
- talloc_free(mem_ctx);
+ talloc_free(tmp_ctx);
return NT_STATUS_NO_MEMORY;
}
@@ -133,14 +133,14 @@ NTSTATUS kerberos_decode_pac(TALLOC_CTX *mem_ctx_out,
status = ndr_map_error2ntstatus(ndr_err);
DEBUG(0,("can't parse the PAC: %s\n",
nt_errstr(status)));
- talloc_free(mem_ctx);
+ talloc_free(tmp_ctx);
return status;
}
if (pac_data->num_buffers < 4) {
/* we need logon_ingo, service_key and kdc_key */
DEBUG(0,("less than 4 PAC buffers\n"));
- talloc_free(mem_ctx);
+ talloc_free(tmp_ctx);
return NT_STATUS_INVALID_PARAMETER;
}
@@ -151,14 +151,14 @@ NTSTATUS kerberos_decode_pac(TALLOC_CTX *mem_ctx_out,
status = ndr_map_error2ntstatus(ndr_err);
DEBUG(0,("can't parse the PAC: %s\n",
nt_errstr(status)));
- talloc_free(mem_ctx);
+ talloc_free(tmp_ctx);
return status;
}
if (pac_data_raw->num_buffers < 4) {
/* we need logon_ingo, service_key and kdc_key */
DEBUG(0,("less than 4 PAC buffers\n"));
- talloc_free(mem_ctx);
+ talloc_free(tmp_ctx);
return NT_STATUS_INVALID_PARAMETER;
}
@@ -167,7 +167,7 @@ NTSTATUS kerberos_decode_pac(TALLOC_CTX *mem_ctx_out,
DEBUG(0, ("misparse! PAC_DATA has %d buffers while "
"PAC_DATA_RAW has %d\n", pac_data->num_buffers,
pac_data_raw->num_buffers));
- talloc_free(mem_ctx);
+ talloc_free(tmp_ctx);
return NT_STATUS_INVALID_PARAMETER;
}
@@ -179,7 +179,7 @@ NTSTATUS kerberos_decode_pac(TALLOC_CTX *mem_ctx_out,
DEBUG(0, ("misparse! PAC_DATA buffer %d has type "
"%d while PAC_DATA_RAW has %d\n", i,
data_buf->type, raw_buf->type));
- talloc_free(mem_ctx);
+ talloc_free(tmp_ctx);
return NT_STATUS_INVALID_PARAMETER;
}
switch (data_buf->type) {
@@ -213,25 +213,25 @@ NTSTATUS kerberos_decode_pac(TALLOC_CTX *mem_ctx_out,
if (!logon_info) {
DEBUG(0,("PAC no logon_info\n"));
- talloc_free(mem_ctx);
+ talloc_free(tmp_ctx);
return NT_STATUS_INVALID_PARAMETER;
}
if (!logon_name) {
DEBUG(0,("PAC no logon_name\n"));
- talloc_free(mem_ctx);
+ talloc_free(tmp_ctx);
return NT_STATUS_INVALID_PARAMETER;
}
if (!srv_sig_ptr || !srv_sig_blob) {
DEBUG(0,("PAC no srv_key\n"));
- talloc_free(mem_ctx);
+ talloc_free(tmp_ctx);
return NT_STATUS_INVALID_PARAMETER;
}
if (!kdc_sig_ptr || !kdc_sig_blob) {
DEBUG(0,("PAC no kdc_key\n"));
- talloc_free(mem_ctx);
+ talloc_free(tmp_ctx);
return NT_STATUS_INVALID_PARAMETER;
}
@@ -247,7 +247,7 @@ NTSTATUS kerberos_decode_pac(TALLOC_CTX *mem_ctx_out,
status = ndr_map_error2ntstatus(ndr_err);
DEBUG(0,("can't parse the KDC signature: %s\n",
nt_errstr(status)));
- talloc_free(mem_ctx);
+ talloc_free(tmp_ctx);
return status;
}
@@ -258,7 +258,7 @@ NTSTATUS kerberos_decode_pac(TALLOC_CTX *mem_ctx_out,
status = ndr_map_error2ntstatus(ndr_err);
DEBUG(0,("can't parse the SRV signature: %s\n",
nt_errstr(status)));
- talloc_free(mem_ctx);
+ talloc_free(tmp_ctx);
return status;
}
@@ -276,7 +276,7 @@ NTSTATUS kerberos_decode_pac(TALLOC_CTX *mem_ctx_out,
status = ndr_map_error2ntstatus(ndr_err);
DEBUG(0,("can't repack the KDC signature: %s\n",
nt_errstr(status)));
- talloc_free(mem_ctx);
+ talloc_free(tmp_ctx);
return status;
}
ndr_err = ndr_push_struct_blob(
@@ -286,7 +286,7 @@ NTSTATUS kerberos_decode_pac(TALLOC_CTX *mem_ctx_out,
status = ndr_map_error2ntstatus(ndr_err);
DEBUG(0,("can't repack the SRV signature: %s\n",
nt_errstr(status)));
- talloc_free(mem_ctx);
+ talloc_free(tmp_ctx);
return status;
}
@@ -298,13 +298,13 @@ NTSTATUS kerberos_decode_pac(TALLOC_CTX *mem_ctx_out,
status = ndr_map_error2ntstatus(ndr_err);
DEBUG(0,("can't repack the RAW PAC: %s\n",
nt_errstr(status)));
- talloc_free(mem_ctx);
+ talloc_free(tmp_ctx);
return status;
}
if (service_keyblock) {
/* verify by service_key */
- ret = check_pac_checksum(mem_ctx,
+ ret = check_pac_checksum(tmp_ctx,
modified_pac_blob, srv_sig_ptr,
context,
service_keyblock);
@@ -316,13 +316,13 @@ NTSTATUS kerberos_decode_pac(TALLOC_CTX *mem_ctx_out,
if (krbtgt_keyblock) {
/* verify the service key checksum by krbtgt_key */
- ret = check_pac_checksum(mem_ctx,
+ ret = check_pac_checksum(tmp_ctx,
srv_sig_ptr->signature, kdc_sig_ptr,
context, krbtgt_keyblock);
if (ret) {
DEBUG(1, ("PAC Decode: Failed to verify the KDC signature: %s\n",
- smb_get_krb5_error_message(context, ret, mem_ctx)));
- talloc_free(mem_ctx);
+ smb_get_krb5_error_message(context, ret, tmp_ctx)));
+ talloc_free(tmp_ctx);
return NT_STATUS_ACCESS_DENIED;
}
}
@@ -336,10 +336,10 @@ NTSTATUS kerberos_decode_pac(TALLOC_CTX *mem_ctx_out,
DEBUG(2, ("PAC Decode: "
"Logon time mismatch between ticket and PAC!\n"));
DEBUG(2, ("PAC Decode: PAC: %s\n",
- nt_time_string(mem_ctx, logon_name->logon_time)));
+ nt_time_string(tmp_ctx, logon_name->logon_time)));
DEBUG(2, ("PAC Decode: Ticket: %s\n",
- nt_time_string(mem_ctx, tgs_authtime_nttime)));
- talloc_free(mem_ctx);
+ nt_time_string(tmp_ctx, tgs_authtime_nttime)));
+ talloc_free(tmp_ctx);
return NT_STATUS_ACCESS_DENIED;
}
}
@@ -351,7 +351,7 @@ NTSTATUS kerberos_decode_pac(TALLOC_CTX *mem_ctx_out,
if (ret) {
DEBUG(2, ("Could not parse name from PAC: [%s]:%s\n",
logon_name->account_name, error_message(ret)));
- talloc_free(mem_ctx);
+ talloc_free(tmp_ctx);
return NT_STATUS_INVALID_PARAMETER;
}
@@ -364,7 +364,7 @@ NTSTATUS kerberos_decode_pac(TALLOC_CTX *mem_ctx_out,
if (!bool_ret) {
DEBUG(2, ("Name in PAC [%s] does not match principal name "
"in ticket\n", logon_name->account_name));
- talloc_free(mem_ctx);
+ talloc_free(tmp_ctx);
return NT_STATUS_ACCESS_DENIED;
}
}
@@ -377,14 +377,14 @@ NTSTATUS kerberos_decode_pac(TALLOC_CTX *mem_ctx_out,
if (DEBUGLEVEL >= 10) {
const char *s;
- s = NDR_PRINT_STRUCT_STRING(mem_ctx, PAC_DATA, pac_data);
+ s = NDR_PRINT_STRUCT_STRING(tmp_ctx, PAC_DATA, pac_data);
if (s) {
DEBUGADD(10,("%s\n", s));
}
}
if (pac_data_out) {
- *pac_data_out = talloc_steal(mem_ctx_out, pac_data);
+ *pac_data_out = talloc_steal(mem_ctx, pac_data);
}
return NT_STATUS_OK;
diff --git a/source4/auth/auth.h b/source4/auth/auth.h
index bb2cd57..0da16e4 100644
--- a/source4/auth/auth.h
+++ b/source4/auth/auth.h
@@ -137,7 +137,7 @@ struct auth4_context {
struct auth_session_info **session_info);
NTSTATUS (*generate_session_info_pac)(struct auth4_context *auth_ctx,
- TALLOC_CTX *mem_ctx_out,
+ TALLOC_CTX *mem_ctx,
struct smb_krb5_context *smb_krb5_context,
DATA_BLOB *pac_blob,
const char *principal_name,
diff --git a/source4/auth/gensec/gensec_gssapi.c b/source4/auth/gensec/gensec_gssapi.c
index 1e7a0a3..a037189 100644
--- a/source4/auth/gensec/gensec_gssapi.c
+++ b/source4/auth/gensec/gensec_gssapi.c
@@ -1300,11 +1300,11 @@ static NTSTATUS gensec_gssapi_session_key(struct gensec_security *gensec_securit
* this session. This uses either the PAC (if present) or a local
* database lookup */
static NTSTATUS gensec_gssapi_session_info(struct gensec_security *gensec_security,
- TALLOC_CTX *mem_ctx_out,
+ TALLOC_CTX *mem_ctx,
struct auth_session_info **_session_info)
{
NTSTATUS nt_status;
- TALLOC_CTX *mem_ctx;
+ TALLOC_CTX *tmp_ctx;
struct gensec_gssapi_state *gensec_gssapi_state
= talloc_get_type(gensec_security->private_data, struct gensec_gssapi_state);
struct auth_session_info *session_info = NULL;
@@ -1314,8 +1314,8 @@ static NTSTATUS gensec_gssapi_session_info(struct gensec_security *gensec_securi
gss_buffer_desc name_token;
char *principal_string;
- mem_ctx = talloc_named(mem_ctx_out, 0, "gensec_gssapi_session_info context");
- NT_STATUS_HAVE_NO_MEMORY(mem_ctx);
+ tmp_ctx = talloc_named(mem_ctx, 0, "gensec_gssapi_session_info context");
+ NT_STATUS_HAVE_NO_MEMORY(tmp_ctx);
maj_stat = gss_display_name (&min_stat,
gensec_gssapi_state->client_name,
@@ -1323,23 +1323,23 @@ static NTSTATUS gensec_gssapi_session_info(struct gensec_security *gensec_securi
NULL);
if (GSS_ERROR(maj_stat)) {
DEBUG(1, ("GSS display_name failed: %s\n",
- gssapi_error_string(mem_ctx, maj_stat, min_stat, gensec_gssapi_state->gss_oid)));
- talloc_free(mem_ctx);
+ gssapi_error_string(tmp_ctx, maj_stat, min_stat, gensec_gssapi_state->gss_oid)));
+ talloc_free(tmp_ctx);
return NT_STATUS_FOOBAR;
}
- principal_string = talloc_strndup(mem_ctx,
+ principal_string = talloc_strndup(tmp_ctx,
(const char *)name_token.value,
name_token.length);
gss_release_buffer(&min_stat, &name_token);
if (!principal_string) {
- talloc_free(mem_ctx);
+ talloc_free(tmp_ctx);
return NT_STATUS_NO_MEMORY;
}
- nt_status = gssapi_obtain_pac_blob(mem_ctx, gensec_gssapi_state->gssapi_context,
+ nt_status = gssapi_obtain_pac_blob(tmp_ctx, gensec_gssapi_state->gssapi_context,
gensec_gssapi_state->client_name,
&pac_blob);
@@ -1350,20 +1350,20 @@ static NTSTATUS gensec_gssapi_session_info(struct gensec_security *gensec_securi
if (NT_STATUS_IS_OK(nt_status)) {
pac_blob_ptr = &pac_blob;
}
- nt_status = gensec_generate_session_info_pac(mem_ctx,
+ nt_status = gensec_generate_session_info_pac(tmp_ctx,
gensec_security,
gensec_gssapi_state->smb_krb5_context,
pac_blob_ptr, principal_string,
gensec_get_remote_address(gensec_security),
&session_info);
if (!NT_STATUS_IS_OK(nt_status)) {
- talloc_free(mem_ctx);
+ talloc_free(tmp_ctx);
return nt_status;
}
nt_status = gensec_gssapi_session_key(gensec_security, session_info, &session_info->session_key);
if (!NT_STATUS_IS_OK(nt_status)) {
- talloc_free(mem_ctx);
+ talloc_free(tmp_ctx);
return nt_status;
}
@@ -1376,7 +1376,7 @@ static NTSTATUS gensec_gssapi_session_info(struct gensec_security *gensec_securi
DEBUG(10, ("gensec_gssapi: delegated credentials supplied by client\n"));
session_info->credentials = cli_credentials_init(session_info);
if (!session_info->credentials) {
- talloc_free(mem_ctx);
+ talloc_free(tmp_ctx);
return NT_STATUS_NO_MEMORY;
}
@@ -1389,7 +1389,7 @@ static NTSTATUS gensec_gssapi_session_info(struct gensec_security *gensec_securi
gensec_gssapi_state->delegated_cred_handle,
CRED_SPECIFIED, &error_string);
if (ret) {
- talloc_free(mem_ctx);
+ talloc_free(tmp_ctx);
DEBUG(2,("Failed to get gss creds: %s\n", error_string));
return NT_STATUS_NO_MEMORY;
}
@@ -1400,8 +1400,8 @@ static NTSTATUS gensec_gssapi_session_info(struct gensec_security *gensec_securi
/* It has been taken from this place... */
gensec_gssapi_state->delegated_cred_handle = GSS_C_NO_CREDENTIAL;
}
- *_session_info = talloc_steal(mem_ctx_out, session_info);
- talloc_free(mem_ctx);
+ *_session_info = talloc_steal(mem_ctx, session_info);
+ talloc_free(tmp_ctx);
return NT_STATUS_OK;
}
diff --git a/source4/auth/gensec/gensec_krb5.c b/source4/auth/gensec/gensec_krb5.c
index d5f5f8a..573a4c9 100644
--- a/source4/auth/gensec/gensec_krb5.c
+++ b/source4/auth/gensec/gensec_krb5.c
@@ -612,7 +612,7 @@ static NTSTATUS gensec_krb5_session_key(struct gensec_security *gensec_security,
}
static NTSTATUS gensec_krb5_session_info(struct gensec_security *gensec_security,
- TALLOC_CTX *mem_ctx_out,
+ TALLOC_CTX *mem_ctx,
struct auth_session_info **_session_info)
{
NTSTATUS nt_status = NT_STATUS_UNSUCCESSFUL;
@@ -628,8 +628,8 @@ static NTSTATUS gensec_krb5_session_info(struct gensec_security *gensec_security
krb5_error_code ret;
- TALLOC_CTX *mem_ctx = talloc_new(mem_ctx_out);
- if (!mem_ctx) {
+ TALLOC_CTX *tmp_ctx = talloc_new(mem_ctx);
+ if (!tmp_ctx) {
return NT_STATUS_NO_MEMORY;
}
@@ -637,8 +637,8 @@ static NTSTATUS gensec_krb5_session_info(struct gensec_security *gensec_security
if (ret) {
DEBUG(5, ("krb5_ticket_get_client failed to get cleint principal: %s\n",
smb_get_krb5_error_message(context,
- ret, mem_ctx)));
- talloc_free(mem_ctx);
+ ret, tmp_ctx)));
+ talloc_free(tmp_ctx);
return NT_STATUS_NO_MEMORY;
}
@@ -647,9 +647,9 @@ static NTSTATUS gensec_krb5_session_info(struct gensec_security *gensec_security
if (ret) {
DEBUG(1, ("Unable to parse client principal: %s\n",
smb_get_krb5_error_message(context,
- ret, mem_ctx)));
+ ret, tmp_ctx)));
krb5_free_principal(context, client_principal);
- talloc_free(mem_ctx);
+ talloc_free(tmp_ctx);
return NT_STATUS_NO_MEMORY;
}
@@ -661,14 +661,14 @@ static NTSTATUS gensec_krb5_session_info(struct gensec_security *gensec_security
/* NO pac */
DEBUG(5, ("krb5_ticket_get_authorization_data_type failed to find PAC: %s\n",
smb_get_krb5_error_message(context,
- ret, mem_ctx)));
+ ret, tmp_ctx)));
} else {
/* Found pac */
- pac_blob = data_blob_talloc(mem_ctx, pac_data.data, pac_data.length);
+ pac_blob = data_blob_talloc(tmp_ctx, pac_data.data, pac_data.length);
if (!pac_blob.data) {
free(principal_string);
krb5_free_principal(context, client_principal);
- talloc_free(mem_ctx);
+ talloc_free(tmp_ctx);
return NT_STATUS_NO_MEMORY;
}
@@ -683,14 +683,14 @@ static NTSTATUS gensec_krb5_session_info(struct gensec_security *gensec_security
if (!NT_STATUS_IS_OK(nt_status)) {
free(principal_string);
krb5_free_principal(context, client_principal);
- talloc_free(mem_ctx);
+ talloc_free(tmp_ctx);
return nt_status;
}
pac_blob_ptr = &pac_blob;
}
- nt_status = gensec_generate_session_info_pac(mem_ctx,
+ nt_status = gensec_generate_session_info_pac(tmp_ctx,
gensec_security,
gensec_krb5_state->smb_krb5_context,
pac_blob_ptr, principal_string,
@@ -701,20 +701,20 @@ static NTSTATUS gensec_krb5_session_info(struct gensec_security *gensec_security
krb5_free_principal(context, client_principal);
if (!NT_STATUS_IS_OK(nt_status)) {
- talloc_free(mem_ctx);
+ talloc_free(tmp_ctx);
return nt_status;
}
nt_status = gensec_krb5_session_key(gensec_security, session_info, &session_info->session_key);
if (!NT_STATUS_IS_OK(nt_status)) {
- talloc_free(mem_ctx);
+ talloc_free(tmp_ctx);
return nt_status;
}
- *_session_info = talloc_steal(mem_ctx_out, session_info);
+ *_session_info = talloc_steal(mem_ctx, session_info);
- talloc_free(mem_ctx);
+ talloc_free(tmp_ctx);
return NT_STATUS_OK;
}
diff --git a/source4/auth/gensec/gensec_util.c b/source4/auth/gensec/gensec_util.c
index d767f90..9c5db48 100644
--- a/source4/auth/gensec/gensec_util.c
+++ b/source4/auth/gensec/gensec_util.c
@@ -56,7 +56,7 @@ NTSTATUS gensec_generate_session_info(TALLOC_CTX *mem_ctx,
return nt_status;
}
-NTSTATUS gensec_generate_session_info_pac(TALLOC_CTX *mem_ctx_out,
+NTSTATUS gensec_generate_session_info_pac(TALLOC_CTX *mem_ctx,
struct gensec_security *gensec_security,
struct smb_krb5_context *smb_krb5_context,
DATA_BLOB *pac_blob,
@@ -84,7 +84,7 @@ NTSTATUS gensec_generate_session_info_pac(TALLOC_CTX *mem_ctx_out,
if (gensec_security->auth_context && gensec_security->auth_context->generate_session_info_pac) {
return gensec_security->auth_context->generate_session_info_pac(gensec_security->auth_context,
- mem_ctx_out,
+ mem_ctx,
smb_krb5_context,
pac_blob,
principal_string,
diff --git a/source4/auth/ntlm/auth.c b/source4/auth/ntlm/auth.c
index d2f1d88..95bdd84 100644
--- a/source4/auth/ntlm/auth.c
+++ b/source4/auth/ntlm/auth.c
@@ -468,7 +468,7 @@ static NTSTATUS auth_generate_session_info_wrapper(TALLOC_CTX *mem_ctx,
--
Samba Shared Repository
More information about the samba-cvs
mailing list