CN114531433B - Interaction method and device of web login equipment - Google Patents

Interaction method and device of web login equipment Download PDF

Info

Publication number
CN114531433B
CN114531433B CN202011228246.6A CN202011228246A CN114531433B CN 114531433 B CN114531433 B CN 114531433B CN 202011228246 A CN202011228246 A CN 202011228246A CN 114531433 B CN114531433 B CN 114531433B
Authority
CN
China
Prior art keywords
login
jump
equipment
logging
target
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202011228246.6A
Other languages
Chinese (zh)
Other versions
CN114531433A (en
Inventor
杨欢
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Unihub China Information Technology Co Ltd
Original Assignee
Unihub China Information Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Unihub China Information Technology Co Ltd filed Critical Unihub China Information Technology Co Ltd
Priority to CN202011228246.6A priority Critical patent/CN114531433B/en
Publication of CN114531433A publication Critical patent/CN114531433A/en
Application granted granted Critical
Publication of CN114531433B publication Critical patent/CN114531433B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/02Protocols based on web technology, e.g. hypertext transfer protocol [HTTP]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L63/00Network architectures or network communication protocols for network security
    • H04L63/08Network architectures or network communication protocols for network security for authentication of entities
    • H04L63/083Network architectures or network communication protocols for network security for authentication of entities using passwords
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L63/00Network architectures or network communication protocols for network security
    • H04L63/16Implementing security features at a particular protocol layer
    • H04L63/168Implementing security features at a particular protocol layer above the transport layer
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/14Session management
    • H04L67/141Setup of application sessions
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L69/00Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
    • H04L69/16Implementation or adaptation of Internet protocol [IP], of transmission control protocol [TCP] or of user datagram protocol [UDP]
    • H04L69/161Implementation details of TCP/IP or UDP/IP stack architecture; Specification of modified or new header fields
    • H04L69/162Implementation details of TCP/IP or UDP/IP stack architecture; Specification of modified or new header fields involving adaptations of sockets based mechanisms

Abstract

The embodiment of the invention provides an interaction method and device of web login equipment. The method comprises the steps of receiving a login device request; analyzing a login device request, judging whether a skip information parameter exists in the login device request, if so, logging in a target device through the login skip device, and establishing an interactive terminal of the target device; otherwise, logging in the target equipment by creating a websocket channel, and establishing an interactive terminal of the target equipment; and executing command issuing to the target device on the interactive terminal. In this way, the quick login from the network management system to the target equipment can be realized in a web mode, a client is not required to be installed, and the use mode is friendly; the device is logged in an interface mode, an interface can be provided for upper-layer applications, mainstream protocols ssh and telnet are supported, and the application is wider.

Description

Interaction method and device of web login equipment
Technical Field
The embodiments of the present invention relate generally to the field of communications, and more particularly, to an interaction method and apparatus for a web login device.
Background
In the current network management system (hereinafter, simply referred to as network management), operators usually rely on client software such as a router or a switch, etc. to manage or maintain network devices, but these are all in the form of clients, and in fact most network management architectures are based on BS architecture, so that logging in from the network management to the devices requires invoking the client software of the system such as the security crt, the Xshell, etc. but this approach has the following drawbacks:
1. the method can not operate which instructions according to the network management user auditing the user logging in the equipment;
2. the user can log in the device only by installing client software such as a SecureCRT or an Xshell, so as to realize interaction;
3. when the system client is called to log in, the user name and the password of the login equipment are required to be input again, so that the login process is complicated, inconvenient and unfriendly to operate.
Disclosure of Invention
According to the embodiment of the invention, an interaction scheme of web login equipment is provided.
In a first aspect of the invention, an interaction method of a web login device is provided. The method comprises the following steps:
receiving a login device request;
analyzing the login equipment request, judging whether a jump information parameter exists in the login equipment request, if so, logging in the target equipment through the login jump equipment, and establishing an interactive terminal of the target equipment; otherwise, logging in the target equipment by creating a websocket channel, and establishing an interactive terminal of the target equipment;
and executing command issuing to the target equipment on the interactive terminal.
Further, the login device request comprises a login type parameter, a login user name parameter, a login device address parameter, a login device port parameter and a login device password parameter.
Further, the skip information parameters include one or more skip commands, each skip command including: jump address, username and password; the jump address, the user name and the password are separated by a primary separator, and the jump address comprises a protocol and an IP address; every two jump commands are separated by a secondary separator.
Further, the logging-in to the target device through the logging-in jump device, and establishing the interactive terminal of the target device, includes:
when the jump information parameter contains a jump command, logging in a first jump device, and after successful logging in, sending a login success message, wherein the login success message is used for triggering and executing the jump command, and logging in a target device according to a protocol address, a user name and a password; when the first jump equipment or the target equipment is failed to log in, a log-in failure message is sent out, wherein the log-in failure message is used for triggering the interactive terminal to be withdrawn, and the failure message is returned after the withdrawal;
when the jump information parameter contains a plurality of jump commands, logging in a first jump device, and after logging in is successful, sending a login success message, wherein the login success message is used for triggering the sequential execution of the jump commands, logging in the jump device according to the protocol address, the user name and the password of the jump command, and logging in the target device according to the protocol address, the user name and the password of the last jump command; and when the login of the jump equipment or the target equipment fails, sending out a login failure message, wherein the login failure message is used for triggering the interaction terminal to exit, and returning a failure message after exiting.
Further, the websocket channel is created through page JavaScript, and ssh protocol or telnet protocol of the connection device is used for sending and receiving messages between the interactive terminal and the target device.
Further, the method further comprises the following steps:
and the interactive terminal generates a log file and records the instruction operation of the target equipment.
Further, the method further comprises the following steps:
when the login state of the target equipment needs to be exited, receiving a message returned by the execution exit command, judging whether the message returned by the execution exit command is consistent with the equipment mark of the target equipment, if so, disconnecting the target equipment from the interactive terminal, and exiting the interactive terminal; otherwise, not operating.
In a second aspect of the invention, an interaction means for a web login device is provided. The device comprises:
the receiving module is used for receiving a login device request;
the analysis module is used for analyzing the login equipment request, judging whether the login equipment request has jump information parameters, if so, logging in the target equipment through the login jump equipment, and establishing an interactive terminal of the target equipment; otherwise, logging in the target equipment by creating a websocket channel, and establishing an interactive terminal of the target equipment;
and the execution module is used for executing the command issuing to the target equipment on the interactive terminal.
In a third aspect of the invention, an electronic device is provided. The electronic device includes: a memory and a processor, the memory having stored thereon a computer program, the processor implementing the method as described above when executing the program.
In a fourth aspect of the invention, there is provided a computer readable storage medium having stored thereon a computer program which when executed by a processor implements a method as according to the first aspect of the invention.
It should be understood that the description in this summary is not intended to limit the critical or essential features of the embodiments of the invention, nor is it intended to limit the scope of the invention. Other features of the present invention will become apparent from the description that follows.
The invention realizes the quick login from the network management system to the target equipment in a web mode, does not need to install a client, and has friendly use mode; the device is logged in an interface mode, an interface can be provided for upper-layer applications, mainstream protocols ssh and telnet are supported, and the application is wider.
Drawings
The above and other features, advantages and aspects of embodiments of the present invention will become more apparent by reference to the following detailed description when taken in conjunction with the accompanying drawings. In the drawings, wherein like or similar reference numerals denote like or similar elements, in which:
FIG. 1 illustrates a flow chart of a method of interaction of a web login device according to an embodiment of the invention;
FIG. 2 shows a schematic diagram of a login procedure according to an embodiment of the invention;
FIG. 3 shows a block diagram of an interaction means of a web login device according to an embodiment of the invention;
fig. 4 shows a block diagram of an exemplary electronic device capable of implementing embodiments of the invention.
Detailed Description
For the purpose of making the objects, technical solutions and advantages of the embodiments of the present invention more apparent, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention, and it is apparent that the described embodiments are some embodiments of the present invention, but not all embodiments of the present invention. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to be within the scope of the invention.
In addition, the term "and/or" herein is merely an association relationship describing an association object, and means that three relationships may exist, for example, a and/or B may mean: a exists alone, A and B exist together, and B exists alone. In addition, the character "/" herein generally indicates that the front and rear associated objects are an "or" relationship.
In the invention, the quick login from the network management system to the target equipment is realized in a web mode, a client is not required to be installed, and the use mode is friendly; the device is logged in an interface mode, an interface can be provided for upper-layer applications, mainstream protocols ssh and telnet are supported, and the application is wider.
FIG. 1 illustrates a flow chart of a method of interaction of a web login device according to an embodiment of the present invention.
The method comprises the following steps:
s101, receiving a login device request.
A user sends a login device request from a webpage or other applications, and a server receives the login device request. For example, a user logs in a network management front-end page through a clicking device, the page sends an http post request, and a server receives the http post request.
The login equipment request comprises a plurality of request parameters, and the request parameters are divided into two types according to the necessary filling items and the optional filling items. The necessary padding item is the request parameter which is necessary in the login device request, and the optional padding item is the request parameter which can exist.
The request parameters of the necessary filling item comprise login type parameters, login user name parameters, login equipment address parameters, login equipment port parameters, login equipment password parameters and the like. The request parameters of the option include a skip information parameter. Wherein the login type parameter describes a login type, e.g. ssh/telnet; the login user name parameter describes the user name of login equipment; the login device address parameter describes the address information of the login device; the login device port parameter describes port information of login devices; the login device password parameter describes the login password of the login device. The skip information parameter describes a skip login mode and supports multiple skip logins to the designated equipment. The skip information parameters include one or more skip commands, each skip command including: jump address, username and password; the jump address, the user name and the password are separated by a primary separator, and the jump address comprises a protocol and an IP address; every two jump commands are separated by a secondary separator.
As an embodiment of the present invention, a skip information parameter telnet127.0.1# # user1# # passwt1# # ssh 127.0.0.2# # user2# # passwd2, indicates that the skip device 1 is logged in first, the device address is 127.0.0.1, the user name is user1, and the password is passwd1; and logging in the target device again, wherein the device address is 127.0.0.2, the user name is user2, and the password is passwd2. The method comprises the steps that # percent# represents a primary separator, if the primary separator is an ssh protocol, a login mode and a password separation are separated through the primary separator, and the login mode is expressed in the forms of the ssh protocol and a user name @ IP address; in the case of telnet protocol, the jump address, user name and password are separated by a primary separator. The # +% # indicates a secondary delimiter for separating a plurality of jump commands. Typically the ssh protocol default port is 22 and the telnet protocol default port is 23.
As an embodiment of the present invention, a login device request is shown in table 1 below:
TABLE 1
S102, analyzing the login equipment request, judging whether a jump information parameter exists in the login equipment request, if so, logging in the target equipment through the login jump equipment, and establishing an interactive terminal of the target equipment; otherwise, logging in the target equipment by creating a websocket channel, and establishing an interactive terminal of the target equipment.
As shown in fig. 2, the parsing process can be subdivided into the following three cases:
first case: the skip information parameter Command in the login device request is null, i.e. the skip information parameter does not exist in the login device request.
In this case, by creating a websocket channel, logging in to the target device, and establishing an interactive terminal of the target device. The page creates a websocket channel through JavaScript, and the channel is connected with ssh/telnet of the device. An asynchronous interactive terminal (terminal) of the login device is created through the websocket channel and the ssh/telnet according to login type (Logintype). The interactive terminal sends data to the equipment and receives the data returned by the equipment through the websocket channel. When the login fails, the interactive terminal is exited and the failure is returned. The Browser is a Browser, such as ie, chrome,360, fire fox, etc.
Second case: the skip information parameter Command in the login device request is not null, namely the skip information parameter exists in the login device request, and the skip information parameter comprises a skip Command.
In this case, logging in the first jump device, and after successful logging in, sending a login success message, where the login success message is used to trigger execution of the jump command, and logging in the target device according to the protocol address, the user name and the password; when the first jump equipment or the target equipment is failed to log in, a log-in failure message is sent out, and the log-in failure message is used for triggering the interactive terminal to be withdrawn and returning a failure message after the first jump equipment or the target equipment is withdrawn.
As an embodiment of the present invention, as shown in fig. 2, the command parameter of the skip information is ssh user2@127.0.0.2# # passwd2. Firstly, logging in the jump equipment 1, wherein the equipment address is a parameter hostname; after successful login of the jump device 1, the login device 2 is executed, the device address 127.0.0.2 of the login device is user2, the password is passwd2, and the login mode is a command in the execution parameters: ssh user2@127.0.0.2 and inputting a login password passwd2 to finish login. When there is a failure to log on to the jump device 1 or device 2, the interactive terminal is exited and a failure is returned. Wherein command parameters are not limited to ssh/telnet, and any one can be supported.
Third case: the command of the skip information parameter in the login device request is not null, namely the skip information parameter exists in the login device request, and the skip information parameter comprises a plurality of skip commands.
Under the condition, logging in the first jump equipment, and sending out a login success message after successful login, wherein the login success message is used for triggering the sequential execution of the jump commands, logging in the jump equipment according to the protocol address, the user name and the password of the jump command, and logging in the target equipment according to the protocol address, the user name and the password of the last jump command; and when the login of the jump equipment or the target equipment fails, sending out a login failure message, wherein the login failure message is used for triggering the interaction terminal to exit, and returning a failure message after exiting.
As an embodiment of the present invention, as shown in fig. 2, the command parameter is telnet127.0.0.1# # user2# # passwd2# # sshuser3@127.0.0.2# # passwd3. The jump equipment 2 is logged in firstly, the equipment address is a parameter hostname, the jump equipment 3 is logged in after the login is successful, the equipment address is 127.0.0.1, the user name is user2, the password is passwd2, and the login mode is to execute the command in the parameters: telnet127.0.0.1 and inputs the login password user2 and password passwd2, and logs in the target device 3 after successfully logging in the jump device 3, wherein the device address 127.0.0.2 of the target device 3 is that the user name is user3, the password is passwd3, and the login mode is that the command in the execution parameters is as follows: ssh user3@127.0.0.2, and enters its login password passwd3. When one of the login jump device 2, the jump device 3 or the device 3 fails, the interactive terminal is exited and a failure is returned. Wherein command parameters are not limited to ssh/telnet, and any one can be supported.
The invention carries out jump login through the jump equipment, which aims at dividing some equipment in the network according to the city or the domain, and the deployment of the device can not directly reach the corresponding target equipment (the network is not connected), so the jump login is needed to be realized through the jump equipment. The method solves the problem of achieving the login of the target equipment under the condition that the network is not enabled.
S103, executing command issuing to the target equipment on the interactive terminal.
After logging in the target device and creating the interactive terminal, the command issued to the target device is executed at the interactive terminal, which is generally executed in batch.
When a batch execution instruction is requested in the currently created interactive terminal, selecting a file containing the batch execution instruction, sequentially sending the instruction in the file to equipment for execution by a webpage, displaying an execution result on the interactive terminal, and recording operations in a log.
As an embodiment of the present invention, the interaction method of the web login device further includes: and the interactive terminal generates a log file and records the instruction operation of the target equipment.
After the login to the target equipment is successful and the interactive terminal is created, the instruction operation on the equipment can be realized and the logs of all operations can be recorded. Each time a device is successfully logged in, a uuid is generated, and is used as a unique id identifier, the uuid is transmitted to a server (the device), and a log file name is generated. When the current created interactive terminal requests to download the log, the log file recorded by the interactive terminal is downloaded according to the uuid corresponding to the interactive terminal.
All operation logs logged in a web mode can be recorded through automatic log recording, and basis is provided for security and audit.
As an embodiment of the present invention, the interaction method of the web login device further includes:
after logging in to the target device and creating the interactive terminal, the server records the hostname of the target device, namely, the hostname. When the login state of the target device needs to be logged out, receiving a message returned by executing a log-out command, for example exit, logout, quit; judging whether the message returned by the executing exit command is consistent with the equipment mark of the target equipment, if so, disconnecting the target equipment from the interactive terminal, namely, connecting the telnet/ssh equipment, and exiting the interactive terminal; this operation is to prevent a problem of security caused by the exit to the jumper when the target device is exited, since the exit to the jumper can operate the jumper server, which may cause a problem of security. And if the message returned by the execution exit command is inconsistent with the device mark of the target device, the operation is not performed. The connection is not operated, i.e. closed, because it may be an operation of a configuration command on the device instead of a command to exit the login state.
According to the embodiment of the invention, the quick login from the network management system to the target equipment is realized in a web mode, a client is not required to be installed, and the use mode is friendly; the device is logged in an interface mode, an interface can be provided for upper-layer applications, mainstream protocols ssh and telnet are supported, and the application is wider.
It should be noted that, for simplicity of description, the foregoing method embodiments are all described as a series of acts, but it should be understood by those skilled in the art that the present invention is not limited by the order of acts described, as some steps may be performed in other orders or concurrently in accordance with the present invention. Further, those skilled in the art will also appreciate that the embodiments described in the specification are alternative embodiments, and that the acts and modules referred to are not necessarily required for the present invention.
The above description of the method embodiments further describes the solution of the present invention by means of device embodiments.
As shown in fig. 3, the apparatus 300 includes:
a receiving module 310, configured to receive a login device request.
The user sends a login device request from a web page or other application, and the server receives the login device request through the receiving module 310.
The login equipment request comprises a plurality of request parameters, and the request parameters are divided into two types according to the necessary filling items and the optional filling items. The necessary padding item is the request parameter which is necessary in the login device request, and the optional padding item is the request parameter which can exist.
The request parameters of the necessary filling item comprise login type parameters, login user name parameters, login equipment address parameters, login equipment port parameters, login equipment password parameters and the like. The request parameters of the option include a skip information parameter. Wherein the login type parameter describes a login type, e.g. ssh/telnet; the login user name parameter describes the user name of login equipment; the login device address parameter describes the address information of the login device; the login device port parameter describes port information of login devices; the login device password parameter describes the login password of the login device. The skip information parameter describes a skip login mode and supports multiple skip logins to the designated equipment. The skip information parameters include one or more skip commands, each skip command including: jump address, username and password; the jump address, the user name and the password are separated by a primary separator, and the jump address comprises a protocol and an IP address; every two jump commands are separated by a secondary separator.
The parsing module 320 is configured to parse the login device request, determine whether a skip information parameter exists in the login device request, and if so, log in the target device through the login skip device, and establish an interaction terminal of the target device; otherwise, logging in the target equipment by creating a websocket channel, and establishing an interactive terminal of the target equipment.
The parsing process can be subdivided into the following three cases:
first case: the parsing module 320 parses out that the skip information parameter Command in the login device request is null, i.e. the skip information parameter does not exist in the login device request.
In this case, by creating a websocket channel, logging in to the target device, and establishing an interactive terminal of the target device. The page creates a websocket channel through JavaScript, and the channel is connected with ssh/telnet of the device. According to different login types (Logintype), the interactive terminal of the login device is created through a websocket channel and ssh/telnet. The interactive terminal sends data to the equipment and receives the data returned by the equipment through the websocket channel. When the login fails, the interactive terminal is exited and the failure is returned.
Second case: the parsing module 320 parses out that the Command of the skip information parameter in the login device request is not null, that is, the skip information parameter exists in the login device request, and the skip information parameter includes a skip Command.
In this case, logging in the first jump device, and after successful logging in, sending a login success message, where the login success message is used to trigger execution of the jump command, and logging in the target device according to the protocol address, the user name and the password; when the first jump equipment or the target equipment is failed to log in, a log-in failure message is sent out, and the log-in failure message is used for triggering the interactive terminal to be withdrawn and returning a failure message after the first jump equipment or the target equipment is withdrawn.
Third case: the parsing module 320 parses out that the skip information parameter Command in the login device request is not null, that is, the skip information parameter exists in the login device request, and the skip information parameter includes a plurality of skip commands.
Under the condition, logging in the first jump equipment, and sending out a login success message after successful login, wherein the login success message is used for triggering the sequential execution of the jump commands, logging in the jump equipment according to the protocol address, the user name and the password of the jump command, and logging in the target equipment according to the protocol address, the user name and the password of the last jump command; and when the login of the jump equipment or the target equipment fails, sending out a login failure message, wherein the login failure message is used for triggering the interaction terminal to exit, and returning a failure message after exiting.
The invention carries out jump login through the jump equipment, which aims at dividing some equipment in the network according to the city or the domain, and the deployment of the device can not directly reach the corresponding target equipment (the network is not connected), so the jump login is needed to be realized through the jump equipment. The method solves the problem of achieving the login of the target equipment under the condition that the network is not enabled.
And the execution module 330 is configured to execute command issuing to the target device on the interaction terminal.
After logging in the target device and creating the interactive terminal, the execution module 330 executes the command issued to the target device at the interactive terminal, which is generally executed in batch.
When a batch execution instruction is requested in the currently created interactive terminal, selecting a file containing the batch execution instruction, sequentially sending the instruction in the file to equipment for execution by a webpage, displaying an execution result on the interactive terminal, and recording operations in a log.
As an embodiment of the present invention, the apparatus 300 further includes:
the log file generating module 340 is configured to generate a log file, and record the instruction operation of the target device.
After the login to the target equipment is successful and the interactive terminal is created, the instruction operation on the equipment can be realized and the logs of all operations can be recorded. Each time a device is successfully logged in, the log file generating module 340 generates a uuid, which is used as a unique id identifier, and the uuid is transmitted to a server (the device) and generates a log file name. When the current created interactive terminal requests to download the log, the log file recorded by the interactive terminal is downloaded according to the uuid corresponding to the interactive terminal.
All operation logs logged in a web mode can be recorded by automatically logging through the log file generating module 340, so that basis is provided for security and audit.
As an embodiment of the present invention, the apparatus 300 further includes: the determination module 350 is exited.
After logging in to the target device and creating the interactive terminal, the server records the hostname of the target device, namely, the hostname. When the login state of the target device needs to be logged out, the log-out judging module 350 receives a message returned by executing a log-out command, for example exit, logout, quit; the exit judging module 350 judges whether the message returned by the executing exit command is consistent with the device mark of the target device, if so, the connection between the target device and the interactive terminal, namely, the telnet/ssh device is disconnected, and the interactive terminal is exited; this operation is to prevent a problem of security caused by the exit to the jumper when the target device is exited, since the exit to the jumper can operate the jumper server, which may cause a problem of security. And if the message returned by the execution exit command is inconsistent with the device mark of the target device, the operation is not performed. The connection is not operated, i.e. closed, because it may be an operation of a configuration command on the device instead of a command to exit the login state.
It will be clear to those skilled in the art that, for convenience and brevity of description, specific working procedures of the described modules may refer to corresponding procedures in the foregoing method embodiments, which are not described herein again.
As shown in fig. 4, the apparatus includes a Central Processing Unit (CPU) that can perform various suitable actions and processes according to computer program instructions stored in a Read Only Memory (ROM) or computer program instructions loaded from a storage unit into a Random Access Memory (RAM). In the RAM, various programs and data required for the operation of the device can also be stored. The CPU, ROM and RAM are connected to each other by a bus. An input/output (I/O) interface is also connected to the bus.
A plurality of components in a device are connected to an I/O interface, comprising: an input unit such as a keyboard, a mouse, etc.; an output unit such as various types of displays, speakers, and the like; a storage unit such as a magnetic disk, an optical disk, or the like; and communication units such as network cards, modems, wireless communication transceivers, and the like. The communication unit allows the device to exchange information/data with other devices via a computer network, such as the internet, and/or various telecommunication networks.
The processing unit performs the respective methods and processes described above, for example, the methods S101 to S103. For example, in some embodiments, methods S101-S103 may be implemented as a computer software program tangibly embodied on a machine-readable medium, such as a storage unit. In some embodiments, part or all of the computer program may be loaded and/or installed onto the device via the ROM and/or the communication unit. When the computer program is loaded into RAM and executed by the CPU, one or more steps of the methods S101 to S103 described above may be performed. Alternatively, in other embodiments, the CPU may be configured to perform methods S101-S103 by any other suitable means (e.g., by means of firmware).
The functions described above herein may be performed, at least in part, by one or more hardware logic components. For example, without limitation, exemplary types of hardware logic components that may be used include: a Field Programmable Gate Array (FPGA), an Application Specific Integrated Circuit (ASIC), an Application Specific Standard Product (ASSP), a system on a chip (SOC), a load programmable logic device (CPLD), etc.
Program code for carrying out methods of the present invention may be written in any combination of one or more programming languages. These program code may be provided to a processor or controller of a general purpose computer, special purpose computer, or other programmable data processing apparatus such that the program code, when executed by the processor or controller, causes the functions/operations specified in the flowchart and/or block diagram to be implemented. The program code may execute entirely on the machine, partly on the machine, as a stand-alone software package, partly on the machine and partly on a remote machine or entirely on the remote machine or server.
In the context of the present invention, a machine-readable medium may be a tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. The machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. The machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any suitable combination of the foregoing. More specific examples of a machine-readable storage medium would include an electrical connection based on one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
Moreover, although operations are depicted in a particular order, this should be understood as requiring that such operations be performed in the particular order shown or in sequential order, or that all illustrated operations be performed, to achieve desirable results. In certain circumstances, multitasking and parallel processing may be advantageous. Likewise, while several specific implementation details are included in the above discussion, these should not be construed as limiting the scope of the invention. Certain features that are described in the context of separate embodiments can also be implemented in combination in a single implementation. Conversely, various features that are described in the context of a single implementation can also be implemented in multiple implementations separately or in any suitable subcombination.
Although the subject matter has been described in language specific to structural features and/or methodological acts, it is to be understood that the subject matter defined in the appended claims is not necessarily limited to the specific features or acts described above. Rather, the specific features and acts described above are example forms of implementing the claims.

Claims (9)

1. A method of interacting with a web login device, comprising:
receiving a login device request;
analyzing the login equipment request, judging whether a jump information parameter exists in the login equipment request, if so, logging in the target equipment through the login jump equipment, and establishing an interactive terminal of the target equipment; otherwise, logging in the target equipment by creating a websocket channel, and establishing an interactive terminal of the target equipment;
executing command issuing to the target equipment on the interactive terminal;
the method for establishing the interactive terminal of the target equipment by logging in the jump equipment comprises the following steps of:
when the jump information parameter contains a jump command, logging in a first jump device, and after successful logging in, sending a login success message, wherein the login success message is used for triggering and executing the jump command, and logging in a target device according to a protocol address, a user name and a password; when the first jump equipment or the target equipment is failed to log in, a log-in failure message is sent out, wherein the log-in failure message is used for triggering the interactive terminal to be withdrawn, and the failure message is returned after the withdrawal;
when the jump information parameter contains a plurality of jump commands, logging in a first jump device, and after logging in is successful, sending a login success message, wherein the login success message is used for triggering the sequential execution of the jump commands, logging in the jump device according to the protocol address, the user name and the password of the jump command, and logging in the target device according to the protocol address, the user name and the password of the last jump command; and when the login of the jump equipment or the target equipment fails, sending out a login failure message, wherein the login failure message is used for triggering the interaction terminal to exit, and returning a failure message after exiting.
2. The method of claim 1, wherein the login device request includes a login type parameter, a login user name parameter, a login device address parameter, a login device port parameter, a login device password parameter.
3. The method of claim 1, wherein the skip information parameters include one or more skip commands, each skip command comprising: jump address, username and password; the jump address, the user name and the password are separated by a primary separator, and the jump address comprises a protocol and an IP address; every two jump commands are separated by a secondary separator.
4. The method of claim 1, wherein the websocket channel is created through page JavaScript, and the ssh protocol or telnet protocol of the connection device is used for sending and receiving messages between the interactive terminal and the target device.
5. The method as recited in claim 1, further comprising:
and the interactive terminal generates a log file and records the instruction operation of the target equipment.
6. The method as recited in claim 1, further comprising:
when the login state of the target equipment needs to be exited, receiving a message returned by the execution exit command, judging whether the message returned by the execution exit command is consistent with the equipment mark of the target equipment, if so, disconnecting the target equipment from the interactive terminal, and exiting the interactive terminal; otherwise, not operating.
7. An interactive apparatus for web login device, comprising:
the receiving module is used for receiving a login device request;
the analysis module is used for analyzing the login equipment request, judging whether the login equipment request has jump information parameters, if so, logging in the target equipment through the login jump equipment, and establishing an interactive terminal of the target equipment; otherwise, logging in the target equipment by creating a websocket channel, and establishing an interactive terminal of the target equipment;
the method for establishing the interactive terminal of the target equipment by logging in the jump equipment comprises the following steps of:
when the jump information parameter contains a jump command, logging in a first jump device, and after successful logging in, sending a login success message, wherein the login success message is used for triggering and executing the jump command, and logging in a target device according to a protocol address, a user name and a password; when the first jump equipment or the target equipment is failed to log in, a log-in failure message is sent out, wherein the log-in failure message is used for triggering the interactive terminal to be withdrawn, and the failure message is returned after the withdrawal;
when the jump information parameter contains a plurality of jump commands, logging in a first jump device, and after logging in is successful, sending a login success message, wherein the login success message is used for triggering the sequential execution of the jump commands, logging in the jump device according to the protocol address, the user name and the password of the jump command, and logging in the target device according to the protocol address, the user name and the password of the last jump command; when the login of the jump equipment or the target equipment fails, a login failure message is sent out, wherein the login failure message is used for triggering the interaction terminal to exit, and the failure message is returned after the interaction terminal exits;
and the execution module is used for executing the command issuing to the target equipment on the interactive terminal.
8. An electronic device comprising a memory and a processor, the memory having stored thereon a computer program, characterized in that the processor, when executing the program, implements the method according to any of claims 1-6.
9. A computer readable storage medium, on which a computer program is stored, characterized in that the program, when being executed by a processor, implements the method according to any one of claims 1-6.
CN202011228246.6A 2020-11-06 2020-11-06 Interaction method and device of web login equipment Active CN114531433B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011228246.6A CN114531433B (en) 2020-11-06 2020-11-06 Interaction method and device of web login equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011228246.6A CN114531433B (en) 2020-11-06 2020-11-06 Interaction method and device of web login equipment

Publications (2)

Publication Number Publication Date
CN114531433A CN114531433A (en) 2022-05-24
CN114531433B true CN114531433B (en) 2023-07-21

Family

ID=81618562

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011228246.6A Active CN114531433B (en) 2020-11-06 2020-11-06 Interaction method and device of web login equipment

Country Status (1)

Country Link
CN (1) CN114531433B (en)

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1599330A (en) * 2004-03-05 2005-03-23 上海傲威通信技术有限公司 Method for realizing remote accession management for network equipment in NAT
CN105872019A (en) * 2016-03-23 2016-08-17 北京搜狐新媒体信息技术有限公司 Method and device for logging in Docker container by Web end
CN107493344A (en) * 2017-08-29 2017-12-19 郑州云海信息技术有限公司 A kind of method and system of web access Docker containers
CN110620814A (en) * 2019-09-10 2019-12-27 西安交大捷普网络科技有限公司 Control method and system for operation and maintenance login of Web browser
CN110719276A (en) * 2019-09-30 2020-01-21 北京网瑞达科技有限公司 Network equipment safety access system based on cache password and working method thereof
CN111125039A (en) * 2018-10-30 2020-05-08 华为技术有限公司 Method and device for generating operation log
CN111405006A (en) * 2020-03-06 2020-07-10 北京奇艺世纪科技有限公司 Method and device for processing remote login failure and remote login system

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7904536B2 (en) * 2002-06-03 2011-03-08 Oracle America, Inc. Method and system for remote management of customer servers

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1599330A (en) * 2004-03-05 2005-03-23 上海傲威通信技术有限公司 Method for realizing remote accession management for network equipment in NAT
CN105872019A (en) * 2016-03-23 2016-08-17 北京搜狐新媒体信息技术有限公司 Method and device for logging in Docker container by Web end
CN107493344A (en) * 2017-08-29 2017-12-19 郑州云海信息技术有限公司 A kind of method and system of web access Docker containers
CN111125039A (en) * 2018-10-30 2020-05-08 华为技术有限公司 Method and device for generating operation log
CN110620814A (en) * 2019-09-10 2019-12-27 西安交大捷普网络科技有限公司 Control method and system for operation and maintenance login of Web browser
CN110719276A (en) * 2019-09-30 2020-01-21 北京网瑞达科技有限公司 Network equipment safety access system based on cache password and working method thereof
CN111405006A (en) * 2020-03-06 2020-07-10 北京奇艺世纪科技有限公司 Method and device for processing remote login failure and remote login system

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
远程登录维护机报故障;赖文书;;网络安全和信息化(第01期);全文 *

Also Published As

Publication number Publication date
CN114531433A (en) 2022-05-24

Similar Documents

Publication Publication Date Title
EP4026297B1 (en) Honeypots for infrastructure-as-a-service security
US20180287937A1 (en) Processing data packets using a policy based network path
US11140162B2 (en) Response method and system in virtual network computing authentication, and proxy server
US20150012964A1 (en) Application layer-based single sign on
GB2563391A (en) Methods and systems for identifying data sessions at a VPN gateway
US10164961B2 (en) Dynamic web services server
US10034057B2 (en) Message processing method, device, gateway, STB and IPTV
CN112221121A (en) Application software networking acceleration method and device and storage medium
CN112187491A (en) Server management method, device and equipment
CN112583815B (en) Operation instruction management method and device
CN112188277B (en) Screen projection control method and device, electronic equipment and computer program medium
US20170102989A1 (en) Method and system for dynamically unblocking customers in critical workflows by pushing community contributed solutions just-in-time when an error is encountered
CN112333044A (en) Shunting equipment performance test method, device and system, electronic equipment and medium
CN111984561A (en) IPMI command processing method, system, device and medium for BMC
US10367894B2 (en) Information processing apparatus, method for controlling the same, non-transitory computer-readable storage medium, and information processing system
US10478731B2 (en) Method and apparatus for storing user data
CN113328877B (en) Method and device for determining port protocol
US20220311745A1 (en) Virtual on-demand internet connectivity for management controllers
CN114531433B (en) Interaction method and device of web login equipment
CN112511620A (en) Network communication method, device, equipment and storage medium
CN111935177A (en) Service control method and device
CN113873041B (en) Message transmission method, device, network equipment and computer readable storage medium
US20180335894A1 (en) Messaging and orchestrating platform in a computer network environment
CN103457771A (en) Method and device for HA virtual machine cluster management
US11038915B1 (en) Dynamic generation of courses of action for incident response in an information technology environment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant