~ubuntu-branches/ubuntu/lucid/samba/lucid-security

« back to all changes in this revision

Viewing changes to .pc/CVE-2011-1678.patch/source3/client/mount.h

  • Committer: Package Import Robot
  • Author(s): Marc Deslauriers
  • Date: 2011-09-30 11:51:06 UTC
  • Revision ID: package-import@ubuntu.com-20110930115106-i2gtgkiwu0p1p3yu
Tags: 2:3.4.7~dfsg-1ubuntu3.8
* SECURITY UPDATE: denial of service via stale mtab lockfile
  - debian/patches/security-mask-signals.patch: mask signals while
    updating the mtab file in source3/client/mount.cifs.c.
  - CVE-2011-3585
* SECURITY UPDATE: mtab corruption via resource limits
  - debian/patches/CVE-2011-1678.patch: truncate mtab file if updating it
    failed in source3/client/{mount.cifs.c,mount.h,mtab.c}.
  - CVE-2011-1678
* SECURITY UPDATE: mtab corruption via incorrect new line check
  - debian/patches/CVE-2011-2724.patch: check proper return codes in
    source3/client/mount.cifs.c.
  - CVE-2011-2724

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/* 
 
2
 * Copyright (C) 2008 Jeff Layton (jlayton@samba.org)
 
3
 *
 
4
 * This program is free software; you can redistribute it and/or modify
 
5
 * it under the terms of the GNU General Public License as published by
 
6
 * the Free Software Foundation; either version 3 of the License, or
 
7
 * (at your option) any later version.
 
8
 * * 
 
9
 * This program is distributed in the hope that it will be useful,
 
10
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 
11
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
12
 * GNU General Public License for more details.
 
13
 *
 
14
 * You should have received a copy of the GNU General Public License
 
15
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
16
 */
 
17
 
 
18
/* most of this info was taken from the util-linux-ng sources */
 
19
 
 
20
#ifndef _MOUNT_H_
 
21
#define _MOUNT_H_
 
22
 
 
23
/* exit status - bits below are ORed */
 
24
#define EX_USAGE        1       /* incorrect invocation or permission */
 
25
#define EX_SYSERR       2       /* out of memory, cannot fork, ... */
 
26
#define EX_SOFTWARE     4       /* internal mount bug or wrong version */
 
27
#define EX_USER         8       /* user interrupt */
 
28
#define EX_FILEIO      16       /* problems writing, locking, ... mtab/fstab */
 
29
#define EX_FAIL        32       /* mount failure */
 
30
#define EX_SOMEOK      64       /* some mount succeeded */
 
31
 
 
32
#define _PATH_MOUNTED_LOCK      _PATH_MOUNTED "~"
 
33
#define _PATH_MOUNTED_TMP       _PATH_MOUNTED ".tmp"
 
34
 
 
35
extern int lock_mtab(void);
 
36
extern void unlock_mtab(void);
 
37
 
 
38
#endif /* ! _MOUNT_H_ */