## 5 Case Study 1--ITMI: Non-IoT
### The Solution: HEAD Metamodel
#### 5.2.2 Phase 2: Generating Policies  
The meta-policy is expressed in terms of the meta-components \(E_{x}\), \(I_{m}\), and \(S_{t}\)[15; 20]:  
\[Metapolicy=\langle E_{x},AU,PU,S_{t}\rangle\]  
Before expressing the formal policy, we need to describe the policy elements:  
* Users: a set of entities who have accounts in the IS. Users = {[PERSON], [PERSON], [PERSON], [PERSON], [PERSON], [PERSON], [PERSON], [PERSON], [PERSON]}
* User Attributes: each user is associated with a set of attributes (e.g., Id, name...). * Roles: specifies user's role. Role = {director, manager, adviser, specialist, technician}. * Groups: specifies user's group. Group = {groupA, groupB, groupC}. * Objects: a set of logical/physical objects that need protection. For example, database entities (projects, tasks...), labs, machines, devices, etc. * Object attributes: object attributes include the project name, machine#, etc. * Actions: a set of actions on logical objects (e.g., read, write, update, delete, etc. ), and on physical objects (e.g., operate machines, test, troubleshoot, etc.). * Permissions: users' permissions to perform actions on objects based on their roles (or groups), and if constraints and contextual constraints are true. * Context: for a given context--for example, log in via private/public network, machine malfunction, system failure, etc.-- context attributes include datetime, login location, failed password attempts, etc., contextual constraint expressions include context attributes which are important for authorization decisions. * Constraints: expressions include the other various types of attributes, for example, subject attributes, object attributes, etc. Based on the meta-policy expression, we express the policy of this case study as follows:  
\[Policy=\langle subject(name,\ldots);object(title,\ldots);role( type,\ldots);group(number,\ldots);\] \[\qquad\qquad\qquad\qquad\qquad\qquad\qquad\qquad\qquad\qquad  
As mentioned earlier, to illustrate the NGAC policy graph, we need to generate the needed Cypher statements as Java output. To obtain the required Cypher statements, the system administrator (or the authorized user) must be aware of how to configure the NGAC policy by specifying the users, resources, relationships, conditions, etc., based on the computing environment of the case study. Figure 9 illustrates the schema of NGAC policy configuration of this case study. In Figure 9a, we show user containers that represent the assignment of U-UA. For example, [PERSON] (U) and [PERSON] (U) are assigned to Adviser (UA), and [PERSON] (U) is assigned to Director (UA), etc. In (b), we show object containers with the representation of relational database tables with some distinguished rows/columns where they are represented as containers of data objects corresponding to the row/column fields. For example, a container named ProjectDetails includes the fields prjName, startDate, endDate, and prjConfirmation. Furthermore, (c) Lists thirteen association relations in terms of the user and object attributes/containers expressed in (a,b). In (c), users' access rights to perform operations are formulated through associations. For example, in (1) and (2) the director is allowed to [r:read, w:write/ insert, u:update, d:delete] the data in FinancialDetails container. He is also allowed to [d: delete, c: confirm] data of ProjectDetails container; in (3) the manager is allowed to [r, w, u] data of ProjectDetails; etc. Note that the operations's' and 'o' in 6 and 9 mean select and operate. In (d), we have two prohibition relations which express user attribute-deny (ua_deny) to deny the technicians '[PERSON]' and '[PERSON]' from performing {w, u, d} on GrpATskRslt/GrpCTskRslt and GrpBTskRslt/GrpCTskRslt respectively. In (e), we represent six obligations defined as event-response relations to  
Figure 8: Case Study 1: A sample of (a) Xtend notation to express the assignment relationships between O-OA nodes; (b) The generate the Java code expressing the Cypher statements.