{"title":"微服务架构中的身份验证和基于角色的授权:通用的以性能为中心的设计","authors":"Randa Ahmad Al-Wadi, Adi Maaita","doi":"10.12720/jait.14.4.758-768","DOIUrl":null,"url":null,"abstract":"—In a microservice-based system, each microservice is a stand-alone application that may be targeted individually to obtain unauthorized access. Consequently, it is necessary to include authentication and authorization features. However, a set of related design decisions needs to be taken in a way that accommodates the scale of a developed system. To illustrate, a user may be authenticated depending on a password and authorized based on roles. In such a case, one integrated authentication and role-based authorization microservice can be added. Besides, the Application Programming Interfaces (APIs) that are associated with roles may be hard-coded as static API-level role authorization checks. Nevertheless, static relation between roles and APIs hinders the ease of modification of their associations when a massive number of APIs exist in a microservice system. To transform the relation into dynamic relation, this paper presents a generic microservice-based architectural design with a separate role-based authorization microservice that contains role/API database records. Moreover, it shows experimentation for performance optimization that was carried out on authentication and role-based authorization databases to utilize the suggested architectural design. The obtained results of password-based authentication encouraged employing not only Structured Query Language (NoSQL) databases with small microservice-based systems, which deal with 1500 users or less while employing Structured Query Language (SQL) databases with medium to large systems. Furthermore, the results indicated that there is no difference between the two database types in the role-based authorization process for all API-based system scale levels.","PeriodicalId":36452,"journal":{"name":"Journal of Advances in Information Technology","volume":"1 1","pages":""},"PeriodicalIF":0.9000,"publicationDate":"2023-01-01","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"0","resultStr":"{\"title\":\"Authentication and Role-Based Authorization in Microservice Architecture: A Generic Performance-Centric Design\",\"authors\":\"Randa Ahmad Al-Wadi, Adi Maaita\",\"doi\":\"10.12720/jait.14.4.758-768\",\"DOIUrl\":null,\"url\":null,\"abstract\":\"—In a microservice-based system, each microservice is a stand-alone application that may be targeted individually to obtain unauthorized access. Consequently, it is necessary to include authentication and authorization features. However, a set of related design decisions needs to be taken in a way that accommodates the scale of a developed system. To illustrate, a user may be authenticated depending on a password and authorized based on roles. In such a case, one integrated authentication and role-based authorization microservice can be added. Besides, the Application Programming Interfaces (APIs) that are associated with roles may be hard-coded as static API-level role authorization checks. Nevertheless, static relation between roles and APIs hinders the ease of modification of their associations when a massive number of APIs exist in a microservice system. To transform the relation into dynamic relation, this paper presents a generic microservice-based architectural design with a separate role-based authorization microservice that contains role/API database records. Moreover, it shows experimentation for performance optimization that was carried out on authentication and role-based authorization databases to utilize the suggested architectural design. The obtained results of password-based authentication encouraged employing not only Structured Query Language (NoSQL) databases with small microservice-based systems, which deal with 1500 users or less while employing Structured Query Language (SQL) databases with medium to large systems. Furthermore, the results indicated that there is no difference between the two database types in the role-based authorization process for all API-based system scale levels.\",\"PeriodicalId\":36452,\"journal\":{\"name\":\"Journal of Advances in Information Technology\",\"volume\":\"1 1\",\"pages\":\"\"},\"PeriodicalIF\":0.9000,\"publicationDate\":\"2023-01-01\",\"publicationTypes\":\"Journal Article\",\"fieldsOfStudy\":null,\"isOpenAccess\":false,\"openAccessPdf\":\"\",\"citationCount\":\"0\",\"resultStr\":null,\"platform\":\"Semanticscholar\",\"paperid\":null,\"PeriodicalName\":\"Journal of Advances in Information Technology\",\"FirstCategoryId\":\"1085\",\"ListUrlMain\":\"https://doi.org/10.12720/jait.14.4.758-768\",\"RegionNum\":0,\"RegionCategory\":null,\"ArticlePicture\":[],\"TitleCN\":null,\"AbstractTextCN\":null,\"PMCID\":null,\"EPubDate\":\"\",\"PubModel\":\"\",\"JCR\":\"Q4\",\"JCRName\":\"COMPUTER SCIENCE, INFORMATION SYSTEMS\",\"Score\":null,\"Total\":0}","platform":"Semanticscholar","paperid":null,"PeriodicalName":"Journal of Advances in Information Technology","FirstCategoryId":"1085","ListUrlMain":"https://doi.org/10.12720/jait.14.4.758-768","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"Q4","JCRName":"COMPUTER SCIENCE, INFORMATION SYSTEMS","Score":null,"Total":0}
Authentication and Role-Based Authorization in Microservice Architecture: A Generic Performance-Centric Design
—In a microservice-based system, each microservice is a stand-alone application that may be targeted individually to obtain unauthorized access. Consequently, it is necessary to include authentication and authorization features. However, a set of related design decisions needs to be taken in a way that accommodates the scale of a developed system. To illustrate, a user may be authenticated depending on a password and authorized based on roles. In such a case, one integrated authentication and role-based authorization microservice can be added. Besides, the Application Programming Interfaces (APIs) that are associated with roles may be hard-coded as static API-level role authorization checks. Nevertheless, static relation between roles and APIs hinders the ease of modification of their associations when a massive number of APIs exist in a microservice system. To transform the relation into dynamic relation, this paper presents a generic microservice-based architectural design with a separate role-based authorization microservice that contains role/API database records. Moreover, it shows experimentation for performance optimization that was carried out on authentication and role-based authorization databases to utilize the suggested architectural design. The obtained results of password-based authentication encouraged employing not only Structured Query Language (NoSQL) databases with small microservice-based systems, which deal with 1500 users or less while employing Structured Query Language (SQL) databases with medium to large systems. Furthermore, the results indicated that there is no difference between the two database types in the role-based authorization process for all API-based system scale levels.