Database
Security
Oracle Label Security |
|
|
|
| ||||||||||||||||||||||||||||||||
| Create Label Security policy | Define label components | Authorize users | Create procedure to enable role |
Labels consists of three components: Required Levels, and optional Compartments and Groups. In this example, the levels will be 'Confidential' and 'Sensitive', and the compartment will be 'PII'; no groups are used:

The same could be achieved using the following scripts:
BEGIN SA_COMPONENTS.CREATE_LEVEL ( policy_name => 'PROTECT_PII', level_num => 1000, short_name => 'C', long_name => 'CONFIDENTIAL'); END; / | BEGIN SA_COMPONENTS.CREATE_LEVEL ( policy_name => 'PROTECT_PII', level_num => 2000, short_name => 'S', long_name => 'SENSITIVE'); END; / |
BEGIN SA_COMPONENTS.CREATE_COMPARTMENT ( policy_name => 'PROTECT_PII', comp_num => 100, short_name => 'PII', long_name => 'PERS_INFO'); END; / |