summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2009-06-05 10:46:30 +0200
committerStefan Metzmacher <metze@samba.org>2009-06-05 17:53:23 +0200
commitf6cc5db0f201029789c0deac13d3f5e1f7c6efac (patch)
tree185299317b81ca457fcbc70eabf1cb268afbd259
parentfabdebdcf4479fe85db41577c7acfa08378bd425 (diff)
downloadsamba-f6cc5db0f201029789c0deac13d3f5e1f7c6efac.tar.gz
samba-f6cc5db0f201029789c0deac13d3f5e1f7c6efac.tar.bz2
samba-f6cc5db0f201029789c0deac13d3f5e1f7c6efac.zip
s3:smbd: add support for SMB2 Create on IPC$
metze
-rw-r--r--source3/smbd/smb2_create.c18
1 files changed, 17 insertions, 1 deletions
diff --git a/source3/smbd/smb2_create.c b/source3/smbd/smb2_create.c
index 8979073045..5d379ec3a5 100644
--- a/source3/smbd/smb2_create.c
+++ b/source3/smbd/smb2_create.c
@@ -214,7 +214,23 @@ static NTSTATUS smbd_smb2_create(struct smbd_smb2_request *req,
}
if (IS_IPC(smbreq->conn)) {
- return NT_STATUS_NOT_IMPLEMENTED;
+ const char *pipe_name = in_name;
+
+ if (!lp_nt_pipe_support()) {
+ return NT_STATUS_ACCESS_DENIED;
+ }
+
+ /* Strip \\ off the name. */
+ if (pipe_name[0] == '\\') {
+ pipe_name++;
+ }
+
+ status = open_np_file(smbreq, pipe_name, &result);
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
+ info = 0;
+ ZERO_STRUCT(sbuf);
} else if (CAN_PRINT(smbreq->conn)) {
status = file_new(smbreq, smbreq->conn, &result);
if(!NT_STATUS_IS_OK(status)) {