diff options
author | Jeremy Allison <jra@samba.org> | 2004-05-13 00:20:50 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 10:51:33 -0500 |
commit | a03b6a05e02ec8415efc0e8ceade102e06f8fffe (patch) | |
tree | 591108c0fc4361821a3eec33bb3a8c21e70c18d0 /source/smbd/process.c | |
parent | cf7a64c05dbc281802a2dc97a182b530fb925db9 (diff) | |
download | samba-a03b6a05e02ec8415efc0e8ceade102e06f8fffe.tar.gz samba-a03b6a05e02ec8415efc0e8ceade102e06f8fffe.tar.xz samba-a03b6a05e02ec8415efc0e8ceade102e06f8fffe.zip |
r656: Make widelinks use realpath(). Tidy up cases where we need to become a service.
Jeremy.
Diffstat (limited to 'source/smbd/process.c')
-rw-r--r-- | source/smbd/process.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/source/smbd/process.c b/source/smbd/process.c index 966bb63c1ea..d0dfc6dd7db 100644 --- a/source/smbd/process.c +++ b/source/smbd/process.c @@ -344,6 +344,7 @@ force write permissions on print services. #define CAN_IPC (1<<3) #define AS_GUEST (1<<5) #define QUEUE_IN_OPLOCK (1<<6) +#define DO_CHDIR (1<<7) /* define a list of possible SMB messages and their corresponding @@ -373,7 +374,7 @@ static const struct smb_message_struct { /* 0x0e */ { "SMBctemp",reply_ctemp,AS_USER | QUEUE_IN_OPLOCK }, /* 0x0f */ { "SMBmknew",reply_mknew,AS_USER}, /* 0x10 */ { "SMBchkpth",reply_chkpth,AS_USER}, -/* 0x11 */ { "SMBexit",reply_exit,0}, +/* 0x11 */ { "SMBexit",reply_exit,DO_CHDIR}, /* 0x12 */ { "SMBlseek",reply_lseek,AS_USER}, /* 0x13 */ { "SMBlockread",reply_lockread,AS_USER}, /* 0x14 */ { "SMBwriteunlock",reply_writeunlock,AS_USER}, @@ -469,7 +470,7 @@ static const struct smb_message_struct { /* 0x6e */ { NULL, NULL, 0 }, /* 0x6f */ { NULL, NULL, 0 }, /* 0x70 */ { "SMBtcon",reply_tcon,0}, -/* 0x71 */ { "SMBtdis",reply_tdis,0}, +/* 0x71 */ { "SMBtdis",reply_tdis,DO_CHDIR}, /* 0x72 */ { "SMBnegprot",reply_negprot,0}, /* 0x73 */ { "SMBsesssetupX",reply_sesssetup_and_X,0}, /* 0x74 */ { "SMBulogoffX", reply_ulogoffX, 0}, /* ulogoff doesn't give a valid TID */ @@ -754,7 +755,7 @@ static int switch_message(int type,char *inbuf,char *outbuf,int size,int bufsize return(ERROR_DOS(ERRSRV,ERRaccess)); /* load service specific parameters */ - if (conn && !set_current_service(conn,(flags & AS_USER)?True:False)) + if (conn && !set_current_service(conn,(flags & (AS_USER|DO_CHDIR)?True:False))) return(ERROR_DOS(ERRSRV,ERRaccess)); /* does this protocol need to be run as guest? */ |