diff options
author | Andrew Bartlett <abartlet@samba.org> | 2002-05-25 07:37:44 +0000 |
---|---|---|
committer | Andrew Bartlett <abartlet@samba.org> | 2002-05-25 07:37:44 +0000 |
commit | 20efe2fe6cbc4b5cf861a3296e29f5495637f79c (patch) | |
tree | 320ae01d545132da8faeb265e7702254bb4bfb3d /source3/rpc_server | |
parent | 9921fd9d0ef9a8862b371eec17d47a9e78c5ad67 (diff) | |
download | samba-20efe2fe6cbc4b5cf861a3296e29f5495637f79c.tar.gz samba-20efe2fe6cbc4b5cf861a3296e29f5495637f79c.tar.bz2 samba-20efe2fe6cbc4b5cf861a3296e29f5495637f79c.zip |
Clean up a few unused functions, add a bit of static etc.
Importantly:
The removal of the silly 'delete user script' behaviour when secuity=domain.
I have left the name the same - as it still does the (previously documented,
but not in smb.conf(5)) sane behaviour of deleting users on request.
When we decide what to do with the 'add user' functionality, we might
rename it.
Andrew Bartlett
(This used to be commit cdcfe3671eb7570e15649b77f708e6579055e7bc)
Diffstat (limited to 'source3/rpc_server')
-rw-r--r-- | source3/rpc_server/srv_samr_nt.c | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/source3/rpc_server/srv_samr_nt.c b/source3/rpc_server/srv_samr_nt.c index 6a623bd2a0..c889581fae 100644 --- a/source3/rpc_server/srv_samr_nt.c +++ b/source3/rpc_server/srv_samr_nt.c @@ -3174,6 +3174,24 @@ NTSTATUS _samr_del_groupmem(pipes_struct *p, SAMR_Q_DEL_GROUPMEM *q_u, SAMR_R_DE } +/**************************************************************************** + Delete a UNIX user on demand. +****************************************************************************/ + +static int smb_delete_user(const char *unix_user) +{ + pstring del_script; + int ret; + + pstrcpy(del_script, lp_deluser_script()); + if (! *del_script) + return -1; + all_string_sub(del_script, "%u", unix_user, sizeof(pstring)); + ret = smbrun(del_script,NULL); + DEBUG(3,("smb_delete_user: Running the command `%s' gave %d\n",del_script,ret)); + return ret; +} + /********************************************************************* _samr_delete_dom_user *********************************************************************/ |