Multi-user login method and device
By automatically obtaining and logging in other users' usernames and passwords after the MacOS system is turned on, and using the VNC program to achieve multi-user login, the problem that the MacOS system only supports single user login is solved, the operation process is simplified and efficiency is improved.
Patent Information
- Application Number
- CN202111263833.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-10-27
- Publication Date
- 2025-09-19
- Estimated Expiration
- 2041-10-27
AI Technical Summary
The MacOS system only supports starting a single user at startup. Other users must open the user interface and switch accounts before logging in. The operation is complicated and inflexible.
A multi-user login method is provided. After a single user completes login on the MacOS system, the user name and password of other users are automatically obtained, the VNC program is started and connected, and the VNC program is exited after a successful login, thereby achieving simultaneous login of multiple users.
It enables simultaneous login of multiple users after the MacOS system is started, simplifies the operation steps, and improves the efficiency and reliability of login.
Smart Images

Figure CN113971277B_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the field of computer technology, specifically to the field of cloud computing technology, and more particularly to a multi-user login method and device. Background Art
[0002] A multi-user system is a computer system consisting of a host computer connected to several terminals via multi-user cards. The basic concept of a multi-user system is that multiple users "time-share" a single host computer, sharing its resources, including hardware and software, to save investment. The host computer handles information processing tasks for all users and implements centralized management. Time-sharing includes two key features: first, only one terminal can be connected to the host computer at any given time; second, all terminals take turns communicating with the host computer.
[0003] MacOS only supports multi-user systems. You only need to add multiple users in the preferences and use any user system by switching users in the user interface. Summary of the Invention
[0004] Embodiments of the present disclosure provide a multi-user login method, apparatus, device, and storage medium.
[0005] In a first aspect, an embodiment of the present disclosure provides a multi-user login method, the method comprising: in response to determining that a single user login is completed when the MacOS system is started, performing an automatic login operation, wherein the automatic login operation comprises: obtaining the user name and password of other users that need to be started; performing a connection operation, the connection operation comprises: starting a VNC program and setting the IP to be connected, and logging in based on the user name and password of other users that need to be started; in response to determining that the login is successful, exiting the VNC program.
[0006] In a second aspect, an embodiment of the present disclosure provides a multi-user login device, which includes: a login module, configured to perform an automatic login operation in response to determining that a single user login is completed when the MacOS system is started, wherein the automatic login operation includes: obtaining the user name and password of other users who need to be started; performing a connection operation, the connection operation includes: starting a VNC program and setting the IP to be connected, and logging in based on the user name and password of other users who need to be started; an exit module, configured to exit the VNC program in response to determining that the login is successful.
[0007] In a third aspect, an embodiment of the present disclosure provides an electronic device comprising one or more processors; a storage device on which one or more programs are stored, and when the one or more programs are executed by the one or more processors, the one or more processors implement a multi-user login method as in any embodiment of the first aspect.
[0008] In a fourth aspect, an embodiment of the present disclosure provides a computer-readable medium having a computer program stored thereon, which, when executed by a processor, implements the multi-user login method of any embodiment of the first aspect.
[0009] In a fifth aspect, an embodiment of the present disclosure provides a computer program product, including a computer program, which, when executed by a processor, implements the multi-user login method of any embodiment of the first aspect.
[0010] The present disclosure implements simultaneous multi-user login after the MacOS system is turned on, simplifying subsequent operation steps.
[0011] It should be understood that the content described in this section is not intended to identify the key or important features of the embodiments of the present disclosure, nor is it intended to limit the scope of the present disclosure. Other features of the present disclosure will become easily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS
[0012] Figure 1 is an exemplary system architecture diagram in which the present disclosure may be applied;
[0013] Figure 2 is a flow chart of an embodiment of a multi-user login method according to the present disclosure;
[0014] Figure 3 is a flow chart of another embodiment of the multi-user login method according to the present disclosure;
[0015] Figure 4 is a schematic diagram of an application scenario of the multi-user login method according to the present disclosure;
[0016] Figure 5 is a flow chart of another embodiment of the multi-user login method according to the present disclosure;
[0017] Figure 6 is a schematic diagram of an embodiment of a multi-user login device according to the present disclosure;
[0018] Figure 7 It is a structural diagram of a computer system suitable for implementing the electronic device of the embodiment of the present disclosure. DETAILED DESCRIPTION
[0019] The following description of exemplary embodiments of the present disclosure is made in conjunction with the accompanying drawings, including various details of the embodiments of the present disclosure to facilitate understanding. These details should be considered as merely exemplary. Therefore, those skilled in the art will recognize that various changes and modifications may be made to the embodiments described herein without departing from the scope and spirit of the present disclosure. Similarly, for the sake of clarity and conciseness, descriptions of well-known functions and structures are omitted in the following description.
[0020] It should be noted that, in the absence of conflict, the embodiments and features of the embodiments in the present disclosure may be combined with each other. The present disclosure will be described in detail below with reference to the accompanying drawings and in combination with the embodiments.
[0021] Figure 1 An exemplary system architecture 100 is shown to which an embodiment of the multi-user login method of the present disclosure can be applied.
[0022] like Figure 1 As shown, system architecture 100 may include terminal devices 101, 102, 103, a network 104, and a server 105. Network 104 is a medium for providing communication links between terminal devices 101, 102, 103 and server 105. Network 104 may include various connection types, such as wired or wireless communication links or fiber optic cables.
[0023] The user can use the terminal devices 101, 102, 103 to interact with the server 105 via the network 104 to receive or send messages, etc. The terminal devices 101, 102, 103 can be installed with a MacOS system.
[0024] Terminal devices 101, 102, and 103 can be hardware or software. When terminal devices 101, 102, and 103 are hardware, they can be various electronic devices with display screens, including but not limited to mobile phones and laptops. When terminal devices 101, 102, and 103 are software, they can be installed in the electronic devices listed above. They can be implemented as multiple software or software modules (for example, to provide multi-user login services), or as a single software or software module. No specific limitations are given here.
[0025] Server 105 can be a server that provides various services. For example, in response to determining that a single user has completed login when the MacOS system is turned on, an automatic login operation is performed, wherein the automatic login operation includes: obtaining the user name and password of other users that need to be started; performing a connection operation, wherein the connection operation includes: starting a VNC program and setting the IP to be connected, and entering the user name and password of other users that need to be started to log in; in response to determining that the login is successful, exiting the VNC program.
[0026] It should be noted that the server 105 can be hardware or software. When the server 105 is hardware, it can be implemented as a distributed server cluster consisting of multiple servers, or it can be implemented as a single server. When the server is software, it can be implemented as multiple software or software modules (for example, to provide multi-user login services), or it can be implemented as a single software or software module. No specific limitations are made here.
[0027] It should be noted that the multi-user login method provided in the embodiments of the present disclosure can be executed by the server 105, or by the terminal devices 101, 102, 103, or by the server 105 and the terminal devices 101, 102, 103 in cooperation with each other. Accordingly, the various parts (e.g., various units, sub-units, modules, sub-modules) included in the multi-user login apparatus can be all provided in the server 105, or all provided in the terminal devices 101, 102, 103, or provided separately in the server 105 and the terminal devices 101, 102, 103.
[0028] It should be understood that Figure 1 The number of terminal devices, networks and servers in the embodiment is merely illustrative. Any number of terminal devices, networks and servers may be provided as required.
[0029] Figure 2 A flowchart 200 of an embodiment of a multi-user login method is shown. The multi-user login method comprises the following steps:
[0030] Step 201 , in response to determining that a single user login is completed when the MacOS system is turned on, an automatic login operation is performed.
[0031] In this embodiment, the execution subject (e.g., Figure 1 The server 105 or terminal devices 101, 102, 103) can monitor in real time or regularly whether a single user has completed login after the MacOS system is started. If it is detected that a single user has completed login, an automatic login operation is performed.
[0032] Among them, the MacOS system is a graphical user interface operating system developed by Apple that runs on the Macintosh series of computers.
[0033] Here, the single user is usually a single user that is pre-set in the MacOS system preferences for automatic startup, for example, admin. Admin can be set in advance and the permissions are administrator permissions.
[0034] Among them, the automatic login operation can include obtaining the user name and password of other users to be started; performing a connection operation, which includes: starting a VNC (Virtual Network Console) program and setting the IP to be connected; and logging in based on the user name and password of other users to be started.
[0035] Here, VNC is a remote control tool software with powerful remote control capabilities, efficient and practical.
[0036] Among them, the other users that need to be started can be one user or multiple users, and this application does not limit this.
[0037] Specifically, the execution entity can obtain the username and password of other users that need to be started from the preset configuration file, for example, username A and password A of user loginer1, username B and password B of user loginer2, and perform the connection operation, that is, start the VNC program and set the IP to be connected, for example, 127.0.0.1, and enter the username and password of other users that need to be started to log in.
[0038] Step 202: In response to determining that the login is successful, exit the VNC program.
[0039] In this embodiment, the execution subject may detect in real time or periodically whether other users to be started have successfully logged in. If it is determined that other users to be started have successfully logged in, the VNC program is exited.
[0040] In some optional embodiments, the connection operation further includes: in response to determining that the login fails, continuing to perform the automatic login operation.
[0041] In this implementation, the execution subject can detect in real time or periodically whether other users who need to be started have successfully logged in. If the login fails, the automatic login operation will continue to be executed.
[0042] This implementation helps to improve the effectiveness and reliability of automatic login for multiple users at startup by continuing to perform the automatic login operation in response to determining that the login has failed.
[0043] In some optional manners, in response to determining that the login is successful, exiting the VNC program includes: in response to determining that the login is successful, exiting the VNC program after waiting for a preset time interval.
[0044] In this implementation, the execution subject may detect in real time or periodically whether other users to be started have successfully logged in. If it is determined that other users to be started have successfully logged in, the execution subject exits the VNC program after waiting for a preset time interval.
[0045] Among them, the preset time interval can be set according to experience and actual needs, for example, 5s, 7s, etc., and this application does not limit this.
[0046] This implementation method exits the VNC program after waiting for a preset time interval in response to determining that the login is successful. This helps to ensure that other users who need to log in successfully log in, that is, exit the VNC program after the corresponding graphical interface of each user is displayed, which helps to improve the effectiveness and reliability of the login.
[0047] In some optional embodiments, the method further includes: in response to determining that the login is successful, detecting whether a login process corresponding to the user identifier of the successful login exists, and in response to determining that it does not exist, continuing to execute the connection operation.
[0048] In this implementation, after determining that other users to be started have successfully logged in and exited the VNC program, the execution entity can also detect in real time or at preset intervals whether the user identifier of the successfully logged-in user, such as a uuid (Universally Unique Identifier), and the corresponding login process, i.e., loginwindows, exist. If not, the execution entity continues to execute the connection operation, i.e., restart the VNC program to log in.
[0049] This implementation method detects whether a login process corresponding to the user identifier of the successful login exists in response to determining that the login is successful, and continues to execute the connection operation in response to determining that it does not exist. This helps to monitor the login status of the user after the successful login, ensures that the user is always logged in, and thus helps the operation of subsequent applications.
[0050] In some optional manners, detecting whether a login process corresponding to a user identifier that has successfully logged in exists includes detecting whether a login process corresponding to a user identifier that has successfully logged in exists at preset time intervals.
[0051] In this implementation, the execution subject checks at a preset interval whether a login process corresponding to the user ID that has successfully logged in exists. If not, the connection operation is continued, that is, the VNC program is restarted, and based on the user name and password of other users that need to be started, the user name and password of the user whose login process corresponding to the user ID that has successfully logged in does not exist is logged in.
[0052] Among them, the preset duration can be set according to experience and actual needs, for example, 1 minute, 2 minutes, etc., and this application does not limit this.
[0053] Specifically, if Figure 3As shown, after the execution entity detects that a single user has logged in to the MacOS system upon startup 301, it performs an automatic login operation, i.e., reads the usernames and passwords of other users to be started from the configuration file 302, e.g., username A and password A for user loginer1, and username B and password B for user loginer2, and determines whether the reading is successful 303. If the reading fails, the execution entity continues to obtain the information. If the information is successful, the execution entity performs a connection operation, i.e., starts the VNC program and sets the IP address to be connected 304, e.g., 127.0.0.1, enters the username and password of the other user to be started, connects 305, and determines whether the connection is successful 306. If the connection fails, the execution entity continues to perform the automatic login operation. If the connection is successful, i.e., the login is successful, the execution entity waits for a preset interval, e.g., 5 seconds, and then exits the VNC program 307. Furthermore, the execution entity may continue to detect whether the login process corresponding to the user ID of the user who has successfully logged in exists 308. If both exist, then continue to detect whether the login process corresponding to the user ID of the user who has successfully logged in exists for each preset duration 309, for example, 1 minute. If it is determined that the login process corresponding to the user ID of the user who has successfully logged in does not exist, then continue to execute the connection operation.
[0054] This implementation method detects whether a login process corresponding to a successfully logged-in user ID exists at preset intervals, and in response to determining that it does not exist, continues to execute the connection operation, which helps to save system resources for login status detection.
[0055] Continue to see Figure 4 , Figure 4 It is a schematic diagram of an application scenario of the multi-user login method according to the present embodiment. The execution subject 401 can monitor in real time or periodically whether a single user has completed the login after the MacOS system is started. If a single user, for example, admin, is detected to have completed the login, the automatic login operation 402 is performed. Among them, the automatic login operation may include obtaining the user name and password of other users who need to be started from a preset configuration file 4021, for example, the user loginer1's user name A and password A, the user loginer2's user name B and password B; performing a connection operation 4022, the connection operation including: starting the VNC (Virtual Network Console) program and setting the IP to be connected; logging in based on the user name and password of the other user who needs to be started. In response to determining that the login is successful, exit the VNC program.
[0056] The multi-user login method provided by the embodiment of the present disclosure performs an automatic login operation in response to determining that a single user login is completed when the MacOS system is turned on, wherein the automatic login operation includes: obtaining the user name and password of other users that need to be started; performing a connection operation, and the connection operation includes: starting the VNC program and setting the IP to be connected, and logging in based on the user name and password of the other users that need to be started; in response to determining that the login is successful, exiting the VNC program. This effectively solves the problem in the prior art that the MacOS system only supports starting a single user when the system is turned on, and other users are not logged in. If you want to log in to the relevant user, you must open the user interface to switch accounts before you can log in, and the operation is complicated and inflexible, and realizes the simultaneous login of multiple users when the system is turned on.
[0057] Furthermore, since multiple users can log in successfully at the same time when the computer is turned on, the self-starting monitoring program corresponding to each user can also be automatically started. After rebooting, it can be automatically deployed with one click, without the need for manual operation, which can effectively simplify the operation steps.
[0058] Further references Figure 5 , which shows Figure 2 The process 500 of another embodiment of the multi-user login method is shown. In this embodiment, the process 500 of the multi-user login method may include the following steps:
[0059] Step 501 , in response to determining that a single user login is completed when the MacOS system is started, an automatic login operation is performed based on a plist file and a command line tool launchctl in the MacOS system.
[0060] In this embodiment, the execution entity can monitor in real time or periodically whether a single user has completed login after the MacOS system is started. If it is detected that a single user has completed login, an automatic login operation is performed based on the plist file and command line tool launchctl in the MacOS system.
[0061] Here, MacOS does not have the / etc / init.d / rc.local and service methods like Linux to set the program to start randomly, and needs to use the plist file to start it.
[0062] plist files are usually placed in the following paths:
[0063] / Library / LaunchDaemons / Daemon tasks defined by the administrator
[0064] / Library / LaunchAgents / Task items defined by the administrator for users
[0065] ~ / Library / LaunchAgents / Task items defined by users
[0066] / System / Library / LaunchAgents Task items defined by MacOS X for users
[0067] The launchctl command manages the startup scripts of MacOS and can be used to control the automatic startup or shutdown of services. The general syntax is:
[0068] launchctl load / path / to / service.plistsudo
[0069] launchctl unload / path / to / service.plist.
[0070] The execution entity can save the plist file of the automatic login operation to the path / Users / admin / / Library / LaunchAgents / to perform the automatic login operation after a single user logs in.
[0071] Step 502: In response to determining that the login is successful, exit the VNC program.
[0072] In this embodiment, the implementation details and technical effects of step 502 can be found in the description of step 502 and will not be repeated here.
[0073] The above embodiments of the present disclosure, Figure 2 Compared with the illustrated embodiment, it highlights that in response to determining that a single user login is completed when the MacOS system is started, an automatic login operation is performed based on the plist file and command line tool launchctl in the MacOS system, and after the login is successful, the VNC program is exited, which helps to improve the efficiency of multi-user login.
[0074] Further references Figure 6 As an implementation of the methods shown in the above figures, the present disclosure provides an embodiment of a multi-user login device. Figure 1 Corresponding to the method embodiment shown, the device can be specifically applied to various electronic devices.
[0075] like Figure 6 As shown, the multi-user login device 600 of this embodiment includes: a login module 601 and a logout module 602.
[0076] Among them, the login module 601 can be configured to perform an automatic login operation in response to determining that a single user login is completed when the MacOS system is started, wherein the automatic login operation includes: obtaining the user name and password of other users who need to be started; performing a connection operation, and the connection operation includes: starting the VNC program and setting the IP to be connected, and logging in based on the user name and password of other users who need to be started.
[0077] The exit module 602 may be configured to exit the VNC program in response to determining that the login is successful.
[0078] In some optional aspects of this embodiment, the login module is further configured to: in response to determining that a single user login is completed when the MacOS system is started, perform an automatic login operation based on a plist file and a command line tool launchctl in the MacOS system.
[0079] In some optional aspects of this embodiment, the connection operation further includes: in response to determining that the login has failed, continuing to perform the automatic login operation.
[0080] In some optional aspects of this embodiment, the device further includes: a detection module configured to, in response to determining that the login is successful, detect whether a login process corresponding to the user identifier of the user who has successfully logged in exists; and in response to determining that it does not exist, continue to execute the connection operation.
[0081] In some optional aspects of this embodiment, the detection module is further configured to: detect at preset intervals whether a login process corresponding to the user identifier of the user who has successfully logged in exists; and in response to determining that it does not exist, continue to execute the connection operation.
[0082] In some optional aspects of this embodiment, the exit module is further configured to: in response to determining that the login is successful, exit the VNC program after waiting for a preset time interval.
[0083] In the technical solutions disclosed herein, the acquisition, storage, and application of user personal information involved comply with the provisions of relevant laws and regulations and do not violate public order and good morals.
[0084] According to an embodiment of the present disclosure, the present disclosure also provides an electronic device, a readable storage medium, and a computer program product.
[0085] like Figure 7 , which is a block diagram of an electronic device according to a multi-user login method according to an embodiment of the present disclosure.
[0086] 700 is a block diagram of an electronic device according to a multi-user login method according to an embodiment of the present disclosure. The electronic device is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device may also represent various forms of mobile devices, such as personal digital assistants, cellular phones, smart phones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely examples and are not intended to limit the implementation of the present disclosure described and / or claimed herein.
[0087] like Figure 7 As shown, the electronic device includes: one or more processors 701, a memory 702, and interfaces for connecting various components, including high-speed interfaces and low-speed interfaces. The various components are connected to each other using different buses and can be installed on a common mainboard or installed in other ways as needed. The processor can process instructions executed in the electronic device, including instructions stored in or on the memory to display graphical information of a GUI on an external input / output device (such as a display device coupled to the interface). In other embodiments, if necessary, multiple processors and / or multiple buses can be used together with multiple memories and multiple memories. Similarly, multiple electronic devices can be connected, and each device provides some necessary operations (for example, as a server array, a group of blade servers, or a multi-processor system). Figure 7 A processor 701 is taken as an example.
[0088] Memory 702 is a non-transitory computer-readable storage medium provided by the present disclosure. The memory stores instructions executable by at least one processor, causing the at least one processor to perform the multi-user login method provided by the present disclosure. The non-transitory computer-readable storage medium of the present disclosure stores computer instructions for causing a computer to perform the multi-user login method provided by the present disclosure.
[0089] The memory 702 is a non-transient computer-readable storage medium that can be used to store non-transient software programs, non-transient computer executable programs and modules, such as the program instructions / modules corresponding to the multi-user login method in the embodiment of the present disclosure (for example, the attached Figure 6 The processor 701 executes the non-transient software programs, instructions, and modules stored in the memory 702 to execute various functional applications and data processing of the server, thereby implementing the multi-user login method in the above method embodiment.
[0090] The memory 702 may include a program storage area and a data storage area. The program storage area may store an operating system and applications required for at least one function; the data storage area may store data created by the use of the electronic device for face tracking, etc. Furthermore, the memory 702 may include high-speed random access memory and may also include non-volatile memory, such as at least one disk storage device, flash memory device, or other non-volatile solid-state storage device. In some embodiments, the memory 702 may optionally include a memory remotely located relative to the processor 701. These remote memories may be connected to the lane detection electronic device via a network. Examples of the aforementioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.
[0091] The electronic device of the multi-user login method may further include: an input device 703 and an output device 704. The processor 701, the memory 702, the input device 703 and the output device 704 may be connected via a bus or other means. Figure 7 The bus connection is taken as an example.
[0092] The input device 703 can receive input digital or character information, and generate key signal input related to user settings and function control of the electronic device for lane line detection, such as input devices such as a touch screen, a keypad, a mouse, a trackpad, a touch pad, an indicator stick, one or more mouse buttons, a trackball, and a joystick. The output device 704 may include a display device, an auxiliary lighting device (e.g., an LED), and a tactile feedback device (e.g., a vibration motor). The display device may include, but is not limited to, a liquid crystal display (LCD), a light emitting diode (LED) display, and a plasma display. In some embodiments, the display device may be a touch screen.
[0093] Various implementations of the systems and techniques described herein can be realized in digital electronic circuit systems, integrated circuit systems, dedicated ASICs (application specific integrated circuits), computer hardware, firmware, software, and / or combinations thereof. These various implementations can include being implemented in one or more computer programs that can be executed and / or interpreted on a programmable system that includes at least one programmable processor, which can be a special purpose or general purpose programmable processor that can receive data and instructions from a storage system, at least one input device, and at least one output device, and transmit data and instructions to the storage system, the at least one input device, and the at least one output device.
[0094] These computer programs (also referred to as programs, software, software applications, or code) include machine instructions for a programmable processor and can be implemented using high-level procedural and / or object-oriented programming languages, and / or assembly / machine languages. As used herein, the terms "machine-readable medium" and "computer-readable medium" refer to any computer program product, apparatus, and / or device (e.g., a magnetic disk, an optical disk, a memory, a programmable logic device (PLD)) for providing machine instructions and / or data to a programmable processor, including a machine-readable medium that receives machine instructions as a machine-readable signal. The term "machine-readable signal" refers to any signal for providing machine instructions and / or data to a programmable processor.
[0095] To provide interaction with a user, the systems and techniques described herein can be implemented on a computer having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and pointing device (e.g., a mouse or trackball) through which the user can provide input to the computer. Other types of devices can also be used to provide interaction with the user; for example, the feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including acoustic input, voice input, or tactile input).
[0096] The systems and techniques described herein can be implemented in a computing system that includes back-end components (e.g., as a data server), or a computing system that includes middleware components (e.g., an application server), or a computing system that includes front-end components (e.g., a user computer having a graphical user interface or a web browser through which a user can interact with implementations of the systems and techniques described herein), or a computing system that includes any combination of such back-end components, middleware components, or front-end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include a local area network (LAN), a wide area network (WAN), and the Internet.
[0097] Computer systems may include clients and servers. A client and server are generally remote from each other and typically interact through a communication network. The client and server relationship arises through computer programs running on the respective computers and having a client-server relationship to each other.
[0098] According to the technical solution of the embodiment of the present disclosure, multiple users can log in simultaneously after the MacOS system is turned on, which simplifies the subsequent operation steps.
[0099] It should be understood that the various forms of the processes shown above can be used to reorder, add, or delete steps. For example, the steps described in this application can be performed in parallel, sequentially, or in a different order, as long as the desired results of the technical solutions disclosed in this disclosure can be achieved. This is not a limitation herein.
[0100] The above specific embodiments do not constitute a limitation on the scope of protection of this disclosure. Those skilled in the art will appreciate that various modifications, combinations, sub-combinations, and substitutions may be made based on design requirements and other factors. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of this disclosure shall be included within the scope of protection of this disclosure.
Claims
1. A multi-user login method, comprising: In response to determining that a single user login is completed when the MacOS system is started, an automatic login operation is performed based on a plist file and a command line tool launchctl in the MacOS system, wherein the automatic login operation includes: Get the username and password of other users who need to be started; Executing a connection operation, the connection operation including: starting a VNC program and setting an IP address to be connected, and logging in based on the user name and password of the other user to be started; In response to determining that the login is successful, the VNC program is exited.
2. The method according to claim 1, wherein The connection operation further includes: In response to determining that the login has failed, continuing to perform the automatic login operation.
3. The method according to claim 2, further comprising: In response to determining that the login is successful, detecting whether a login process corresponding to the user identifier of the user who successfully logged in exists; In response to determining that it does not exist, continuing to perform the connection operation.
4. The method according to claim 3, wherein: The detecting whether a login process corresponding to the user identifier of the user who successfully logged in exists includes: The preset time interval detects whether a login process corresponding to the user ID of the user who successfully logged in exists.
5. The method according to any one of claims 1 to 4, wherein: In response to determining that the login is successful, exiting the VNC program includes: In response to determining that the login is successful, the VNC program is exited after waiting for a preset time interval.
6. A multi-user login device comprising: The login module is configured to, in response to determining that a single user login is completed when the MacOS system is started, perform an automatic login operation based on a plist file and a command line tool launchctl in the MacOS system, wherein the automatic login operation includes: Get the username and password of other users who need to be started; Executing a connection operation, the connection operation including: starting a VNC program and setting an IP address to be connected, and logging in based on the user name and password of the other user to be started; The exit module is configured to exit the VNC program in response to determining that the login is successful.
7. The device according to claim 6, wherein The connection operation further includes: In response to determining that the login has failed, continuing to perform the automatic login operation.
8. The apparatus according to claim 7, further comprising: A detection module is configured to, in response to determining that the login is successful, detect whether a login process corresponding to the user identifier of the user who successfully logged in exists; In response to determining that it does not exist, continuing to perform the connection operation.
9. The device according to claim 8, wherein The detection module is further configured to: The system checks at preset intervals whether a login process corresponding to the user identifier of the user who has successfully logged in exists; and in response to determining that the login process does not exist, continues to execute the connection operation.
10. The device according to any one of claims 6 to 9, wherein: The exit module is further configured to: In response to determining that the login is successful, the VNC program is exited after waiting for a preset time interval.
11. An electronic device, characterized in that: include: at least one processor; as well as a memory communicatively connected to the at least one processor; wherein, The memory stores instructions that can be executed by the at least one processor, so that the at least one processor can perform the method according to any one of claims 1 to 5.
12. A non-transitory computer-readable storage medium storing computer instructions, characterized in that: The computer instructions are used to cause the computer to execute the method according to any one of claims 1 to 5.
13. A computer program product comprising a computer program, which, when executed by a processor, implements the method according to any one of claims 1 to 5.
Citation Information
Patent Citations
Login authentication method and electronic device
CN103020500A
Desktop virtualization and remote desktop connection method
CN110442429A