NetBSD-Announce archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Updated: NetBSD Security Advisory 2010-001: File system module autoloading Denial of Service attack



-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

                 NetBSD Security Advisory 2010-001
                 =================================

Topic:          File system module autoloading Denial of Service attack

Version:        NetBSD-current:         affected prior to 2009-12-19 20:28:27 
UTC
                NetBSD 5.0.1:           not affected
                NetBSD 5.0:             not affected
                NetBSD 4.0.*:           not affected
                NetBSD 4.0:             not affected

Severity:       Local Denial of Service

Fixed:          NetBSD-current:         Dec 19, 2009

Please note that NetBSD releases prior to 4.0 are no longer supported.
It is recommended that all users upgrade to a supported release.


Abstract
========

A coding error in the NetBSD VFS code allows a local attacker to
crash the local system by passing a soon-to-be-unmapped pointer
as a file system name to the mount system call.


Technical Details
=================

When entering the mount_get_vfsops() function, the string "fstype",
containing the file system name, is first copied from userspace into the
kernel address space variable "fstypename". Upon invocation of the file
system kernel module autoloader, however, the module_autoload() function
was passed the "fstype" variable, which points to userspace memory.

If a pointer passed to the mount system call as the file system name is
unmapped before being used by the module autoloader, the module autoloader
will access unmapped memory, causing an unresolvable page fault in kernel
space and subsequently a kernel panic.

The same occurrs unconditionally on architectures with completely separate
kernel and user address spaces.

Please note that this vulnerability does not affect NetBSD 5.0 and 5.0.1,
as the file system module autoloading code is not enabled in these
versions.


Solutions and Workarounds
=========================

For all NetBSD versions, you need to obtain fixed kernel sources,
rebuild and install the new kernel, and reboot the system.
                                      
The fixed source may be obtained from the NetBSD CVS repository.
The following instructions briefly summarise how to upgrade your
kernel.  In these instructions, replace:

  ARCH     with your architecture (from uname -m), and                  
  KERNCONF with the name of your kernel configuration file.    

To update from CVS, re-build, and re-install the kernel:

        # cd src
        # cvs update -d -P sys/kern/vfs_syscalls.c
        # ./build.sh kernel=KERNCONF
        # mv /netbsd /netbsd.old
        # cp sys/arch/ARCH/compile/obj/KERNCONF/netbsd /netbsd 
        # shutdown -r now

For more information on how to do this, see:

   http://www.NetBSD.org/guide/en/chap-kernel.html


Thanks To
=========

Martin Husemann for finding and reporting the vulnerability, and for
developing a patch for it.


Revision History
================

        2010-01-12      Initial release
        2010-02-02      Removed NetBSD-5 from the list of vulnerable versions


More Information
================

Advisories may be updated as new information becomes available.
The most recent version of this advisory (PGP signed) can be found at 
  http://ftp.NetBSD.org/pub/NetBSD/security/advisories/NetBSD-SA2010-001.txt.asc

Information about NetBSD and NetBSD security can be found at
http://www.NetBSD.org/ and http://www.NetBSD.org/Security/.

Copyright 2010, The NetBSD Foundation, Inc.  All Rights Reserved.
Redistribution permitted only in full, unmodified form.

$NetBSD: NetBSD-SA2010-001.txt,v 1.2 2010/02/02 18:21:54 tonnerre Exp $
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (NetBSD)

iQIcBAEBAgAGBQJLaHD8AAoJEAZJc6xMSnBu3RIQAK4oAmeypKbsvxYLPyjPE7FO
zFrVjwvw8gNufv/7VmFhyY7qoUjKPCGg+07RagxMDwbm5uArMLGwgA9p+w0biKB4
Kj8bdFWCsQDauMCNlFD0BiXjT9P1Jj6g2JVlWrA1X+8m+341LIfM77H1s5c+XFLa
MXV6j0KYjZM5nbBACjwSp0LhO91N2WI3iFNxIfqFBMg0eqrpLbWE2DGcC/BD3mjn
2FB5jS7xCEDFhWCH/KgtNDRISrYNwv5C8yjMz6IIEPr5V1q3M+lQDKMVFWGYq33X
7D8XmOs/hFwWtVyJvJPPUdh0g6YmLapUnCJQsWuV+Le/s4IKr7id5CCMULlVYC+4
bTGtuR76S3qdz1jnbfZGNmx2cKYH1PcgaTTiJMP0g0Wx5+NupLJQJljURj+chk7N
py7d64sx1N0JzdSNRF1mGu0O6pJjZ+g3b7Z3Wy1zkZz6oB9z4QViPL0LdxONqkF9
iUDBaqf/E0pwEv71C4Krto1Mt+AuY6SjKIffrGkdvfgzucjyR0XoVpVaeuH1VIJB
58uYw5mLwIPdKA6qQkQWGCpn1YsLzuOJnOxWBS+l4bQICf1xF9/pdxiyHD+5Z4yy
1tpuW2qoG1eKO0Lezk9hda/vpIowKTGsJmwb9v6o0ByCsLVVJPJC0/Eq/HuBjlIn
KWp7ZziPdspLJwPoEjbh
=cPW2
-----END PGP SIGNATURE-----


Home | Main Index | Thread Index | Old Index