summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2011-07-19 16:05:32 +1000
committerAndrew Bartlett <abartlet@samba.org>2011-07-20 09:17:15 +1000
commitd2a661a531da3d6b9bad6890a2cec46ec96e8521 (patch)
tree05f2efb5f7cc6b6f3244ab75753ac3a6c1381943
parent15123d96ffcac2243f69be41143bf78d92228d7f (diff)
downloadsamba-d2a661a531da3d6b9bad6890a2cec46ec96e8521.tar.gz
samba-d2a661a531da3d6b9bad6890a2cec46ec96e8521.tar.bz2
samba-d2a661a531da3d6b9bad6890a2cec46ec96e8521.zip
s3-auth Remove pointless destructor in make_server_info
All the callers allocate ->info3 as a talloc child already. As regardes the TALLOC_ZERO(), I added this originally out of parinoia many years ago. We do not consistantly zero session keys in memory, and for NTLMv2 and Kerberos they are random for each sesssion, so breaking into smbd far enough to read an old session key isn't a particularly interesting attack, compared with (say) reading the keytab or the password database. (NTLM and LM session keys are fixed derivitives of the passwords however). Andrew Bartlett
-rw-r--r--source3/auth/server_info.c10
1 files changed, 0 insertions, 10 deletions
diff --git a/source3/auth/server_info.c b/source3/auth/server_info.c
index a53e556d28..dec99b669e 100644
--- a/source3/auth/server_info.c
+++ b/source3/auth/server_info.c
@@ -29,14 +29,6 @@
#undef DBGC_CLASS
#define DBGC_CLASS DBGC_AUTH
-/* FIXME: do we really still need this ? */
-static int server_info_dtor(struct auth_serversupplied_info *server_info)
-{
- TALLOC_FREE(server_info->info3);
- ZERO_STRUCTP(server_info);
- return 0;
-}
-
/***************************************************************************
Make a server_info struct. Free with TALLOC_FREE().
***************************************************************************/
@@ -51,8 +43,6 @@ struct auth_serversupplied_info *make_server_info(TALLOC_CTX *mem_ctx)
return NULL;
}
- talloc_set_destructor(result, server_info_dtor);
-
/* Initialise the uid and gid values to something non-zero
which may save us from giving away root access if there
is a bug in allocating these fields. */