Solaris System Files

This files_system_solaris_objects.cfg example specifies important Solaris system files, together with their desired ownerships and permissions.  This files_system_solaris_objects.cfg file is #include'd by the parent files_system_objects.cfg file.

///////////////////////////////////////////////////////////////////////////////
//
// files_system_solaris_objects.cfg
//
///////////////////////////////////////////////////////////////////////////////

#if solaris

        /kernel/genunix -rwxr-xr-x 755 0 3 root sys
        /etc/system -rw-r--r-- 644 0 3 root sys
        /etc/mail/aliases -rw-r--r-- 644 0 2 root bin

#  if ! ( cologne )
        /etc/auto_direct -rw-r--r-- 644 0 2 root bin
#  endif

        /etc/auto_home -rw-r--r-- 644 0 2 root bin
        /etc/auto_master -rw-r--r-- 644 0 2 root bin

#  if ! cologne
        /etc/defaultdomain -rw-r--r-- 644 0 0 root root
#  endif

        /etc/defaultrouter -rw-r--r-- 644 0 0 root root
        /etc/dfs/dfstab -rw-r--r-- 644 0 3 root sys
        /etc/group -rw-r--r-- 644 0 3 root sys
        /etc/hosts lrwxrwxrwx 777 0 0 root root

#  if mus | comp | perf
        /etc/hosts.equiv -rw-r--r-- 644 0 1 root other
#  endif

        /etc/inet/hosts -r--r--r-- 444 0 3 root sys
        /etc/inittab -rw-rw-r-- 644 0 3 root sys
        /etc/inetd.conf lrwxrwxrwx 777 0 0 root root
        /etc/inet/inetd.conf -r--r--r-- 444 0 3 root sys
        /etc/magic -r--r--r-- 444 0 2 root bin
#if solaris28
        /etc/mnttab -r--r--r-- 444 0 0 root root
#else
        /etc/mnttab -rw-r--r-- 644 0 0 root root
#endif
        /etc/netmasks lrwxrwxrwx 777 0 0 root root
        /etc/inet/netmasks -r--r--r-- 444 0 3 root sys
        /etc/networks lrwxrwxrwx 777 0 0 root root
        /etc/inet/networks -r--r--r-- 444 0 3 root sys
        /etc/nsswitch.conf -rw-r--r-- 644 0 3 root sys
#  if ntpd
        /etc/ntp.conf -rw-r--r-- 644 0 1 root other
#  endif
        /etc/passwd -rw-r--r-- 644 0 3 root sys
        /etc/protocols lrwxrwxrwx 777 0 0 root root
        /etc/inet/protocols -r--r--r-- 444 0 3 root sys
        /etc/resolv.conf -rw-r--r-- 644 0 1 root other
        /etc/rpc -rw-r--r-- 644 0 3 root sys
#  if ! nosendmail
        /etc/sendmail.cf lrwxrwxrwx 777 0 1 root other
#  endif
        /etc/mail/sendmail.cf -r--r--r-- 444 0 2 root bin
        /etc/services lrwxrwxrwx 777 0 0 root root
        /etc/inet/services -r--r--r-- 444 0 3 root sys
        /etc/shadow -r-------- 400 0 3 root sys
        /etc/shells -rw-r--r-- 644 0 1 root other
        /etc/syslog.conf -rw-r--r-- 644 0 3 root sys
        /etc/termcap lrwxrwxrwx 777 0 0 root root
        /usr/share/lib/termcap -rw-r--r-- 644 0 2 root bin
        /etc/ttydefs -rw-r--r-- 644 0 3 root sys
        /etc/vfstab -rw-r--r-- 644 0 3 root sys

        // to fix a buffer-overflow vulnerability:
        /usr/sbin/format -r-x------ 500 0 2 root bin

[...]

#endif  // solaris

///////////////////////////////////////////////////////////////////////////////

This example files_system_solaris_objects.cfg file incorporates elaborate per-machine customizations by way of PIKT '#if ... #endif' directives.  Contrast this hand-coded approach with the automated approach of using the mkdirlist.pl script to autogenerate system file lists, as in files_system_redhat_linux_objects.cfg and files_system_suse_linux_objects.cfg.

On the piktmaster system, we would install the FilesSystem.obj file to each PIKT Solaris system with the command:

# piktc -iv +O FilesSystem +H solaris        [or: ... -H down]

For more examples, see Samples.

 
Home | FAQ | News | Intro | Samples | Tutorial | Reference | Software
Developer's Notes | Licensing | Authors | Pikt-Users | Pikt-Workers | Related Projects | Site Index | Privacy Policy | Contact Us
Page best viewed at 1024x768 or greater.   Page last updated 2019-01-12.   This site is PIKT® powered.
Copyright © 1998-2019 Robert Osterlund. All rights reserved.
Home FAQ News Intro Samples Tutorial Reference Software
PIKT Logo
PIKT Page Title
View sample
non-search links
Pikt script