source: BOOK/chroot/common/changingowner.xml@ 6748458

sysvinit
Last change on this file since 6748458 was da7d5fc, checked in by Chris Staub <chris@…>, 11 years ago

Updates to changin ownership page

  • Property mode set to 100644
File size: 2.2 KB
RevLine 
[3f8be484]1<?xml version="1.0" encoding="ISO-8859-1"?>
[aa18ac0]2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
[3f8be484]4 <!ENTITY % general-entities SYSTEM "../../general.ent">
5 %general-entities;
6]>
7
8<sect1 id="ch-chroot-changingowner">
9 <?dbhtml filename="changingowner.html"?>
10
11 <title>Changing Ownership</title>
12
[6bfe833]13 <para os="a">Currently, the <filename class="directory">/tools</filename>
[fa6e750]14 and <filename class="directory">/cross-tools</filename> directories
[ca77da8]15 are owned by the user <emphasis>clfs</emphasis>, a user that
[da7d5fc]16 exists only on the host system. Although <filename
[fa6e750]17 class="directory">/tools</filename> and <filename
[da7d5fc]18 class="directory">/cross-tools</filename> can be deleted once the CLFS
19 system has been finished, they can be retained to build
[fb40919]20 additional CLFS systems. If the <filename class="directory">/tools</filename>
[fa6e750]21 and <filename class="directory">/cross-tools</filename> directories are
22 kept as is, the files are owned by a user ID without a corresponding
23 account. This is dangerous because a user account created later could
[da7d5fc]24 get this same user ID and would own these directories and all the files
25 therein, thus exposing those files to possible malicious manipulation.</para>
[3f8be484]26
[da7d5fc]27 <para os="b">One possible fix for this issue might be to add the
28 <systemitem class="username">clfs</systemitem> user to the new CLFS system
29 later when creating the <filename>/etc/passwd</filename> file, taking care
30 to assign it the same user and group IDs as on the host system. Alternatively,
[6bfe833]31 assign the contents of the <filename class="directory">/tools</filename>
32 and <filename class="directory">/cross-tools</filename> directories to
33 user <systemitem class="username">root</systemitem> by running the
34 following commands:</para>
[3f8be484]35
[6bfe833]36<screen os="c"><userinput>chown -Rv 0:0 /tools
[94e6142]37chown -Rv 0:0 /cross-tools</userinput></screen>
[3f8be484]38
[6bfe833]39 <para os="d">The commands use <parameter>0:0</parameter> instead of
[fa6e750]40 <parameter>root:root</parameter>, because <command>chown</command>
[9b65b70]41 is unable to resolve the name <quote>root</quote> until the
42 <filename>passwd</filename> file has been created.</para>
[3f8be484]43
44</sect1>
Note: See TracBrowser for help on using the repository browser.