Full Disclosure mailing list archives

Re: Re: hard links on Linux create local DoS vulnerability and security problems


From: "Kurt Seifried" <listuser () seifried org>
Date: Wed, 26 Nov 2003 16:47:02 -0700

There is a simpler solution. Place user files on a separate filesystem
from system files. This includes putting all temporary files on separate
filesystems of their own. (Both /tmp and /var/tmp.) Since hard links
cannot cross filesystems the problem disappears. Mounting user
filesystems
nosuid and nodev will prevent security problems should a setuid binary
appear in that filesystem.

See, this is semi intelligent. any user writeable filesystem, typically
/tmp, /var/tmp, /home and sem-writeable fs's like /var/spool/mail (everyone
forgets the mail spool), mail queues, etc, etc will largely solve this
problem.

And a mandatory system profile in /etc , which aliases ln as 'ln -s' might
help.  One for each valid shell.

That is without a doubt one of the silliest things I have heard.

1) hard links are legitimate, very useful (think chroot)
2) alias'ing a commands... *snicker*. So I copy the ln binary to another
name and execute it (which causes you to make /home, /tmp, etc noexec, to
which the attacker replies with "/lib/ld-linux.so.2 /tmp/my-ln", a losing
battle ultimately.
3) change my shell, unalias the command, etc.

My advice: learn to use the "find" command to look for files and directories
that are writeable by users (either world writeable, writeable by groups the
users belong to, or owned by the user themself) and move those directories
onto seperate partitions. Forgot the silliness of playing with "alias" and
whatnot.

Kurt Seifried, kurt () seifried org
A15B BEE5 B391 B9AD B0EF
AEB0 AD63 0B4E AD56 E574
http://seifried.org/security/


----- Original Message ----- 
From: "Jeremiah Cornelius" <jeremiah () nur net>
To: "Jakob Lell" <jlell () JakobLell de>
Cc: "Steven Leikeim" <steven () enel ucalgary ca>;
<full-disclosure () lists netsys com>; <bugtraq () securityfocus com>
Sent: Wednesday, November 26, 2003 3:18 PM
Subject: Re: [Full-disclosure] Re: hard links on Linux create local DoS
vulnerability and security problems


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

On Monday 24 November 2003 10:17, Steven Leikeim wrote:
<SNIP>

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.3 (GNU/Linux)

iD8DBQE/xSbQJi2cv3XsiSARAm5CAJwPkETRJxLWAXw3M+B8jjfUwr38aQCeNzU/
4AjEdIIdmXmIHA6pYWjb1ao=
=FIsi
-----END PGP SIGNATURE-----

_______________________________________________
Full-Disclosure - We believe in it.
Charter: http://lists.netsys.com/full-disclosure-charter.html


_______________________________________________
Full-Disclosure - We believe in it.
Charter: http://lists.netsys.com/full-disclosure-charter.html


Current thread: