3. 構築
3.3. カーネルパラメータ
Ⅰ‑32 Copyright © 2003 IPA, All Rights Reserved.
Ⅰ‑33 Copyright © 2003 IPA, All Rights Reserved.
(3) tsol̲flush̲buffers
ブロックが i ノードにリンクされてからディスクに書き込まれるまでの間に障害が 発生したと想定する。その際、次のブートでは、起動の際に fsck が行なわれるが、こ の fsck 後でもディスクブロックがファイルシステムにリンクされている可能性があ る。そこで、データブロックが i ノードが更新される前にフラッシュするように設定 を行なうものである。デフォルトでは 1 になっている。
(4) tsol̲hide̲upgraded̲names
通常、ディレクトリやファイルを優位な機密ラベルに変更するにはプロセスに file̲mac̲write または file̲upgrade̲sl 特権が必要である。これらによって優位に なった機密ラベルのファイルおよびディレクトリは、デフォルトでは、アクセスする ことはできないが ls コマンド等でファイルを確認することができる。このパラメータ を設定するとプロセスよりも優位な機密ラベルのファイルおよびディレクトリは表示 されなくなる18。デフォルトでは 0 に設定されている。
(5) tsol̲privs̲debug
プロセスがどの特権を使っているか調べるコマンドとして runpd がある。このコマ ンドを実行するためには、このパラメータを 1 にする必要がある。デフォルトでは 0 にされている。
Note:
runpd の実行を有効にすると、プロセスの特権情報が取得されるだけではなく、特権がなくて もプロセスが起動できるようになるため、必要時のみに設定することを推奨する。
18 file̲mac̲read 等の特権をもっているプロセスの場合はこの限りではない。
Ⅰ‑34 Copyright © 2003 IPA, All Rights Reserved.
3.3.1.2. system ファイルのサンプル
リスト 3‑16 system
*ident "@(#)system 1.24 00/02/08 SMI; TSOL 2.x"
*
* SYSTEM SPECIFICATION FILE
*
* moddir:
*
* Set the search path for modules. This has a format similar to the
* csh path variable. If the module isn't found in the first directory
* it tries the second and so on. The default is /kernel /usr/kernel
*
* Example:
* moddir: /kernel /usr/kernel /other/modules
* root device and root filesystem configuration:
*
* The following may be used to override the defaults provided by
* the boot program:
*
* rootfs: Set the filesystem type of the root.
*
* rootdev: Set the root device. This should be a fully
* expanded physical pathname. The default is the
* physical pathname of the device where the boot
* program resides. The physical pathname is
* highly platform and configuration dependent.
*
* Example:
* rootfs:ufs
* rootdev:/sbus@1,f8000000/esp@0,800000/sd@3,0:a
*
* (Swap device configuration should be specified in /etc/vfstab.)
* exclude:
*
* Modules appearing in the moddir path which are NOT to be loaded,
* even if referenced. Note that ̀exclude' accepts either a module name,
* or a filename which includes the directory.
*
* Examples:
* exclude: win
* exclude: sys/shmsys
Ⅰ‑35 Copyright © 2003 IPA, All Rights Reserved.
* forceload:
*
* Cause these modules to be loaded at boot time, (just before mounting
* the root filesystem) rather than at first reference. Note that
* forceload expects a filename which includes the directory. Also
* note that loading a module does not necessarily imply that it will
* be installed.
*
* Example:
* forceload: drv/foo
* set:
*
* Set an integer variable in the kernel or a module to a new value.
* This facility should be used with caution. See system(4).
*
* Examples:
*
* To set variables in 'unix':
*
* set nautopush=32
* set maxusers=40
*
* To set a variable named 'debug' in the module named 'test̲module'
*
* set test̲module:debug = 0x13
* =======================================
* Trusted Solaris Configuration Variables
*
* tsol̲hide̲upgraded̲names
*
* When operating at a specific SL, there are occasions in which a
* directory will contain upgraded files and/or subdirectories.
* In some environments, it is required that a process not be able
* to learn about upgraded entries. Setting this flag controls
* whether upgraded filenames are returned with getdents(2).
* There is a performance penalty in that all directory entries must
* be examined before returning the results to the calling process.
*
* Value:
* 0 Do not hide upgraded names
* 1 Hide upgraded names
set tsol̲hide̲upgraded̲names=0
* tsol̲privs̲debug
*
* There is a three‑step process to assist in debugging privilege
Ⅰ‑36 Copyright © 2003 IPA, All Rights Reserved.
* problems with applications.
*
* The first step is to enable the debugging functionality. Set
* the kernel variable tsol̲privs̲debug via this file, uncomment
* the /var/log/privdebug.log line in the /etc/syslog.conf file,
* and reboot the machine.
*
* The second step is to start the program (that you want to
* debug the required privileges of) through the Trusted Path mechanism
* and runpd(1M). When started in this fashion, the process
* simply logs the failed operation/privilege combination, then
* proceeds as though the privilege were actually in the effective
* set. This allows integrators to determine what privileges are
* required, and why they are required, to get applications to work.
*
* The final step, after the application(s) have been privileged
* debugged, is to reset this variable and reboot the machine.
*
* Value:
* 0 Disable debugging mechanism
* 1 Enable debugging mechanism
set tsol̲privs̲debug=0
* tsol̲clean̲windows
*
* Clean register windows before returning from system call.
* This is for object reuse. It is possible for a system call
* to return kernel information is an inactive register window.
* A value of 1 will prevent this at a cost of clearing
* inactive register windows on return from each system call.
*
* Value:
* 0 Disable cleaning of inactive windows after system call
* 1 Enable cleaning of inactive windows after system call
set tsol̲clean̲windows=1
* tsol̲flush̲buffers
*
* Controls the order of disk buffer flushing with respect to
* inode updates. There is a timing window where blocks could be
* linked on to an inode and not yet written to disk and a machine
* crash in this state would leave old disk blocks (possibly of
* higher label, or another users) linked to a file after fsck
* recovers the file system. Setting this switch ensures that
* data blocks are flushed before inodes are updated on disk.
* There is a small performance penalty.
*
* Value:
* 0 Disable forced data flushing before inode updates
* 1 Enable forced data flushing before inode updates
set tsol̲flush̲buffers=1
Ⅰ‑37 Copyright © 2003 IPA, All Rights Reserved.
3.3.2. /etc/security/tsol/label̲encodings
label̲encodings ファイルは、MLS を構成する、機密ラベルの名称と値、また、それらの 相互運用ポリシーを定義するファイルはである。
Trusted Solaris では次の二つのタイプから構成される機密ラベルを実装している。
格付け(Classification)
階層的機密分類に用いられるラベル
(例)REGISTERD > NEED̲TO̲KNOW > INTERNAL̲USE̲ONLY > PUBLIC コンパートメント(Compartment)
非階層的な組織的分類に用いられるラベル
(例)SYSTEM̲ADMINISTRATION, MANUFACTURING, ENGINEERING, HUMAN̲RESOURCES これらは label̲encodings ファイルにより、システム上では、人に読める文字列として 表されるが、システム内部では、格付けは 2bytes の数値、コンパートメントの 256bits の ビット列で表されている。
Ⅰ‑38 Copyright © 2003 IPA, All Rights Reserved.
図 3‑3 ラベル内部表現
3.3.2.1. label̲encodings ファイルの構成
label̲encodings ファイルは米国政府などの組織から支給される場合もある。このファイ ルはコンパートメントモードワークステーション(CMW)に必要なラベルとエンコードの定 義が含まれている。コンパートメントモードワークステーションでは次のラベルが定義さ れている。
認可上限(Clearance)
機密ラベル(Sensitivity Label)
情報ラベル(Information Label)
label̲encodings ファイルは次のセクションから構成されており、これらは必須のセク ションとなっている。
CLASSIFICATIONS(格付け)
INFORMATION LABELS(情報ラベル)
SENSITIVITI LABELS(機密ラベル)
Ⅰ‑39 Copyright © 2003 IPA, All Rights Reserved.
CLEALANCES(許可上限)
CHANNEL
PRINTER BANNERS
ACCREDITATION RANGES(認可範囲)
LOCAL DEFINITION
label̲encodings ファイルに関する詳細の説明とリファレンスについては、Trusted Solarsi 8 4/01 AnswerBook “Compartmented Mode Workstation Labeling : Encodings Format”
(http://docs.sun.com/db/doc/816‑1051)に記載されている。
Note:
情報ラベルについては、Trusted Solaris 7 以降ではサポートしていない。label̲encodings ファイル中の INFORMATION LABEL セクションは SENSITIVITY LABELS セクションで指定するコ ンパートメントの定義と同様の定義がされている必要がある。
(1) CLASSIFICATIONS セクション
格付けは、機密ラベルまたは認可上限の階層的な部分である。各ラベルには一つの み格付けがある。ラベル変換ソフトウェア19では、格付け値を 256 個に制限している。
Trusted Solaris では 1〜255 の数値(整数)が、label̲encodings ファイル中の各格 付けに割り当てられる。値 0 は ADMIN̲LOW 管理ラベルに予約されている。
機密ラベルのうち格付け部分は、ファイルやディレクトリに含まれる情報の機密度 に基づいた機密保護の相対的なレベルを示す。ユーザやアプリケーションを実行する プロセス、ユーザのコマンドなどに割り当てられた認可上限において、格付けは信頼 度のレベルを示す。高い値を持つ格付けは、低い値の格付けよりも優位となる。
表 3‑7 格付けのタグ
# タグ 有効な値
1 name= 格付け名称 2 sname= 省略名称 3 aname= 代替名称
4 value= 格付けの値(1〜255 の整数)
5 initial compartments= 初期値として定義するコンパートメント
19 米国防情報局(Defense Intelligence Agency)の標準的なラベル作成のためのラベル作成ソフト
Ⅰ‑40 Copyright © 2003 IPA, All Rights Reserved.
(2) INFORMATION LABELS/SENSITIVITI LABELS/CLEALANCES セクション
情報ラベル、機密ラベル、許可上限では、機密ラベルの格付け以外の部分を形成す るコンパートメントを定義する。(情報ラベルは現在使われていない。)
コンパートメントは、機密ラベルまたは認可上限で使用するオプションの一つであ る。他のトラステッドシステムでは、コンパートメントをカテゴリと呼ぶことがあり、
また、政府機関ではチャネルと呼ぶこともある。
コンパートメントは、割り当てられたビットで構成され、それらは階層的なもので はない。しかし、コンパートメント間に階層関係を確立することもできる。一つコン パートメントのビットが、もう一つのコンパートメントのビットをすべて含む場合、
前者は優位となる。
INFORMATION LABELS、SENSITIVITI LABELS、CLEALANCE セクションは次のサブセク ションから構成されている。
WORDS
REQUIRED CONBINATIONS CONBINATION CONSTRAINTS
WORDS サブセクションは、label̲encodings ファイルの中ではコンパートメントを定 義する部分である。
REQUIRED CONBINATIONS サブセクションと CONBINATION CONSTRAINTS サブセクショ ンではコンパートメントの組み合わせの制限を定義する部分である。
表 3‑8 コンパートメントのタグ(WORD サブセクション)
# タグ 有効な値
1 name= コンパートメント名称 2 sname= 省略名称
3 prefix= 接頭文字 4 suffix= 接尾文字
5 compartments= コンパートメントのビット列
6 minclass= このコンパートメントが利用可能な下限の格付け 7 maxclass= このコンパートメントが利用可能な上限の格付け 8 omniclass= initial compartments から隠蔽する文字
(3) CHANNELS/PRINTER BANNERS セクション
CHANNELS、PRINTER BANNERS セクションについては、Trusted Solaris では使われて いない。リスト 3‑21 のとおりの定義がされている必要がある。
Ⅰ‑41 Copyright © 2003 IPA, All Rights Reserved.
(4) ACCREDITATION RANGES セクション
ACCREDITATION RANGES セクションは、格付けに対するコンパートメントの組み合わ せの制限を定義する。CLASSIFICATIONS セクションで定義された、格付けはすべて定 義する必要がある。
表 3‑9 認可範囲のタグ1
# タグ 有効な値
1 classification= CLASSIFICATION の格付け 2 only valid compartment combinations: 有効なコンパートメント 3 all compartment combinations valid except: 有効でないコンパートメント
4 all compartment combinations valid; すべてのコンパートメントが有効
表 3‑10 認可範囲のタグ2
# タグ 有効な値
1 minimum clearance= ユーザ許可上限の最低値 2 minimum sensitivity label= サブジェクトの機密ラベルの下限
3 minimum protect as cliassifications= プリンターバナーページ用
(5) LOCAL DEFINITIONS セクション
LOCAL DEFINITIONS セクションは、Trusted Solaris の拡張機能としての定義をする。
LOCAL DEFINITIONS セクションには、CDE のウインドウのタイトルバーに表示する色 を定義する COLOR NAMES サブセクションがある。
表 3‑11 拡張機能のタグ
# タグ 有効な値
1 Admin Low Name= 管理ラベル ADMIN̲LOW の変更名称 2 Admin High Name= 管理ラベル ADMIN̲HIGH の変更名称 3 Default Label View= 管理ラベルの表示・非表示の設定 4 Classification Name= 格付けのデフォルト名
5 Compartments Name= コンパートメントのデフォルト名
Note:
“default flags”および”forced flags”については、Trusted Solaris 7 以降ではサポートして いない。リスト 3‑21 のとおりの定義がされている必要がある。