# Role-Based Access Control Model for Inter-System Cross-Domain in Multi-Domain Environment
## 3 Proposed Model
### Formal Definition of Model Functions  
\(\text{user\_authorization}(\text{user}\in\text{U}_{d})\to 2^{SR_{e}}\). denote all specific roles authorized to a user. Formally:  
\[\text{userauthorization}(\text{user}\in\text{U}_{d})=\{SR_{e_{i}}\,\mid SR_{e_{i }}\subseteq SR_{e_{i}},\,(\text{user},\,SR_{e_{i}})\in\,USR_{d}\}\,(e=1,\,2, \,\ldots,\,n) \tag{16}\]  
when \(e=d\), \(SR_{e_{i}}\) indicates the specific role set of local domain for the _user_; when \(SR_{e_{i}}=\emptyset\), it explains that the _user_ does not have any specific role of domain \(e\).  
\(\text{sr\_assignment}(\text{specific\_role}\in\text{SR}_{d})\to 2^{P}\). denote all the permissions assigned to a specific role. Formally:  
\[\text{sr\_assignment}(\text{specific\_role}\in\text{SR}_{d})=\{P_{i}\,\mid\,P_{i }\subseteq P,\,(\text{specific\_role},P_{i})\in SRP_{d}\} \tag{17}\]  
**Property 5**.: _If a specific role has a primary specific role, its permission set includes the directly assigned permissions and the permissions of all its primary roles. The formal expression is as follows: Suppose,_  
\[\forall\textit{specific\_role}^{\prime},\textit{specific\_role}\in SR_{1};\]  
\[\forall P_{a,b},\,P_{a},\,P_{b}\subseteq P;\]  
_If,_  
\[P_{a}\text{ denotes a permission set directly assigned to }\textit{specific\_role}^{\prime};\]  
\[P_{b}\text{ denote the permission set of all primary specific roles of }\textit{specific\_role}^{\prime},\]  
\[P_{b}=\bigcup\limits_{\textit{specific\_role}\in\textit{s}\textit{l}\textit{ inheritance(specific\_role})}\textit{sr\_assignment}(\textit{specific\_role})\]  
_So, all permissions assigned by specific_role\({}^{\prime}\) are,_  
\[P_{a,b}=\textit{sr\_assignment}(\textit{specific\_role}^{\prime})=P_{a}\cup P _{b}.\]  
\[\textit{user\_assignment}(\textit{user}\in\textbf{U}_{d})\rightarrow\textbf{2} ^{\textbf{P}}.\text{ denote all permissions a user has. Formally:}\]  
\[\textit{user\_assignment}(\textit{user}\in\textbf{U}_{d})=\bigcup\limits_{ \textit{specific\_role}\in\textit{user}\textit{authorization}(\textit{user})} \textit{sr\_assignment}(\textit{specific\_role}) \tag{18}\]  
\[\textit{user\_sessions}(\textit{user}\in\textbf{U}_{d})\rightarrow\textbf{2} ^{\textbf{S}_{e}}.\text{ denote all sessions activated by a user. Formally:}\]  
\[\textit{user\_sessions}(\textit{user}\in\textbf{U}_{d})=\big{\{}S_{d_{i}} \bigm{|}S_{d_{i}}\subseteq SR_{d},\,\big{(}\textit{user, }\,S_{d_{i}}\big{)}\in\textit{US}_{d}\big{\}} \tag{19}\]  
\[\textit{session\_user}(\textit{session}\in\textbf{S}_{d})\rightarrow\textit{ user}\in\textbf{U}_{d}.\text{ denote from a session to a user mapping. Formally:}\]  
\[\textit{session\_user}(\textit{session}\in S_{d})=\{\textit{user}\,\mid \textit{user}\in\textbf{U}_{d},\,(\textit{user},\textit{session})\in\textit{US}_{d}\} \tag{20}\]  
\[\textit{session\_sr}(\textit{session}\in\textbf{S}_{d})\rightarrow\textbf{2} ^{\textbf{SR}_{e}}.\text{ denote all specific roles activated by a session. Formally:}\]  
\[\textit{session\_sr}(\textit{session}\in\textbf{S}_{d})=\{SR_{e_{i}}\mid SR_{e_{ i}}\subseteq SR_{d},\,(\textit{session\_user}(\textit{session}),\,SR_{e_{i}})\in\textit{US}_{d}\}\,(\textit{e}=1,\,2,\,\ldots,\,n) \tag{21}\]  
_when_ \(e\) = \(d\), \(SR_{e_{i}}\) indicates the specific role set of the local domain activated for the session; when_\(SR_{e_{i}}\)=_O_, it explains that the session does not activate any specific role of domain e._  
\[\textit{session\_permission}(\textit{session}\in\textbf{S}_{d})\rightarrow\textbf{2} ^{\textbf{P}}.\text{ denote all permissions activated by a session. Formally:}\]  
\[\textit{session}(\textit{session}\in\textbf{S}_{d})=\bigcup\limits_{ \textit{specific\_role}\in\textit{session\_sr}(\textit{session})}\textit{sr\_ assignment}(\textit{specific\_role}) \tag{22}\]