A cross-platform system security login authentication system
By designing a cross-platform system security login authentication system, using Qt development and TCP communication, the problem of low security and difficulty in development and maintenance of the operating system's own login module is solved, a unified login interface and authentication process are realized, and security is improved. performance and development convenience.
Patent Information
- Application Number
- CN202211175173.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-09-26
- Publication Date
- 2024-09-20
- Estimated Expiration
- 2042-09-26
AI Technical Summary
The login module that comes with existing operating systems has low security and is difficult to develop and maintain across platforms, resulting in inconsistent interface styles, cumbersome development processes and error-prone.
A cross-platform system security login authentication system is designed, including a platform adaptation module, a cross-platform security authentication module and an authentication server. Qt is used to develop a cross-platform interface library and TCP communication to uniformly handle the login interface and authentication process, adapting to different Operating system interfaces and technologies.
It achieves a cross-platform unified login interface and authentication process, reduces the difficulty of development and maintenance, improves security, and avoids interface style differences and security issues between different platforms.
Smart Images

Figure CN115529177B
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of identity authentication security, and in particular relates to a cross-platform system security login authentication system. Background Art
[0002] With the development of computer security, the system login modules that come with each platform can no longer meet the requirements, and people have begun to use self-developed system login modules to replace the system's own login modules.
[0003] System login involves the underlying principles of the operating system, and the interfaces and interfaces are provided by various system manufacturers: 1. The Windows XP system login module is implemented using GINA technology, and the interface is implemented using Windows API, such as MFC; 2. The Windows 7 and above system login modules are implemented using Credential Providers technology, and the interface is implemented using the template that comes with this module; 3. The Linux system login module is implemented using GNOME, LightDM and other technologies.
[0004] Regardless of the operating system, the built-in system login module only performs simple system username and password authentication, and uses different login technologies and different interface APIs. Not only is the security poor, but it is also difficult to maintain and develop. Developers need to use corresponding technologies according to different systems and versions to implement the corresponding version of the login module. The development process is cumbersome, especially when maintaining and upgrading, all platform codes need to be maintained. Because it involves the underlying operating system and cross-platform development, the slightest carelessness may cause inability to enter the operating system or security problems, resulting in immeasurable consequences. In addition, the interface styles on each platform will be inconsistent, increasing the learning cost and aesthetics. Summary of the invention
[0005] 1. Technical issues to be resolved
[0006] The technical problem to be solved by the present invention is: how to design a cross-platform system security login authentication system, which solves the problem that the login module provided by the operating system itself has low security and is difficult to develop and maintain across platforms.
[0007] (II) Technical solution
[0008] In order to solve the above technical problems, the present invention provides a cross-platform system security login authentication system, comprising:
[0009] Platform adaptation module, which is deployed according to different operating systems and only handles the interaction with the operating system;
[0010] Cross-platform security authentication module, developed using Qt, for login interface display and authentication process processing;
[0011] The authentication server is used to communicate with the cross-platform security authentication module to verify the legitimacy of the login.
[0012] Preferably, the operations related to the operating system are implemented in the platform adaptation module, which only calls the interface of the cross-platform security authentication module to obtain the authentication result. If successful, it logs into the system. If it fails, it will call the cross-platform security authentication module again.
[0013] Preferably, the cross-platform security authentication module is developed using the cross-platform interface library Qt and has cross-platform capabilities. Once this module is called, the event loop is started, the authentication logic is called synchronously, and it waits for the authentication to end and then returns. This module also has TCP communication capabilities, can connect to the authentication server, encrypt the user input information and send it to the server to assist in completing the authentication process.
[0014] Preferably, the authentication server is deployed remotely or locally, communicates with the cross-platform security authentication module through the TCP protocol, compares and verifies the information to be verified with the content in the database, and returns the result information to the cross-platform security authentication module to assist it in completing identity authentication.
[0015] Preferably, the system is installed and deployed on Windows XP / 7 / 10, Kylin, Kylin or Linux system;
[0016] In the Windwos XP system, the platform adaptation module uses GINA technology to rewrite the system login function, cyclically calls the cross-platform security authentication module, obtains the authentication result and attempts to log in to the system;
[0017] In the Windwos 7 / 10 system, the platform adaptation module uses the Credential Providers technology to cyclically call the cross-platform security authentication module in a sub-process manner, wait for the process to end, obtain the authentication result and try to log in to the system;
[0018] On the Kylin, Kylin or Linux system, the platform adaptation module uses LightDM technology, which can directly call the platform security authentication module in a loop, obtain the authentication results and try to log in to the system.
[0019] Preferably, the cross-platform security authentication module can format the content input by the user in the human-computer interaction interface and send it to the authentication server according to the TCP authentication protocol.
[0020] Preferably, under Windows XP system, the cross-platform security authentication module selects msvc compiler and Qt for joint compilation, and selects MSVC2013 version as the version of msvc compiler, and also adjusts the Qt default library loading path to solve the library shortage problem.
[0021] Preferably, in Windows 7 / 10 system, the authentication action is captured by modifying the system function entry, and then a subprocess is started, and the subprocess calls a cross-platform security authentication module to adapt the cross-platform authentication process. When the system authentication starts, a new subprocess is created to lock the current system authentication process, execute the authentication logic, and return the authentication result through the process return value, and then continue to execute the system authentication process;
[0022] In the Linux system, LightDM technology is used to complete the authentication process by calling the cross-platform security authentication module, and then interact with the operating system through the LightDM / Gretter class.
[0023] Preferably, the communication function in the cross-platform security authentication module uses a customized TCP module, which customizes the TCP protocol internally, inputs the message type and data body, and can communicate with the authentication server, and TCP packet sticking processing and MTU packet subpacketing design are designed in the customized TCP module; the cross-platform security authentication module is implemented using winsocket in Windows system and BSD socket in Linux system.
[0024] The invention also provides a design method for the system.
[0025] (III) Beneficial effects
[0026] The present invention designs and implements a cross-platform system security login authentication system, which can overcome the problems of difficult software development and maintenance, poor adaptability and low security caused by differences in system login module interface styles and authentication processes between different platforms and different system versions. BRIEF DESCRIPTION OF THE DRAWINGS
[0027] Figure 1 This is a schematic diagram of the module calling relationship of the system of the present invention. DETAILED DESCRIPTION
[0028] In order to make the purpose, content and advantages of the present invention more clear, the specific implementation methods of the present invention are further described in detail below in conjunction with the drawings and examples.
[0029] Aiming at the problem that the differences in system login module interface styles and authentication processes between different platforms and system versions lead to difficult software development and maintenance, poor adaptability and low security, the present invention designs a cross-platform system security login authentication system.
[0030] (I) System components
[0031] The system described in the present invention mainly includes the following components:
[0032] 1) Platform adaptation module: This module is deployed according to different operating systems and only handles the interaction with the operating system.
[0033] 2) Cross-platform security authentication module, which is developed using Qt and is used for login interface display and authentication process processing.
[0034] 3) Authentication server, used to communicate with the cross-platform security authentication module to verify the legitimacy of the login.
[0035] (II) Module Calling Relationship
[0036] The present invention covers up the differences between operating systems to the greatest extent, and puts the operations related to the operating system into the platform adaptation module. Figure 1 This module only calls the interface of the cross-platform security authentication module to obtain the authentication result. If successful, it will log in to the system. If it fails, it will call the cross-platform security authentication module again.
[0037] The cross-platform security authentication module is developed using the cross-platform interface library Qt. It has cross-platform capabilities and can achieve a unified interface style on multiple platforms. Once this module is called, it starts the event loop, synchronously calls the authentication logic, and waits for the authentication to end before returning. This module also has TCP communication capabilities, can connect to the authentication server, encrypt the user input information and send it to the server to assist in completing the authentication process.
[0038] The authentication server can be deployed remotely or locally, and communicate with the cross-platform security authentication module through the TCP protocol. It compares the information to be verified with the content in the database, and returns the result information to the cross-platform security authentication module to assist it in completing identity authentication.
[0039] (III) Adaptation and maintenance
[0040] This system can be installed and deployed on Windows XP / 7 / 10, Kylin, Kylin, or other Linux systems.
[0041] 1) In the Windwos XP system, the platform adaptation module uses GINA technology to rewrite the system login function, cyclically call the cross-platform security authentication module, obtain the authentication result and try to log in to the system.
[0042] 2) In Windwos 7 / 10 systems, the platform adaptation module uses Credential Providers technology. Because it already has an interface and event loop, it calls the cross-platform security authentication module in a subprocess loop, waits for the process to end, obtains the authentication result and tries to log in to the system.
[0043] 3) On Kylin, Kylin, or other Linux systems, the platform adaptation module uses LightDM technology. Since LightDM itself supports Qt, it can directly call the platform security authentication module in a loop, obtain the authentication results and try to log in to the system.
[0044] Because the platform adaptation module is only responsible for calling the cross-platform security authentication module and system operations, it does not need to be upgraded or maintained once it is installed and deployed. If there is a subsequent need, you only need to modify the cross-platform security authentication module to update all platforms.
[0045] The present invention adopts the idea of modular architecture design, independently assigns functions to each module, and decouples functions between modules. Programmers can select required modules according to requirements, and can also write and replace corresponding modules according to module specifications.
[0046] The cross-platform security authentication module will format the content entered by the user in the human-computer interaction interface and send it to the authentication server according to the TCP authentication protocol. Programmers can upgrade the authentication server according to project requirements, or implement a new authentication server based on the TCP authentication protocol.
[0047] In addition, a new authentication module can be implemented according to the cross-platform security authentication module interface. At this time, programmers will not need to understand the operating principles of the system login modules in each system. They only need to return the authentication results after their own authentication process is completed, and they can be easily integrated.
[0048] (IV) Functional Implementation
[0049] 1) Under Windows XP system, in official and existing implementations, Gina is used to call MFC to implement interface writing and authentication functions, which does not meet the cross-platform requirements of the system of the present invention, so the present invention focuses on solving the problem of Gina and Qt adaptation under Windows XP system. It has been verified that MinGW compiler and Gina cannot be adapted, so msvc compiler is selected to be jointly compiled with Qt, and because virtual studio 2015 and later versions have poor adaptability to Windows XP system, MSVC2013 version is selected as the version of msvc compiler. Qt default library loading path is also adjusted to solve the library shortage problem.
[0050] The present invention captures the authentication action by modifying the function entry in the system library, replaces the system default behavior, and calls the cross-platform security authentication module to implement the authentication process. After the authentication is completed, the authentication result is obtained and the operating system is logged in.
[0051] 2) In Windows 7 / 10 systems, the official Credential Providers provide interface templates that can only operate a few controls and background images, etc., and cannot complete a relatively responsible authentication process. It is also impossible to use MFC, Qt and other interface tools for joint development, which brings great cross-platform problems.
[0052] In the present invention, the authentication action is captured by modifying the system function entry, and then the subprocess is started, and the subprocess calls the cross-platform security authentication module to adapt the cross-platform authentication process. When the system authentication starts, a new subprocess is created, the current system authentication process is locked, the authentication logic is executed, and the authentication result is returned through the process return value, and then the system authentication process continues to be executed.
[0053] 3) In the Linux system, LightDM technology is used, which supports Qt development. The authentication process is completed by calling the cross-platform security authentication module, and then the LightDM / Gretter class is used to interact with the operating system.
[0054] 4) The communication function in the cross-platform security authentication module uses a customized TCP module and an internal customized TCP protocol. The caller does not need to understand the internal implementation principle of the socket. He only needs to enter the message type and data body to communicate with the authentication server, which greatly simplifies the development of the authentication process. TCP packet sticking processing and MTU packet subpacketing design are added to the customized TCP module to improve communication stability and efficiency. The cross-platform security authentication module is implemented using winsocket in Windows system and BSD socket in Linux system.
[0055] 5) The cross-platform security authentication module uses two login technologies. Through the interface parameters, you can selectively use the self-developed login process, the operating system's own login process, or both together to further improve system security. At the same time, the system administrator can change the configuration so that when the cross-platform security authentication module cannot connect to the fingerprint reader or authentication server, it automatically uses the operating system's own login process to ensure that users can log in to the operating system safely, solving the problem of similar systems being unable to enter the system due to equipment problems or server disconnection.
[0056] The above is only a preferred embodiment of the present invention. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the technical principles of the present invention. These improvements and modifications should also be regarded as the scope of protection of the present invention.
Claims
1. A cross-platform system security login authentication system, It is characterized in that include: Platform adaptation module, which is deployed according to different operating systems and only handles the interaction with the operating system; Cross-platform security authentication module, developed using the application development framework Qt, for login interface display and authentication process processing; The authentication server is used to communicate with the cross-platform security authentication module to verify the legitimacy of the login; The operations related to the operating system are implemented in the platform adaptation module. This module only calls the interface of the cross-platform security authentication module to obtain the authentication result. If successful, the user logs in to the system. If failed, the cross-platform security authentication module will be called again. The cross-platform security authentication module is developed using the cross-platform interface library Qt and has cross-platform capabilities. Once this module is called, an event loop is started, the authentication logic is called synchronously, and it waits for the authentication to end and return. This module also has TCP communication capabilities, can connect to the authentication server, encrypt the user input information and send it to the server to assist in completing the authentication process; The authentication server is deployed remotely or locally, communicates with the cross-platform security authentication module through the TCP protocol, compares and verifies the information to be verified with the content in the database, and returns the result information to the cross-platform security authentication module to assist it in completing identity authentication.
2. The system according to claim 1, It is characterized in that The system is installed and deployed on Windows XP / 7 / 10, Kylin, Kylin or Linux system; In the Windwos XP system, the platform adaptation module uses the graphic identification and authentication model GINA technology to rewrite the system login function, cyclically call the cross-platform security authentication module, obtain the authentication result and try to log in to the system; In the Windwos 7 / 10 system, the platform adaptation module uses the CredentialProviders plug-in technology provided by Microsoft to cyclically call the cross-platform security authentication module in a child process mode, wait for the process to end, obtain the authentication result and try to log in to the system; On the Kylin, Kylin or Linux system, the platform adaptation module uses the identity authentication model interface LightDM technology used by the Linux platform, and can directly call the platform security authentication module in a loop, obtain the authentication results and try to log in to the system.
3. The system according to claim 2, It is characterized in that The cross-platform security authentication module can format the content input by the user in the human-computer interaction interface according to the TCP authentication protocol and send it to the authentication server.
4. The system according to claim 3, It is characterized in that Under Windows XP system, the cross-platform security authentication module uses Microsoft Visual C++ msvc compiler and Qt for joint compilation, and uses MSVC2013 version as the version of msvc compiler. The Qt default library loading path is also adjusted to solve the library shortage problem.
5. The system according to claim 4, It is characterized in that In Windows 7 / 10 system, the authentication action is captured by modifying the system function entry, and then the child process is started. The child process calls the cross-platform security authentication module to adapt to the cross-platform authentication process. When the system authentication starts, a new child process is created to lock the current system authentication process, execute the authentication logic, and return the authentication result through the process return value, and then continue to execute the system authentication process; In the Linux system, LightDM technology is used to complete the authentication process by calling the cross-platform security authentication module, and then interact with the operating system through the LightDM / Gretter class.
Citation Information
Cited By
Unified identity authentication system and method for scientific research collaboration
CN121486100A
A unified identity authentication system and method for scientific research collaboration
CN121486100B
