The Samba-Bugzilla – Attachment 8360 Details for
Bug 9513
SEGV when using vfs_full_audit and accessing msdfs link
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Different patch for 3.6.x.
look (text/plain), 2.09 KB, created by
Jeremy Allison
on 2012-12-20 01:07:50 UTC
(
hide
)
Description:
Different patch for 3.6.x.
Filename:
MIME Type:
Creator:
Jeremy Allison
Created:
2012-12-20 01:07:50 UTC
Size:
2.09 KB
patch
obsolete
>diff --git a/source3/smbd/msdfs.c b/source3/smbd/msdfs.c >index f0f5d06..88367fd 100644 >--- a/source3/smbd/msdfs.c >+++ b/source3/smbd/msdfs.c >@@ -265,16 +265,19 @@ NTSTATUS create_conn_struct(TALLOC_CTX *ctx, > conn->sconn->num_tcons_open++; > > if (session_info != NULL) { >- conn->session_info = copy_serverinfo(conn, session_info); >- if (conn->session_info == NULL) { >- DEBUG(0, ("copy_serverinfo failed\n")); >- TALLOC_FREE(conn); >- return NT_STATUS_NO_MEMORY; >- } > vfs_user = conn->session_info->unix_name; >+ conn->session_info = copy_serverinfo(conn, session_info); > } else { > /* use current authenticated user in absence of session_info */ > vfs_user = get_current_username(); >+ conn->session_info = copy_serverinfo(conn, >+ get_current_conn()->session_info); >+ } >+ >+ if (conn->session_info == NULL) { >+ DEBUG(0, ("copy_serverinfo failed\n")); >+ TALLOC_FREE(conn); >+ return NT_STATUS_NO_MEMORY; > } > > set_conn_connectpath(conn, connpath); >@@ -285,7 +288,7 @@ NTSTATUS create_conn_struct(TALLOC_CTX *ctx, > * smb.conf checks are done as we need a uid and token. JRA. > * > */ >- if (conn->session_info) { >+ if (session_info) { > share_access_check(conn->session_info->security_token, > lp_servicename(snum), MAXIMUM_ALLOWED_ACCESS, > &conn->share_access); >diff --git a/source3/smbd/proto.h b/source3/smbd/proto.h >index d6f7511..6148cdc 100644 >--- a/source3/smbd/proto.h >+++ b/source3/smbd/proto.h >@@ -1129,6 +1129,7 @@ gid_t get_current_gid(connection_struct *conn); > const struct security_unix_token *get_current_utok(connection_struct *conn); > const struct security_token *get_current_nttok(connection_struct *conn); > uint16_t get_current_vuid(connection_struct *conn); >+connection_struct *get_current_conn(void); > > /* The following definitions come from smbd/utmp.c */ > >diff --git a/source3/smbd/uid.c b/source3/smbd/uid.c >index 7a48cb2..78c74cca 100644 >--- a/source3/smbd/uid.c >+++ b/source3/smbd/uid.c >@@ -596,3 +596,8 @@ uint16_t get_current_vuid(connection_struct *conn) > { > return current_user.vuid; > } >+ >+connection_struct *get_current_conn(void) >+{ >+ return current_user.conn; >+}
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 9513
:
8359
| 8360