summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2003-08-14 23:40:45 +0000
committerJeremy Allison <jra@samba.org>2003-08-14 23:40:45 +0000
commit6a0c1d0baf2f185e0a8bf739af20c54472626678 (patch)
tree1217994a013a72aa88aaba1831b90b1c349656a7
parent1699fadcdb86462c0b36f0479317dc52ae8a263a (diff)
downloadsamba-6a0c1d0baf2f185e0a8bf739af20c54472626678.tar.gz
samba-6a0c1d0baf2f185e0a8bf739af20c54472626678.tar.bz2
samba-6a0c1d0baf2f185e0a8bf739af20c54472626678.zip
Fix setfileinfo level 1 - it only takes 12 bytes. Found by Samba4
torture tester. Jeremy. (This used to be commit 273ebfceb3142f485c2874f84114600d4a58c523)
-rw-r--r--source3/smbd/trans2.c7
1 files changed, 1 insertions, 6 deletions
diff --git a/source3/smbd/trans2.c b/source3/smbd/trans2.c
index efce768177..feb78e512f 100644
--- a/source3/smbd/trans2.c
+++ b/source3/smbd/trans2.c
@@ -2508,18 +2508,13 @@ static int call_trans2setfilepathinfo(connection_struct *conn,
switch (info_level) {
case SMB_INFO_STANDARD:
{
- if (total_data < l1_cbFile+4)
+ if (total_data < 12)
return(ERROR_DOS(ERRDOS,ERRinvalidparam));
/* access time */
tvs.actime = make_unix_date2(pdata+l1_fdateLastAccess);
-
/* write time */
tvs.modtime = make_unix_date2(pdata+l1_fdateLastWrite);
-
- dosmode = SVAL(pdata,l1_attrFile);
- size = IVAL(pdata,l1_cbFile);
-
break;
}