Re: Login incorrect - 2. Anlauf
tschweikle@FIDUCIA.de wrote:
Natürlich geht das! Mit den File-Flags lassen sich auch für root Zugriffsrechte einräumen: wenn bei ls rauskommt
-r--r----- 1 root root 1079 Oct 14 11:58 tps.ldif dr-xr-xr-x 4 root root 1024 Sep 2 14:33 winxx ^
dann darf auch root in dem Verzeichnis nichts mehr ändern (keine neuen Files/Verzeichnisse mehr anlegen oder Rechte auf vorhandene Files/Verzeichnisse ändern). Wenn auch noch 'r' fehlt ist der Zugriff auf das File/Verzeichnis verboten fehlt auch noch 'x' bei einem Verzeichnis, darf nicht mehr ins Verzeichnis gewechselt werden.
Das trifft auf root nicht zu. 1. Fuer alle User gilt: Das Schreibrecht ist nur noetig, um Veraenderungen am *Inhalt* eines Verzeichnisses (= Anlegen, Loeschen oder Verschieben von Dateien darin) bzw. einer Datei zu machen. Fuer das Aendern von Rechten ist dagegen keinerlei Schreib- Lese- oder Ausfuehrungsrecht erforderlich, dazu genuegt es, an das jeweilige Objekt heranzukommen (d.h. mindestens 'x' bei Verzeichnis darueber vorhanden). 2. Es ist zwar moeglich, Rechte fuer root anzugeben (bzw. wegzunehmen), aber root kann unabhaengig von den gesetzten Rechten auf Dateien und Verzeichnisse zugreifen. Ausnahme: Eine Datei kann auch von root nur als Programm ausgefuehrt werden, wenn mindestens ein 'x' gesetzt ist, sonst wird sie nicht als ausfuehrbar erkannt. 3. Wenn selbst root etwas nicht darf, dann muss da schon ein grundlegendes Hindernis bestehen, dem sich mit einem einfachen chmod auch nicht beikommen laesst. Beispiele: - Loeschen eines nicht leeren Verzeichnisses (mit rmdir). Dazu muessen zunaechst alle Eintraege darin geloescht werden (z.B. mit rm -r). - Veraendern einer Programmdatei, waehrend sie noch von einem Prozess ausgefuehrt wird. (Aus Verzeichnis loeschen und durch neue Datei ersetzen geht aber.) - Schreiben (oder Rechte aendern etc.) in einem Dateisystem, das read-only gemounted ist. - Aendern von Rechten oder Eigentuemern in einem Dateisystem, das diese Eigenschaften nicht unterstuetzt (z.B. VFAT). - Direktes Uebergehen von Datei-Attributen, die mit chattr gesetzt wurden. Diese muessen zuvor explizit mit chattr entfernt werden. Eilert -- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Eilert Brinkmann -- Universitaet Bremen -- FB 3, Informatik eilert@informatik.uni-bremen.de - eilert@tzi.org - eilert@linuxfreak.com http://www.informatik.uni-bremen.de/~eilert/ --------------------------------------------------------------------- To unsubscribe, e-mail: suse-linux-unsubscribe@suse.com For additional commands, e-mail: suse-linux-help@suse.com
participants (1)
-
eilert@informatik.uni-bremen.de