From f6afda0bc867f1080c45e1f6f79d5032c41d2b1a Mon Sep 17 00:00:00 2001 From: Christian Ambach Date: Mon, 27 Feb 2012 17:51:40 -0800 Subject: s3:smb2_server verify creditcharge for all requests that have max_???? checks, also do a check of the creditcharge the client has sent (when using largemtu) Signed-off-by: Jeremy Allison --- source3/smbd/smb2_read.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'source3/smbd/smb2_read.c') diff --git a/source3/smbd/smb2_read.c b/source3/smbd/smb2_read.c index 13bcbdfd19..0b6e2ee461 100644 --- a/source3/smbd/smb2_read.c +++ b/source3/smbd/smb2_read.c @@ -80,6 +80,11 @@ NTSTATUS smbd_smb2_request_process_read(struct smbd_smb2_request *req) return smbd_smb2_request_error(req, NT_STATUS_INVALID_PARAMETER); } + status = smbd_smb2_request_verify_creditcharge(req, in_length); + if (!NT_STATUS_IS_OK(status)) { + return smbd_smb2_request_error(req, status); + } + if (req->compat_chain_fsp) { /* skip check */ } else if (in_file_id_persistent != in_file_id_volatile) { -- cgit