1ead1f93eSLiane Praza# 2ead1f93eSLiane Praza# CDDL HEADER START 3ead1f93eSLiane Praza# 4ead1f93eSLiane Praza# The contents of this file are subject to the terms of the 5ead1f93eSLiane Praza# Common Development and Distribution License (the "License"). 6ead1f93eSLiane Praza# You may not use this file except in compliance with the License. 7ead1f93eSLiane Praza# 8ead1f93eSLiane Praza# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE 9ead1f93eSLiane Praza# or http://www.opensolaris.org/os/licensing. 10ead1f93eSLiane Praza# See the License for the specific language governing permissions 11ead1f93eSLiane Praza# and limitations under the License. 12ead1f93eSLiane Praza# 13ead1f93eSLiane Praza# When distributing Covered Code, include this CDDL HEADER in each 14ead1f93eSLiane Praza# file and include the License file at usr/src/OPENSOLARIS.LICENSE. 15ead1f93eSLiane Praza# If applicable, add the following below this CDDL HEADER, with the 16ead1f93eSLiane Praza# fields enclosed by brackets "[]" replaced with your own identifying 17ead1f93eSLiane Praza# information: Portions Copyright [yyyy] [name of copyright owner] 18ead1f93eSLiane Praza# 19ead1f93eSLiane Praza# CDDL HEADER END 20ead1f93eSLiane Praza# 21ead1f93eSLiane Praza 22ead1f93eSLiane Praza# 23*ebbab6bbSDan Price# Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved. 24ead1f93eSLiane Praza# 25ead1f93eSLiane Praza 26ead1f93eSLiane Praza# 27ead1f93eSLiane Praza# For kernel/drv, set .conf files to mode 0644. Assume all other 28ead1f93eSLiane Praza# files there are drivers, and give them mode 0755 and reboot-needed. 29ead1f93eSLiane Praza# 30ead1f93eSLiane Praza# The (?<!r) construct in the reboot-needed transform is a negative 31ead1f93eSLiane Praza# lookbehind assertion: it says "only match this regex if the 32ead1f93eSLiane Praza# previously matched text does NOT match regex r." So it will match 33ead1f93eSLiane Praza# all files in the various kernel trees, except for .conf files. 34ead1f93eSLiane Praza# 35ead1f93eSLiane Praza<transform file path=.*kernel/drv/.+\.conf -> default mode 0644> 36ead1f93eSLiane Praza<transform file path=.*kernel/drv/.+ -> default mode 0755> 37ead1f93eSLiane Praza<transform file path=.*kernel/.+(?<!\.conf)$ -> default reboot-needed true> 38ead1f93eSLiane Praza 39*ebbab6bbSDan Price 40*ebbab6bbSDan Price# 41*ebbab6bbSDan Price# Non-global zones should not have content in kernel, usr/kernel (and 42*ebbab6bbSDan Price# other kernel dirs) or in boot/. 43*ebbab6bbSDan Price# 44*ebbab6bbSDan Price<transform file dir link hardlink path=.*kernel/.* -> set variant.opensolaris.zone global> 45*ebbab6bbSDan Price<transform dir path=kernel$ -> set variant.opensolaris.zone global> 46*ebbab6bbSDan Price<transform dir path=.*/kernel$ -> set variant.opensolaris.zone global> 47*ebbab6bbSDan Price 48*ebbab6bbSDan Price<transform file dir link hardlink path=boot/.* -> set variant.opensolaris.zone global> 49*ebbab6bbSDan Price<transform dir path=boot$ -> set variant.opensolaris.zone global> 50*ebbab6bbSDan Price 51ead1f93eSLiane Praza# 52ead1f93eSLiane Praza# shared objects should generally have mode 0755 53ead1f93eSLiane Praza# 54ead1f93eSLiane Praza<transform file path=.*lib/.*\.so.* -> default mode 0755> 55ead1f93eSLiane Praza 56ead1f93eSLiane Praza# 57ead1f93eSLiane Praza# Catch some of the collections of largely read-only files 58ead1f93eSLiane Praza# 59ead1f93eSLiane Praza<transform file path=usr/lib/help/.+ -> default mode 0444> 60ead1f93eSLiane Praza<transform file path=usr/share/doc/ksh/.+ -> default mode 0644> 61ead1f93eSLiane Praza<transform file path=usr/share/ipfilter/.+ -> default mode 0644> 62ead1f93eSLiane Praza<transform file path=usr/share/lib/ccs/.+ -> default mode 0644> 63ead1f93eSLiane Praza<transform file path=usr/share/lib/java/.+ -> default mode 0644> 64ead1f93eSLiane Praza<transform file path=usr/share/lib/locale/com/sun/dhcpmgr/.+\.properties -> default mode 0644> 65ead1f93eSLiane Praza<transform file path=usr/share/lib/locale/com/sun/dhcpmgr/.+ -> default mode 0444> 66ead1f93eSLiane Praza<transform file path=usr/share/lib/locale/com/sun/.+ -> default mode 0644> 67ead1f93eSLiane Praza<transform file path=usr/share/lib/mailx/.+ -> default mode 0644> 68ead1f93eSLiane Praza<transform file path=usr/share/lib/nterm/.+ -> default mode 0644> 69ead1f93eSLiane Praza<transform file path=usr/share/lib/pub/.+ -> default mode 0644> 70ead1f93eSLiane Praza<transform file path=usr/share/lib/sgml/.+ -> default mode 0644> 71ead1f93eSLiane Praza<transform file path=usr/share/lib/slp/.+ -> default mode 0644> 72ead1f93eSLiane Praza<transform file path=usr/share/lib/tabset/.+ -> default mode 0644> 73ead1f93eSLiane Praza<transform file path=usr/share/lib/t.+ -> default mode 0644> 74ead1f93eSLiane Praza<transform file path=usr/share/lib/unittab/.+ -> default mode 0644> 75ead1f93eSLiane Praza<transform file path=usr/share/lib/zoneinfo/.+ -> default mode 0644> 76ead1f93eSLiane Praza<transform file path=usr/share/src/grub/.+ -> default mode 0644> 77ead1f93eSLiane Praza<transform file path=usr/share/.+ -> default mode 0444> 78ead1f93eSLiane Praza 79ead1f93eSLiane Praza 80ead1f93eSLiane Praza# 81ead1f93eSLiane Praza# For what's left, go with root:bin 0644, +x for directories 82ead1f93eSLiane Praza# 83ead1f93eSLiane Praza# 84ead1f93eSLiane Praza<transform file dir -> default owner root> 85ead1f93eSLiane Praza<transform file dir -> default group bin> 86ead1f93eSLiane Praza<transform file -> default mode 0644> 87ead1f93eSLiane Praza<transform dir -> default mode 0755> 88