USB network redirection-based softdog dynamic scheduling method and related equipment
By adopting the dynamic scheduling method based on the USB network redirection in the encryption dog management, the problem of damage monitoring in the existing encrypted dog management in the existing encrypted dog management is not timely and the serial processing efficiency is low, and the efficient sharing and management of encrypted dogs is realized, and the management of the encrypted dogs is improved. Operation and maintenance efficiency.
Patent Information
- Application Number
- CN202411492047.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-24
- Publication Date
- 2025-01-24
AI Technical Summary
The existing dongle management methods include equipment damage and real-time monitoring, and the single-machine hardware damage causes the node machine to be unable to participate in the verification work. The one-to-one network mount method leads to serial processing, which makes management efficiency low.
Using a dongle dynamic scheduling method based on USB network redirection, the dongle is set on the node machine corresponding to the forwarding client through the USB port, and is shared with the node machine corresponding to the non-forwarding client under the management of the forwarding server. The dongle information USB Over Network sharing is realized through database storage and management.
The management effect and efficiency of encrypted dogs have been improved, the verification work interruption of single -machine hardware damage is avoided, and the efficient sharing and management of encrypted dogs is achieved, and the overall operation and maintenance efficiency is improved.
Smart Images

Figure CN119363441A_ABST
Abstract
Description
Technical Field
[0001] The invention relates to the field of software technology, and in particular to a dongle dynamic scheduling method based on USB network redirection and related equipment. Background Art
[0002] In the field of cloud rendering, installing a dongle in a node machine can effectively improve data security. In the prior art, the operation and maintenance of dongles is generally done by manual maintenance and management by operation and maintenance personnel. There are problems such as untimely real-time monitoring of dongle equipment damage, and damage to the hardware of a single machine causing the node machine to no longer be able to participate in the verification work, resulting in loss of efficiency. In addition, the one-to-one network mounting method requires coordination and cooperation. When one node machine is performing verification work, the other needs to wait for the node machine to be released. In short, serial processing is required. Therefore, a solution that can improve the efficiency of dongle management is urgently needed. Summary of the invention
[0003] In view of this, the purpose of the present invention is to provide a dongle dynamic scheduling method and related equipment based on USB network redirection to improve the current dongle management effect and efficiency.
[0004] To achieve the above objectives, the present invention adopts the following technical solutions:
[0005] In a first aspect, an embodiment of the present application provides a dongle dynamic scheduling method based on USB network redirection, comprising:
[0006] The encryption dongle is set on the node machine corresponding to the forwarding client through the USB port; wherein the encryption dongle on the node machine corresponding to the forwarding client can be shared with the node machine corresponding to the non-forwarding client under the management of the forwarding service end;
[0007] Obtain and parse the dongle information reported by the node machine corresponding to the forwarding client, and store the parsed information in the database;
[0008] Based on the information in the database, in response to the dongle use request sent by the node machine corresponding to the non-forwarding client, the node machine corresponding to the non-forwarding client shares the dongle on the node machine corresponding to the forwarding client through USB Over Network.
[0009] Further, in some embodiments of the present application, the process of the node machine corresponding to the forwarding client generating the dongle information includes:
[0010] When starting up, the local device is traversed to query all USB devices of preset types and obtain corresponding device information, wherein the device information includes the instance address, name, port, location and status of the device;
[0011] Based on the device information, a target list is generated, and the target list is used as the dongle information.
[0012] Further, in some embodiments of the present application, the process of the node machine corresponding to the forwarding client and the node machine corresponding to the non-forwarding client sharing the dongle thereon includes:
[0013] Sequentially assigning fixed TCP port numbers to the devices in the target list;
[0014] The target list is traversed, and the location and TCP port are specified through the USB Over Network software so that the corresponding USB port can be connected externally.
[0015] Furthermore, in some embodiments of the present application, the node machine corresponding to the forwarding client is also used to periodically monitor the plug-in and unplug-out changes of the USB port thereon through a preset thread, so as to share or cancel the sharing of the corresponding USB port in real time, and synchronously upload the change information to the forwarding server.
[0016] Further, in some embodiments of the present application, the process in which the node machine corresponding to the non-forwarding client uses the dongle in the node machine corresponding to the forwarding client includes:
[0017] When the dongle needs to be used, a dongle use request is sent to the forwarding server;
[0018] When the forwarding server returns the information of the dongle, the corresponding dongle is mounted by calling the USB Over Network software;
[0019] After the use of the dongle is completed, the USB Over Network software is called to uninstall the dongle, and a dongle uninstallation request is sent to the forwarding service end.
[0020] Further, in some embodiments of the present application, responding to the dongle use request sent by the node machine corresponding to the non-forwarding client based on the information in the database includes:
[0021] When receiving a dongle use request sent by the node machine corresponding to the non-forwarding client, querying the database for information of a dongle in an idle state, setting the state of the dongle to be busy, and returning the information of the dongle to the node machine of the non-forwarding client;
[0022] When receiving the dongle uninstallation request sent by the node machine corresponding to the non-forwarding client, the dongle state is set to idle in the database, and the result is returned to the node machine corresponding to the non-forwarding client.
[0023] In the second aspect, an embodiment of the present application provides a dongle dynamic scheduling system based on USB network redirection, including: a forwarding client and its corresponding node machine, a forwarding server and its corresponding node machine, a forwarding server and corresponding devices, used to execute the above-mentioned dynamic dongle scheduling method based on USB network redirection.
[0024] In a third aspect, an embodiment of the present application provides a dynamic dongle scheduling device based on USB network redirection, including a processor and a memory, wherein the processor is connected to the memory:
[0025] Wherein, the processor is used to call and execute the program stored in the memory;
[0026] The memory is used to store the program, and the program is at least used to execute the above-mentioned dynamic dongle scheduling method based on USB network redirection.
[0027] The present invention relates to the field of software technology, and in particular to a method and related equipment for dynamically scheduling an encryption dongle based on USB network redirection. The method comprises the following steps: setting the encryption dongle on a node machine corresponding to a forwarding client via a USB port; wherein the encryption dongle on the node machine corresponding to the forwarding client can be shared with a node machine corresponding to a non-forwarding client under the management of a forwarding service end; obtaining and parsing encryption dongle information reported by a node machine corresponding to the forwarding client, and storing the parsed information in a database; based on the information in the database, responding to an encryption dongle use request sent by a node machine corresponding to the non-forwarding client, enabling the node machine corresponding to the non-forwarding client to share the encryption dongle on the node machine corresponding to the forwarding client via USB Over Network, thereby improving the management effect of the encryption dongle, and improving the management efficiency by setting multiple node machines corresponding to the forwarding clients. BRIEF DESCRIPTION OF THE DRAWINGS
[0028] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0029] Figure 1 It is a flow chart of a method for dynamically scheduling a dongle based on USB network redirection provided by an embodiment of the present invention;
[0030] Figure 2 It is a structural diagram of a dynamic dongle scheduling device based on USB network redirection provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0031] To make the purpose, technical solution and advantages of the present invention clearer, the technical solution of the present invention will be described in detail below. Obviously, the described embodiments are only part of the embodiments of the present invention, rather than all the embodiments. Based on the embodiments of the present invention, all other implementation methods obtained by ordinary technicians in this field without creative work belong to the scope of protection of the present invention.
[0032] Figure 1 This is a flowchart of a method for dynamically scheduling a dongle based on USB network redirection provided by an embodiment of the present invention. Figure 1 , this embodiment may include the following steps:
[0033] S101, setting the encryption dongle on the node machine corresponding to the forwarding client through the USB port.
[0034] Among them, the encryption dongle on the node machine corresponding to the forwarding client can be shared with the node machine corresponding to the non-forwarding client under the management of the forwarding server.
[0035] S102, obtaining and parsing the dongle information reported by the node machine corresponding to the forwarding client, and storing the parsed information in a database.
[0036] S103, based on the information in the database, respond to the dongle use request sent by the node machine corresponding to the non-forwarding client, and enable the node machine corresponding to the non-forwarding client to share the dongle on the node machine corresponding to the forwarding client through USB Over Network.
[0037] The invention provides a method for dynamically scheduling an encryption dongle based on USB network redirection, which comprises the following steps: setting the encryption dongle on a node machine corresponding to a forwarding client via a USB port; wherein the encryption dongle on the node machine corresponding to the forwarding client can be shared with a node machine corresponding to a non-forwarding client under the management of a forwarding server; obtaining and parsing encryption dongle information reported by a node machine corresponding to the forwarding client, and storing the parsed information in a database; based on the information in the database, responding to an encryption dongle use request sent by a node machine corresponding to a non-forwarding client, enabling the node machine corresponding to the non-forwarding client to share the encryption dongle on the node machine corresponding to the forwarding client via USB Over Network, thereby improving the management effect of the encryption dongle, and improving the management efficiency by setting a plurality of node machines corresponding to forwarding clients.
[0038] In the embodiment of the present application, the forwarding client can be set on multiple node machines to perform the same operation, so as to improve the efficiency of using the dongle under the management of the forwarding server, wherein the operation of the node machine corresponding to each forwarding client specifically includes the following:
[0039] First, at startup, the local device is traversed to query all preset types of USB devices and obtain the corresponding device information, which includes the instance address, name, port, location and status of the device. Based on the device information, a target list is generated and the target list is used as the dongle information.
[0040] Specifically, in the present application, the USB forwarding client software, i.e. the forwarding client mentioned above, can be installed on a node machine, wherein the machine should have multiple USB ports and an external USB hub, i.e., the machine has the ability to insert N USB dongles, and there can be multiple such node machines.
[0041] After completing the above arrangement, the node machine of the forwarding client traverses the local device at startup and queries all preset type devices on it, such as all USB devices with human-machine interface device class 3-0-0 (Class-Subclass-Protocol), obtains the device's instance address, name, port, location (such as 1:1:1 / 3:1:4), status and other information and stores them in a target list such as list L, where the location information can be used as a unique identifier for the corresponding device (it should be noted that before or after generating the list, devices can be filtered, such as filtering out USB devices that are dongles).
[0042] Then the node machine of the forwarding client allocates a fixed TCP port number, such as 6000-7000, to each device in the L order of this list.
[0043] Then traverse this list L, use the USB Over Network software to specify the location and TCP port to share the corresponding USB port for external connection. After completion, this machine will listen to N TCP ports. At this time, the USB port that can be used for external connection (such as devices with dongles installed) can be used to share with external machines such as the node machine corresponding to the non-forwarding client.
[0044] At the same time, the node machine corresponding to the forwarding client also connects to the forwarding server through TCP, and reports this list information as the dongle information to the forwarding server for storage. The node machine corresponding to the forwarding client can also start a thread to regularly monitor the plug-in and unplug changes of the USB port of this machine, share or cancel the sharing of the USB port in real time, and synchronously report the change information to the forwarding server. Thus, the operation of the node machine corresponding to the forwarding client is completed.
[0045] On this basis, the process of the node machine corresponding to the non-forwarding client using the dongle in the node machine corresponding to the above-mentioned forwarding client includes: when the dongle needs to be used, sending a dongle use request to the forwarding server; when the forwarding server returns the dongle information, mounting the corresponding dongle by calling the USB Over Network software; and after the use of the dongle is completed, calling the USB Over Network software to uninstall the dongle, and sending a dongle uninstall request to the forwarding server.
[0046] Specifically, there are also multiple node machines corresponding to the non-forwarding client, which are the authorization verification working end. When it needs to use the dongle, that is, it needs to verify the dongle, it first sends a dongle use request to the forwarding server to request an idle dongle (this step may require a loop request to wait for allocation); when there is an idle dongle information returned, call the USB Over Network software to mount this remote dongle; and after use, call the USB Over Network software to uninstall this remote dongle, and send a request to the forwarding server.
[0047] Correspondingly, on the forwarding server side, it can respond to the dongle usage request sent by the node machine corresponding to the non-forwarding client based on the information in the database, including: when receiving the dongle usage request sent by the node machine corresponding to the non-forwarding client, querying the dongle information with an idle status from the corresponding database, setting the status of this dongle to busy, and returning the dongle information to the node machine of the non-forwarding client; when receiving the dongle uninstallation request sent by the node machine corresponding to the non-forwarding client, setting the dongle status to idle in the database, and returning the result to the node machine corresponding to the non-forwarding client.
[0048] Specifically, the forwarding server can be set up in only one place. In actual applications, the forwarding server is started and listens to the specified TCP port P1 (used for the forwarding client to report the dongle status) and the specified TCP port P2 (used by the non-forwarding client to request an idle dongle); the client (i.e., the forwarding client and the non-forwarding client) is connected in a loop, the reported information is parsed, and stored in the database. At this time, the database contains the information of the dongle to be scheduled. When the mount request of the non-forwarding client arrives, the information of an idle dongle is queried from the database, and the status of this dongle is set to busy, and the result is returned to the non-forwarding client; when the uninstall request of the non-forwarding client arrives, the status of this dongle in the database is idle, and the result is returned to the non-forwarding client.
[0049] Based on the same inventive concept, the present application also provides a dongle dynamic scheduling system based on USB network redirection, including: a forwarding client and its corresponding node machine, a forwarding server and its corresponding node machine, a forwarding server and corresponding devices, used to execute the dynamic dongle scheduling method based on USB network redirection in the above method embodiment.
[0050] Regarding the system in the above embodiment, the specific manner in which each part performs operations has been described in detail in the embodiment of the method, and will not be elaborated here.
[0051] The present invention also provides a dynamic dongle scheduling device based on USB network redirection, which is used to implement the above method embodiment. Figure 2 Schematic diagram of the structure of the USB network redirection dynamic dongle scheduling device provided by the embodiment of the present invention. Figure 2 As shown, the USB network redirection-based dynamic dongle scheduling device of this embodiment includes a processor 21 and a memory 22, and the processor 21 is connected to the memory 22. The processor 21 is used to call and execute the program stored in the memory 22; the memory 22 is used to store the program, and the program is at least used to execute the USB network redirection-based dynamic dongle scheduling method in the above embodiment.
[0052] The specific implementation scheme of the dynamic dongle scheduling device based on USB network redirection provided in the embodiment of the present application can refer to the implementation scheme of the dynamic dongle scheduling method based on USB network redirection in any of the above embodiments, which will not be repeated here.
[0053] It can be understood that the same or similar parts of the above embodiments can be referenced to each other, and the contents not described in detail in some embodiments can refer to the same or similar contents in other embodiments.
[0054] It should be noted that, in the description of the present invention, the terms "first", "second", etc. are only used for descriptive purposes and cannot be understood as indicating or implying relative importance. In addition, in the description of the present invention, unless otherwise specified, the meaning of "plurality" refers to at least two.
[0055] Any process or method description in a flowchart or otherwise described herein may be understood to represent a module, segment or portion of code that includes one or more executable instructions for implementing the steps of a specific logical function or process, and the scope of the preferred embodiments of the present invention includes alternative implementations in which functions may not be performed in the order shown or discussed, including performing functions in a substantially simultaneous manner or in the reverse order depending on the functions involved, which should be understood by those skilled in the art to which the embodiments of the present invention belong.
[0056] It should be understood that the various parts of the present invention can be implemented by hardware, software, firmware or a combination thereof. In the above-mentioned embodiments, a plurality of steps or methods can be implemented by software or firmware stored in a memory and executed by a suitable instruction execution system. For example, if implemented by hardware, as in another embodiment, it can be implemented by any one of the following technologies known in the art or their combination: a discrete logic circuit having a logic gate circuit for implementing a logic function for a data signal, a dedicated integrated circuit having a suitable combination of logic gate circuits, a programmable gate array (PGA), a field programmable gate array (FPGA), etc.
[0057] A person skilled in the art may understand that all or part of the steps in the method for implementing the above-mentioned embodiment may be completed by instructing related hardware through a program, and the program may be stored in a computer-readable storage medium, which, when executed, includes one or a combination of the steps of the method embodiment.
[0058] In addition, each functional unit in each embodiment of the present invention may be integrated into a processing module, or each unit may exist physically separately, or two or more units may be integrated into one module. The above-mentioned integrated module may be implemented in the form of hardware or in the form of a software functional module. If the integrated module is implemented in the form of a software functional module and sold or used as an independent product, it may also be stored in a computer-readable storage medium.
[0059] The storage medium mentioned above can be a read-only memory, a magnetic disk or an optical disk, etc.
[0060] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "examples", "specific examples", or "some examples" means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present invention. In this specification, the schematic representation of the above terms does not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described may be combined in any one or more embodiments or examples in a suitable manner.
[0061] Although the embodiments of the present invention have been shown and described above, it is to be understood that the above embodiments are exemplary and are not to be construed as limitations of the present invention. A person skilled in the art may change, modify, replace and vary the above embodiments within the scope of the present invention.
Claims
1. A dongle dynamic scheduling method based on USB network redirection, characterized in that: include: The encryption dongle is set on the node machine corresponding to the forwarding client through the USB port; wherein the encryption dongle on the node machine corresponding to the forwarding client can be shared with the node machine corresponding to the non-forwarding client under the management of the forwarding service end; Obtain and parse the dongle information reported by the node machine corresponding to the forwarding client, and store the parsed information in the database; Based on the information in the database, in response to the dongle use request sent by the node machine corresponding to the non-forwarding client, the node machine corresponding to the non-forwarding client shares the dongle on the node machine corresponding to the forwarding client through USB Over Network.
2. The method for dynamic scheduling of dongles based on USB network redirection according to claim 1, characterized in that: The process of the node machine corresponding to the forwarding client generating the dongle information includes: When starting up, the local device is traversed to query all USB devices of preset types and obtain corresponding device information, wherein the device information includes the instance address, name, port, location and status of the device; Based on the device information, a target list is generated, and the target list is used as the dongle information.
3. The method for dynamic scheduling of dongles based on USB network redirection according to claim 2, characterized in that: The process of the node machine corresponding to the forwarding client and the node machine corresponding to the non-forwarding client sharing the encryption dongle thereon comprises: Sequentially assigning fixed TCP port numbers to the devices in the target list; The target list is traversed, and the location and TCP port are specified through the USB Over Network software so that the corresponding USB port can be connected externally.
4. The method for dynamic scheduling of dongles based on USB network redirection according to claim 2, characterized in that: The node machine corresponding to the forwarding client is also used to monitor the plug-in and unplug changes of the USB port thereon at regular intervals through a preset thread, so as to share or cancel the sharing of the corresponding USB port in real time, and synchronously upload the change information to the forwarding server.
5. The method for dynamic scheduling of dongles based on USB network redirection according to claim 2, characterized in that: The process of the node machine corresponding to the non-forwarding client using the dongle in the node machine corresponding to the forwarding client includes: When the dongle needs to be used, a dongle use request is sent to the forwarding server; When the forwarding server returns the information of the dongle, the corresponding dongle is mounted by calling the USB Over Network software; After the use of the dongle is completed, the USB Over Network software is called to uninstall the dongle, and a dongle uninstallation request is sent to the forwarding service end.
6. The method for dynamic scheduling of dongles based on USB network redirection according to claim 5, characterized in that: The method of responding to the dongle use request sent by the node machine corresponding to the non-forwarding client based on the information in the database includes: When receiving a dongle use request sent by the node machine corresponding to the non-forwarding client, querying the database for information of a dongle in an idle state, setting the state of the dongle to be busy, and returning the information of the dongle to the node machine of the non-forwarding client; When receiving the dongle uninstallation request sent by the node machine corresponding to the non-forwarding client, the dongle state is set to idle in the database, and the result is returned to the node machine corresponding to the non-forwarding client.
7. A dongle dynamic scheduling system based on USB network redirection, characterized in that: include: The forwarding client and its corresponding node machine, the forwarding server and its corresponding node machine, the forwarding server and the corresponding device are used to execute the dynamic dongle scheduling method based on USB network redirection as described in any one of claims 1-6.
8. A dynamic dongle scheduling device based on USB network redirection, characterized in that: The invention comprises a processor and a memory, wherein the processor is connected to the memory: Wherein, the processor is used to call and execute the program stored in the memory; The memory is used to store the program, and the program is at least used to execute the dynamic dongle scheduling method based on USB network redirection as described in any one of claims 1-6.