• Skip to main content
  • Skip to primary sidebar

BSDFreaks.nl

For starters and advanced *BSD users

Tags

brand dmi enschede FreeBSD harddisk Hardware Howto's Howto's move new ports server serverruimte universiteit utwente

FreeBSD 5.2-RELEASE-p1

January 30, 2004 by Rob

[b]I. Background[/b]

Mounted filesystems can have a variety of flags set on them. Some
flags affect performance and reliability‚ while others enable or
disable particular security-related features such as the ability to
execute a binary stored on the filesystem or the use of access control
lists to complement normal Unix file permissions.

The mksnap_ffs(8) command creates a `snapshot’ of a filesystem. A
`snapshot’ is a static representation of the state of the filesystem
at a particular point in time. Snapshots have a variety of uses‚
but their primary purpose is to make it possible to run fsck(8) and
dump(8) on live filesystems.

[b]II. Problem Description[/b]

The kernel interface for creating a snapshot of a filesystem is the
same as that for changing the flags on that filesystem. Due to an
oversight‚ the mksnap_ffs(8) command called that interface with only
the snapshot flag set‚ causing all other flags to be reset to the
default value.

[b]III. Impact[/b]

A regularly scheduled backup of a live filesystem‚ or any other
process that uses the mksnap_ffs(8) command (for instance‚ to provide
a rough undelete functionality on a file server)‚ will clear any flags
in effect on the filesystem being snapshot. Possible consequences
depend on local usage‚ but can include disabling extended access
control lists or enabling the use of setuid executables stored on an
untrusted filesystem.

The mksnap_ffs(8) command is normally only available to the superuser
and members of the `operator’ group. There is therefore no risk
of a user gaining elevated privileges directly through use of the
mksnap_ffs(8) command unless it has been intentionally made available
to unprivileged users.

[b]IV. Workaround[/b]

Do not use the mksnap_ffs(8) command‚ nor the -L option of the dump(8)
command.

It is recommended that you delete the mksnap_ffs(8) command from your
system to prevent accidental use:

# rm /sbin/mksnap_ffs

[b]V. Solution[/b]

Do one of the following:

1) Upgrade your vulnerable system to the RELENG_5_1 or RELENG_5_2
security branch dated after the correction date.

2) To patch your present system:

a) Download the relevant patch from the location below‚ and verify the
detached PGP signature using your PGP utility.

[FreeBSD 5.1 systems]
# fetch ftp://ftp.FreeBSD.org/pub/FreeBSD/CERT/patches/SA-04:01/mksnap_ffs_5_1.patch
# fetch ftp://ftp.FreeBSD.org/pub/FreeBSD/CERT/patches/SA-04:01/mksnap_ffs_5_1.patch.asc

[FreeBSD 5.2 systems]
# fetch ftp://ftp.FreeBSD.org/pub/FreeBSD/CERT/patches/SA-04:01/mksnap_ffs_5_2.patch
# fetch ftp://ftp.FreeBSD.org/pub/FreeBSD/CERT/patches/SA-04:01/mksnap_ffs_5_2.patch.asc

b) Execute the following commands as root:

# cd /usr/src
# patch < /path/to/patch # cd /usr/src/sbin/mksnap_ffs # make obj && make depend && make && make install You are strongly encouraged to verify that all your filesystems have the correct flags set. The mount(8) command can list currently mounted filesystems and flags. Run the following command as root: # mount [b]VI. Correction details[/b] The following list contains the revision numbers of each file that was corrected in FreeBSD. Branch Revision Path - ------------------------------------------------------------------------- RELENG_5_1 src/sbin/mksnap_ffs/mksnap_ffs.c 1.2.2.1 src/sys/conf/newvers.sh 1.50.2.14 RELENG_5_2 src/sbin/mksnap_ffs/mksnap_ffs.c 1.5.2.1 src/sys/conf/newvers.sh 1.56.2.3 - ------------------------------------------------------------------------- -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.4 (FreeBSD) iD8DBQFAGZGaFdaIBMps37IRAllWAJ9oKoQlBCzfriylX+N8GFp543TZKgCfRvqq FWOjW+047DNINuG/6CTN0/8= =sRcT -----END PGP SIGNATURE-----

Filed Under: *BSD news from the past

Reader Interactions

Comments

  1. Anonymous says

    January 31, 2004 at 1:34 pm

    Ah, dit is die advisory.

    Updaten maar weer :P…

Primary Sidebar

Pages

  • Howto overview
  • iPhone mail setup
  • Links

Categories

  • *BSD news from the past
  • Console
  • Firewall
  • FreeBSD
  • FTP server
  • Hardware
  • Howto's
  • Installation
  • Kernel
  • Mail server
  • Miscellaneous
  • Networking
  • News
  • News imported
  • OpenBSD
  • Operating System
  • Programming
  • Security
  • Site news
  • Software
  • Sysutils
  • Web server

Recent Comments

  • admin on Qmail FreeBSD Mail Toaster Spam en virus control addon
  • admin on [FreeBSD] Het opzetten van een Vlan
  • Jap on [FreeBSD] Installing GlFtpd
  • Jap on [FreeBSD] Installing GlFtpd
  • Crashjuh on Wireless access point met OpenBSD + VPN

Copyright © 2025 · Genesis Sample Theme on Genesis Framework · WordPress · Log in