CN112217873A - Device sharing method, related device and storage medium - Google Patents
Device sharing method, related device and storage medium Download PDFInfo
- Publication number
- CN112217873A CN112217873A CN202010976223.7A CN202010976223A CN112217873A CN 112217873 A CN112217873 A CN 112217873A CN 202010976223 A CN202010976223 A CN 202010976223A CN 112217873 A CN112217873 A CN 112217873A
- Authority
- CN
- China
- Prior art keywords
- proxy
- host
- equipment
- list
- proxy host
- 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.)
- Granted
Links
- 238000000034 method Methods 0.000 title claims abstract description 82
- 238000004891 communication Methods 0.000 claims description 34
- 238000004590 computer program Methods 0.000 claims description 33
- 238000012545 processing Methods 0.000 claims description 7
- 238000013475 authorization Methods 0.000 claims description 6
- 230000000977 initiatory effect Effects 0.000 claims description 3
- 238000012423 maintenance Methods 0.000 abstract description 8
- 238000010586 diagram Methods 0.000 description 16
- 230000008569 process Effects 0.000 description 13
- 238000005516 engineering process Methods 0.000 description 8
- 230000005540 biological transmission Effects 0.000 description 7
- 239000003795 chemical substances by application Substances 0.000 description 5
- 230000006870 function Effects 0.000 description 5
- 230000003287 optical effect Effects 0.000 description 5
- 230000005236 sound signal Effects 0.000 description 4
- 230000003068 static effect Effects 0.000 description 4
- 230000002159 abnormal effect Effects 0.000 description 3
- 230000000694 effects Effects 0.000 description 3
- 239000003245 coal Substances 0.000 description 2
- 230000005611 electricity Effects 0.000 description 2
- 230000004048 modification Effects 0.000 description 2
- 238000012986 modification Methods 0.000 description 2
- XLYOFNOQVPJJNP-UHFFFAOYSA-N water Substances O XLYOFNOQVPJJNP-UHFFFAOYSA-N 0.000 description 2
- 230000009471 action Effects 0.000 description 1
- 230000000712 assembly Effects 0.000 description 1
- 238000000429 assembly Methods 0.000 description 1
- 230000008859 change Effects 0.000 description 1
- 230000004069 differentiation Effects 0.000 description 1
- 230000006872 improvement Effects 0.000 description 1
- 230000003993 interaction Effects 0.000 description 1
- 239000004973 liquid crystal related substance Substances 0.000 description 1
- 238000004519 manufacturing process Methods 0.000 description 1
- 238000010295 mobile communication Methods 0.000 description 1
- 238000012163 sequencing technique Methods 0.000 description 1
Images
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/50—Network services
- H04L67/56—Provisioning of proxy services
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L43/00—Arrangements for monitoring or testing data switching networks
- H04L43/08—Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters
- H04L43/0805—Monitoring or testing based on specific metrics, e.g. QoS, energy consumption or environmental parameters by checking availability
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L63/00—Network architectures or network communication protocols for network security
- H04L63/08—Network architectures or network communication protocols for network security for authentication of entities
- H04L63/0876—Network architectures or network communication protocols for network security for authentication of entities based on the identity of the terminal or configuration, e.g. MAC address, hardware or software configuration or device fingerprint
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/01—Protocols
- H04L67/133—Protocols for remote procedure calls [RPC]
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Power Engineering (AREA)
- Computer Hardware Design (AREA)
- Computer Security & Cryptography (AREA)
- Computing Systems (AREA)
- General Engineering & Computer Science (AREA)
- Environmental & Geological Engineering (AREA)
- Computer And Data Communications (AREA)
- Telephonic Communication Services (AREA)
Abstract
The embodiment of the application provides a device sharing method, related devices and a storage medium, wherein a terminal device obtains an accessible proxy host list from a service platform, the terminal device initiates a call to a sharing device through a proxy host in the proxy host list, and receives collected data returned by the sharing device and returned by the proxy host in the proxy host list, so as to realize device sharing. Therefore, the proxy host is adopted to replace the terminal equipment to initiate the calling of the sharing equipment, so that one sharing equipment can be called by a plurality of terminal equipment, and the equipment utilization rate is improved. In addition, external equipment for acquiring different information is not required to be configured for each terminal device, and equipment purchase cost and maintenance cost are reduced.
Description
Technical Field
The present application relates to the field of internet technologies, and in particular, to a device sharing method, a related device, and a storage medium.
Background
At present, in order to realize automatic business handling, terminal equipment for handling business often needs external equipment to collect various data information. The external devices are, for example, pos (point Of sale) machines, certificate information acquisition devices, handwriting screen devices, scanner devices, high-speed camera devices, and the like. When the number of terminal devices handling the service increases, the number of corresponding external devices also increases. However, each external device can only be used by the terminal device to which the external device belongs, and the device utilization rate of the external device is low.
Disclosure of Invention
Aspects of the present disclosure provide a device sharing method, related device and storage medium, so as to improve a device usage rate.
The embodiment of the application provides a device sharing method, which comprises the following steps:
the method comprises the steps that terminal equipment obtains an accessible proxy host list from a service platform, wherein the proxy host list stores proxy hosts accessible by the terminal equipment, and the proxy hosts are connected with shared equipment of equipment types required by the terminal equipment;
the terminal equipment initiates the call of the sharing equipment through the proxy host in the proxy host list;
and the terminal equipment receives the collected data returned by the sharing equipment and returned by the proxy in the proxy list so as to realize equipment sharing.
An embodiment of the present application further provides an apparatus sharing method, including:
the target proxy host responds to a device calling request sent by the terminal device, wherein the device calling request comprises a device type required by the terminal device;
the target proxy host identifies the state of the sharing equipment under the equipment type connected with the target proxy host;
if the shared device is in an available state, the target proxy host judges whether the target proxy host has the authority to be used as the intermediate device of the terminal device to call the shared device;
if yes, the target proxy host acquires the acquired data of the shared device and returns the acquired data to the terminal device.
An embodiment of the present application further provides an apparatus sharing method, including:
the method comprises the steps that a service platform receives a list obtaining request sent by terminal equipment, wherein the list obtaining request comprises an equipment type required by the terminal equipment;
according to the list acquisition request, acquiring a proxy host connected with shared equipment belonging to the equipment type and generating a proxy host list;
the service platform returns the proxy host list to the terminal equipment so that the terminal equipment initiates calling of the sharing equipment through a target proxy host in the proxy host list, wherein the target proxy host is a proxy host in the proxy list;
the service platform receives a device authentication request sent by a target proxy host, and calls the sharing device to authenticate whether the target proxy host has the authority as the intermediate device of the terminal device;
and the service platform returns an authentication passing message to the target proxy host, so that the target proxy host is used as the intermediate equipment of the terminal equipment to acquire the acquired data of the sharing equipment and return the acquired data to the terminal equipment.
An embodiment of the present application further provides a terminal device, including: a memory, a processor, and a communications component;
the memory for storing a computer program;
the processor, coupled with the memory, to execute the computer program to:
acquiring a proxy host list accessible by the terminal equipment from a service platform, wherein the proxy host list stores proxy hosts accessible by the terminal equipment, and the proxy hosts are connected with shared equipment of the equipment type required by the terminal equipment;
initiating, by a proxy in the proxy list, a call to the shared device;
and receiving collected data returned by the sharing equipment and returned by the proxy in the proxy list through the communication component so as to realize equipment sharing.
An embodiment of the present application further provides a proxy, which can be implemented as a target proxy, including: a memory, a processor, and a communications component;
the memory for storing a computer program;
the processor, coupled with the memory, to execute the computer program to:
responding to a device calling request sent by the terminal device through the communication component, wherein the device calling request comprises a device type required by the terminal device;
identifying the state of the shared device under the device type connected with the shared device;
if the shared device is in an available state, the target proxy host judges whether the target proxy host has the authority to be used as the intermediate device of the terminal device to call the shared device;
if yes, the target proxy host acquires the acquired data of the shared device and returns the acquired data to the terminal device.
An embodiment of the present application further provides a service platform, including: a memory, a processor, and a communications component;
the memory for storing a computer program;
the processor, coupled with the memory, to execute the computer program to:
receiving a list acquisition request sent by terminal equipment through a communication component, wherein the list acquisition request comprises an equipment type required by the terminal equipment;
according to the list acquisition request, acquiring a proxy host connected with shared equipment belonging to the equipment type and generating a proxy host list;
returning the proxy host list to the terminal equipment to enable the terminal equipment to initiate the call of the sharing equipment through a target proxy host in the proxy host list, wherein the target proxy host is a proxy host in the proxy list;
receiving a device authentication request sent by a target proxy host through a communication component, and calling the sharing device for authentication if the target proxy host has the authority as an intermediate device of the terminal device;
and returning an authentication passing message to the target proxy host so that the target proxy host is used as the intermediate equipment of the terminal equipment to acquire the acquired data of the sharing equipment and return the acquired data to the terminal equipment.
Embodiments of the present application further provide a computer-readable storage medium storing a computer program, which, when executed by a processor, causes the processor to implement the steps in the device sharing method.
The embodiment of the application provides a device sharing method, related devices and a storage medium, wherein a terminal device obtains an accessible proxy host list from a service platform, the terminal device initiates a call to a sharing device through a proxy host in the proxy host list, and receives collected data returned by the sharing device and returned by the proxy host in the proxy host list, so as to realize device sharing. Therefore, the proxy host is adopted to replace the terminal equipment to initiate the calling of the sharing equipment, so that one sharing equipment can be called by a plurality of terminal equipment, and the equipment utilization rate is improved. In addition, external equipment for acquiring different information is not required to be configured for each terminal device, and equipment purchase cost and maintenance cost are reduced.
Drawings
The accompanying drawings, which are included to provide a further understanding of the application and are incorporated in and constitute a part of this application, illustrate embodiment(s) of the application and together with the description serve to explain the application and not to limit the application. In the drawings:
fig. 1 is a schematic structural diagram of a device sharing system according to an exemplary embodiment of the present application;
fig. 2 is a flowchart illustrating a device sharing method according to an exemplary embodiment of the present application;
fig. 3 is a schematic flowchart of another device sharing method according to an exemplary embodiment of the present application;
fig. 4 is a flowchart illustrating a further device sharing method according to an exemplary embodiment of the present application;
fig. 5 is a schematic structural diagram of a terminal device according to an exemplary embodiment of the present application;
fig. 6 is a schematic structural diagram of a proxy according to an exemplary embodiment of the present application;
fig. 7 is a schematic structural diagram of a service platform according to an exemplary embodiment of the present application.
Detailed Description
In order to make the objects, technical solutions and advantages of the present application more apparent, the technical solutions of the present application will be described in detail and completely with reference to the following specific embodiments of the present application and the accompanying drawings. It should be apparent that the described embodiments are only some of the embodiments of the present application, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
In some embodiments of the present application, a terminal device obtains an accessible proxy host list from a service platform, and the terminal device initiates a call to a sharing device through a proxy host in the proxy host list and receives collected data returned by the sharing device and returned by the proxy host in the proxy host list, so as to implement device sharing. Therefore, the proxy host is adopted to replace the terminal equipment to initiate the calling of the sharing equipment, so that one sharing equipment can be called by a plurality of terminal equipment, and the equipment utilization rate is improved. In addition, external equipment for acquiring different information is not required to be configured for each terminal device, and equipment purchase cost and maintenance cost are reduced.
The technical solutions provided by the embodiments of the present application are described in detail below with reference to the accompanying drawings.
Fig. 1 is a schematic structural diagram of a device sharing system according to an exemplary embodiment of the present application. As shown in fig. 1, the system includes: the service platform 6, at least one terminal device 5, at least one proxy 4, and at least one sharing device connected to each proxy, wherein each terminal device and each proxy can be in communication connection with the service platform, each terminal device can be in communication connection with each proxy, and each proxy can be in communication connection with the device connected thereto. It is to be noted that fig. 1 shows only the handwriting screen device 1, the camera device 2, the POS machine 3, and the like, but the sharing device is not limited to the sharing device shown in fig. 1.
In this embodiment, the service platform is responsible for managing and maintaining a proxy list accessible by each terminal device, and authenticating whether the proxy has the right to be used as an intermediate device of the terminal device to call the shared device, although the function of the service platform is not limited thereto. Wherein the proxy in the proxy list can be accessed by the terminal device. In different access processes, the terminal device may need to access different types of shared devices, so the proxy hosts in the proxy host list corresponding to the terminal device may be different.
In this embodiment, each terminal device is a device capable of providing a certain service to a user. The device types may differ for different services. For example, the terminal device may be a banking terminal capable of providing banking services to a user, such as a self-service teller machine, a self-service cash dispenser, or the like. As another example, the terminal device may be a terminal device capable of providing business hall telecommunication services to the user, such as a self-service business hall terminal. For another example, the terminal device may be a terminal device capable of providing a water, electricity and coal payment service for a user, such as a self-service payment machine, but is not limited thereto.
In this embodiment, the proxy can initiate a call to the sharing device as an intermediate device of the terminal device instead of the terminal device. Each proxy is connected to a terminal device and a shared device that can be used by a plurality of terminal devices. The device types of these shared devices include, but are not limited to: POS machines, credential information collection devices, handwriting screen devices, scanner devices, high-speed camera devices, printers, facsimile machines, and the like, but are not limited thereto. In different application scenarios, the device types and forms of the shared device and the terminal device connected to the proxy host are different. For example, in a banking scenario, the terminal device is an automatic teller machine, and accordingly, the sharing device is a printer, a camera device. For another example, in a company office scenario, the terminal devices are notebook computers, desktop computers, etc. used by employees of the company, and correspondingly, the sharing devices are printers, fax machines of the company; for another example, in a business hall scenario, the terminal device is a self-service business hall terminal, and accordingly, the sharing device is a certificate information collecting device, a handwriting screen device, a scanner device, a high-speed camera device, and a camera device of the business hall. For another example, in a water, electricity and coal payment scene, the terminal device is a self-service payment machine, and correspondingly, the sharing device is: POS machine, printer, camera, handwriting screen equipment, card reading equipment.
It should be noted that the sharing device may be a network connection device connected to the proxy host through a network, and the network connection device may be, for example, a POS machine, a certificate information collecting device, a handwriting screen device, a scanner device, a high-speed shooting device, a camera device, a printer, or a facsimile machine. The sharing device can also be a USB device connected to the proxy host, and the USB device is a handwriting screen device or a card reading device.
In this embodiment, the server platform maintains the binding relationship between each proxy and the connected sharing device, and the host information of each proxy and the device information of the connected sharing device. Based on this, when a certain terminal device needs to call a shared device of a certain device type, the terminal device may obtain a proxy list accessible by the terminal device from the service platform, and the service platform may provide the proxy list accessible by the terminal device to the terminal device. Then, the terminal equipment initiates the call of the sharing equipment through the proxy host in the proxy host list; the agent host in the agent host list can determine the sharing device under the device type required by the terminal device, and acquire the acquired data of the sharing device and return the acquired data to the terminal device, so that the terminal device can execute corresponding service operation by using the acquired data of the sharing device, thereby realizing the sharing of the sharing device. When the proxy host calls the sharing equipment, the proxy host and the service platform perform data interaction to identify whether the proxy host has the authority to replace the terminal equipment to initiate the call of the sharing equipment, and if the proxy host has the authority, the proxy host acquires the acquired data of the sharing equipment and returns the acquired data to the terminal equipment.
Taking a business hall scene as an example, a plurality of self-service business hall terminals are arranged in a business hall. Some self-service business office terminals have connected certificate information acquisition equipment, handwriting screen equipment, scanner equipment, high appearance equipment of shooing, camera equipment, and some self-service business office terminals have connected equipment such as high appearance equipment of shooing, camera equipment. Each self-service business hall terminal can be used as an agent host of other self-service business hall terminals. When a certain self-service business hall terminal is not connected with certificate information acquisition equipment or camera equipment, and needs the acquisition data of the certificate information acquisition equipment or the camera equipment in the business process, the self-service business hall terminal connected with the certificate information acquisition equipment or the camera equipment can be sent with an equipment calling request, and the certificate information acquisition equipment or the camera equipment connected with other self-service business hall terminals can acquire corresponding acquisition data. Obviously, the proxy host is arranged, the sharing of the equipment can be realized, and the self-service business hall terminal which is not connected with a certain sharing equipment can acquire the collected data of the certain sharing equipment through the self-service business hall terminal which is connected with the certain sharing equipment, so that the equipment utilization rate of the sharing equipment is improved, and the equipment purchase cost and the maintenance cost are also reduced.
It can be understood that, in this embodiment, a proxy host is added between the sharing device and the terminal device, and the proxy host replaces the terminal device to initiate the call to the sharing device, so that one sharing device can be called by multiple terminal devices, thereby improving the device usage rate. In addition, external equipment for acquiring different information is not required to be configured for each terminal device, and equipment purchase cost and maintenance cost are reduced.
For the working principle of the system, reference may be made to the following detailed description of the method embodiments.
Fig. 2 is a flowchart illustrating a device sharing method according to an exemplary embodiment of the present application. As shown in fig. 2, the device sharing method includes the following steps:
201. the terminal equipment obtains an accessible proxy host list from the service platform, the proxy host list stores the proxy hosts accessible by the terminal equipment, and the proxy hosts are connected with the shared equipment of the equipment type required by the terminal equipment.
202. The terminal device initiates a call to the sharing device through the proxy in the proxy list.
203. And the terminal equipment receives the collected data returned by the sharing equipment and returned by the proxy in the proxy list so as to realize equipment sharing.
In this embodiment, before calling the sharing device through one proxy, the terminal device needs to obtain a list of accessible proxies. The proxy hosts stored in the proxy host list are proxy hosts which can be accessed by the terminal equipment, the accessible proxy hosts are connected with sharing equipment of the equipment type required by the terminal equipment, and the terminal equipment can call the sharing equipment through the accessible proxy hosts to acquire the collected data of the sharing equipment.
In this embodiment, the manner in which the terminal device obtains the proxy list accessible to the terminal device from the service platform is not limited. For example, the service platform may periodically issue the latest proxy list accessible to the terminal device. For another example, the terminal device actively requests the service platform to obtain the proxy list. Specifically, the terminal device sends a list acquisition request to the service platform, wherein the list acquisition request includes a device type required by the terminal device, so that the service platform acquires a proxy host connected with shared devices belonging to the device type and generates a proxy host list; and receiving the proxy host list returned by the service platform. For example, if the terminal device needs image data captured by the camera device, each proxy in the proxy list returned by the service platform is connected with the camera device. And if the terminal equipment needs the certificate information acquired by the certificate information acquisition equipment, all the proxy hosts in the proxy host list returned by the service platform are connected with the certificate information acquisition equipment. If the terminal device needs the scanning information scanned by the scanner device, each proxy in the proxy list returned by the service platform is connected with the scanner device.
After the proxy host list is obtained, the terminal device can send a device call request to the proxy hosts in the proxy host list, and acquisition of the acquisition information of the sharing device through the proxy hosts is achieved.
In this embodiment, the terminal device may sequentially initiate a device call request to the proxy hosts in the proxy host list, or may select one proxy host from the proxy host list to initiate a device call request, and of course, the manner in which the terminal device initiates a call to the shared device through the proxy hosts in the proxy host list is not limited to this.
In an optional embodiment, in order to find out the proxy that can successfully invoke the sharing device as quickly as possible, the service platform may set a priority for the proxy in the proxy list during the process of generating the proxy list for the terminal device, so that the terminal device may initiate a device invocation request to the proxy in the proxy list according to the priority of the proxy, so that the proxy initiates invocation to the sharing device. The priority of the proxy can be determined by the service platform according to the relevant influencing factors, and for the relevant content of determining the priority of the proxy, reference may be made to the description in the embodiment shown in fig. 4, which will not be detailed here for the moment. In this embodiment, the higher the priority of the proxy is, the higher the possibility that the terminal device successfully calls the shared device through the proxy is; conversely, the lower the priority of the proxy is, the lower the possibility that the terminal device successfully calls the sharing device through the proxy is.
In this embodiment, when the proxies in the proxy list are arranged in order of priority from high to low, the terminal device may invoke the sharing device in the following manner, and of course, is not limited to the following manner.
As an example, the terminal device sequentially sends device invocation requests to the proxy hosts in the proxy host list according to the order of the priorities from high to low, so that the proxy hosts invoke the sharing devices under the device types connected with the proxy hosts until the target proxy hosts successfully invoke the sharing devices appear. The target proxy is one of the proxies in the proxy list.
For example, 10 proxies A1-A10 in the proxy list, the 10 proxies are ranked in order of priority from high to low. The terminal equipment sends an equipment calling request to the first-ranked proxy host, and if the collected data of the shared equipment is successfully called, the first-ranked proxy host is a target proxy host. And if the collected data of the shared equipment is not called, sequentially sending equipment calling requests to the proxy host ordered at the next position until the collected data of the shared equipment is successfully called. When the proxy A8 successfully calls the collected data to the shared device, A8 is the target proxy.
As another example, the terminal device selects a target proxy from the proxy list according to the priority between the proxies; and sending a device calling request to the target proxy host for the target proxy host to call the sharing device under the device type connected with the target proxy host.
Following the above example, the 10 proxies in the proxy list are ranked in order of priority from high to low. The terminal device may select one proxy host with a higher priority as a target proxy host to invoke the sharing device, and if the collected data of the sharing device is not invoked, continue to select another proxy host with a higher priority as a target proxy host to invoke the sharing device until the collected data of the sharing device is successfully invoked. Specifically, when a higher-priority proxy is selected, a proxy having the highest priority may be selected as a target proxy from among the proxies that have not been selected. One of the first N proxies with the highest priority may also be selected as the target proxy for the unselected proxies, where N is a natural number greater than or equal to 2.
In this embodiment, when the proxy in the proxy list successfully calls the shared device of the device type required by the terminal device, the acquired data of the shared device is returned to the terminal device, so that the terminal device can acquire the acquired data of the shared device through the proxy.
In practical applications, the collected data of the sharing device may relate to privacy information of the user, for example, face data captured by a camera device, user credential information collected by a credential information collecting device, and the like.
In an optional embodiment, in order to ensure the security and availability of data transmission, the collected data of the sharing device may be transmitted between the proxy host and the terminal device by using a data encryption transmission method.
As an example, the acquiring data is a data ciphertext encrypted by the target proxy, and after the terminal device receives the acquiring data, the method further includes: sending a key acquisition request to a service platform, wherein the key acquisition request comprises identification information of a target proxy host; receiving a decryption key which is returned by the service platform and corresponds to the encryption key used by the target proxy host in the encryption mode; and decrypting the data ciphertext by using the decryption key to obtain the data plaintext.
Specifically, after the target proxy successfully invokes the collected data to the sharing device, the target proxy may request an encryption key from the service platform, and the service platform may simultaneously generate a decryption key corresponding to the encryption key for the target proxy. And after the target proxy host acquires the encryption key generated by the service platform, encrypting the acquired data of the sharing equipment by using the encryption key to obtain an encrypted data ciphertext. After receiving the data ciphertext sent by the target proxy host, the terminal equipment sends a key acquisition request carrying identification information of the target proxy host to the service platform; after receiving a key acquisition request initiated by the terminal equipment, the service platform acquires a decryption key corresponding to an encryption key used by the target proxy host in an encryption manner according to the identification information of the target proxy host and returns the decryption key to the terminal equipment; and the terminal equipment receives the decryption key returned by the service platform, and decrypts the data ciphertext generated by the target proxy host by using the decryption key to obtain the data plaintext.
According to the device sharing method provided by the embodiment of the application, the terminal device obtains the accessible proxy host list from the service platform, the terminal device initiates the call of the sharing device through the proxy host in the proxy host list, and receives the collected data returned by the sharing device and returned by the proxy host in the proxy host list, so that the device sharing is realized. Therefore, the proxy host is adopted to replace the terminal equipment to initiate the calling of the sharing equipment, so that one sharing equipment can be called by a plurality of terminal equipment, and the equipment utilization rate is improved. In addition, external equipment for acquiring different information is not required to be configured for each terminal device, and equipment purchase cost and maintenance cost are reduced.
Fig. 3 is a flowchart illustrating a device sharing method according to an exemplary embodiment of the present application. The execution subject of the method is a target proxy. In this embodiment, only the target proxy is taken as an example for explanation, and the working principle of other proxies in the proxy list accessible to the terminal device is the same as that of the target proxy, which is not described herein again.
As shown in fig. 3, the device sharing method includes the steps of:
301. and the target proxy host responds to a device calling request sent by the terminal device, wherein the device calling request comprises the device type required by the terminal device.
302. The target proxy identifies the state of the shared device under the device type to which it is connected.
303. If the sharing device is in the available state, the target proxy determines whether the target proxy has the authority to call the sharing device as the intermediate device of the terminal device, and if so, step 304 is executed.
304. And the target proxy host acquires the acquired data of the sharing equipment and returns the acquired data to the terminal equipment.
In this embodiment, the target proxy is any proxy in the list of accessible proxies acquired by the terminal device from the service platform. When the terminal device needs to call the shared device of a certain device type, the terminal device sends a device call request including the device type needed by the terminal device to the target proxy host, and then the target proxy host responds to the device call request sent by the terminal device.
In practical applications, various abnormal situations such as incapability of connecting with the proxy host and power failure may occur to the sharing device, at this time, the sharing device is in an unavailable state, and the proxy host cannot acquire the data acquired by the sharing device from the unavailable state. Therefore, in order to enable the target proxy host to successfully call the shared device under the device type required by the terminal device, before the target proxy host calls the shared device, the state of the shared device under the device type required by the terminal device connected with the target proxy host is identified, and the target proxy host initiates a call operation on the shared device only when the shared device is in an available state; otherwise, if the shared device is in the unavailable state, the target proxy host abandons the calling operation of the shared device.
It should be noted that, if there are multiple sharing devices of the same device type connected to the current target proxy, one sharing device in an available state may be selected from the multiple sharing devices, and the target proxy calls the selected sharing device in the available state. If none of the sharing devices connected to the current target proxy host is in the available state, the terminal device may reselect a new target proxy host from the host list and send a device call request to the new target proxy host.
In practical applications, the shared device connected to the proxy host may have support to be called by the terminal device, and may have support to be called by the terminal device. For example, the service platform determines a proxy that is accessible by the terminal device according to the device type required by the terminal device, but the shared device connected to the proxy is not registered in the service platform (the shared device registered in the service platform allows the terminal device to be called by the proxy), and at this time, the proxy does not have the authority to call the shared device as an intermediate device of the terminal device.
Therefore, in order to ensure the success rate of calling the shared device and avoid the pressure on the system caused by frequent calling as much as possible, the target proxy host needs to identify whether the target proxy host has the authority to call the shared device instead of the terminal device before calling the shared device.
In this embodiment, after the target proxy host successfully calls the shared device, the collected data of the shared device is returned to the terminal device, so that the terminal device can obtain the collected data of the shared device through the target proxy host.
According to the device sharing method provided by the embodiment of the application, the terminal device obtains the accessible proxy host list from the service platform, the terminal device initiates the call of the sharing device through the proxy host in the proxy host list, and receives the collected data returned by the sharing device and returned by the proxy host in the proxy host list, so that the device sharing is realized. Therefore, the proxy host is adopted to replace the terminal equipment to initiate the call of the sharing equipment, so that one sharing equipment can be called by a plurality of terminal equipment, and the equipment utilization rate is provided. In addition, external equipment for acquiring different information is not required to be configured for each terminal device, and equipment purchase cost and maintenance cost are reduced.
In practical applications, the collected data of the sharing device may relate to privacy information of the user, for example, face data captured by a camera device, user credential information collected by a credential information collecting device, and the like. Therefore, in order to ensure the security and the availability of data transmission, the collected data of the sharing device can be transmitted between the target proxy host and the terminal device by adopting a data encryption transmission method.
As an example, before the target proxy returns the acquired data of the shared device to the terminal device, a key acquisition request including identification information of the target proxy may be sent to the service platform, so that the service platform generates an encryption key corresponding to the target proxy; receiving an encryption key returned by the service platform; and encrypting the acquired data by using the encryption key to obtain a data ciphertext.
Specifically, after the target proxy successfully invokes the collected data to the sharing device, the target proxy may request an encryption key from the service platform, and the service platform may simultaneously generate a decryption key corresponding to the encryption key for the target proxy. And after the target proxy host acquires the encryption key generated by the service platform, encrypting the acquired data of the sharing equipment by using the encryption key to obtain an encrypted data ciphertext. After receiving the data ciphertext sent by the target proxy host, the terminal equipment sends a key acquisition request carrying identification information of the target proxy host to the service platform; after receiving a key acquisition request initiated by the terminal equipment, the service platform acquires a decryption key corresponding to an encryption key used by the target proxy host in an encryption manner according to the identification information of the target proxy host and returns the decryption key to the terminal equipment; and the terminal equipment receives the decryption key returned by the service platform, and decrypts the data ciphertext generated by the target proxy host by using the decryption key to obtain the data plaintext.
In an alternative embodiment, the service platform may generate a common encryption key and a decryption key that matches the encryption key. It will be appreciated that a common encryption key and decryption key that matches the encryption key are applicable to all proxies, i.e. each proxy uses the same encryption key and corresponding decryption key.
In another alternative embodiment, to further improve the security of data transmission, the service platform may also generate its dedicated encryption key and its matching decryption key for each proxy, that is, each proxy uses a different encryption key and corresponding decryption key. It should be noted that various encryption and decryption algorithms can be used to generate the encryption key and the decryption key.
In practical application, the target proxy host can authenticate whether the target proxy host has the authority to call the sharing device instead of the terminal device in various ways. In an alternative embodiment, the authentication may be performed by the service platform. As an example, the target proxy host obtains a first UDID (unique Device ID) of the shared Device, where the first UDID includes Device information of the shared Device; the target proxy host sends a device authentication request comprising a first UDID to the service platform so that the service server authenticates the target proxy host according to the device information included in the first UDID and the pre-stored device information of the shared device bound with the target proxy host; and if the target proxy host receives the authentication passing message returned by the service platform, determining that the target proxy host has the authority to be used as the intermediate equipment of the terminal equipment to call the sharing equipment.
For ease of understanding and differentiation, the UDID of the shared device uploaded by the target proxy in the device authentication phase is referred to as a first UDID, while the UDID of the shared device uploaded by the target proxy in the device registration phase is referred to as a second UDID.
In order to ensure that the service platform can perform authentication, before the target proxy host sends a device authentication request including the first UDID to the service platform, the device information of the shared device connected with the target proxy host can be acquired; generating a second UDID according to the device information of the shared device; and reporting the second UDID and the host information of the target proxy host to a service platform so as to bind and store the host information and the device information of the shared device included in the second UDID.
It will be appreciated that the target proxy registers the device supporting its surrogate end device calls into the service platform in advance. In consideration of data security, the target proxy host does not directly upload the acquired device information of the shared device to the service platform, but generates a second UDID according to the device information of the shared device, and reports the second UDID and the host information of the target proxy host to the service platform. The subsequent service platform can analyze the second UDID, acquire the device information of the second UDID, and bind and store the host information of the target agent host and the device information of the shared device.
It should be noted that the device information of the shared device may include the device type of the shared device, the product identification code PID, and the vendor identification code VID, and of course, the device information of the shared device is not limited to the above examples. The host information may include at least one of identification information of the host, an IP of the host, and a MAC (Media Access Control Address) Address of the host, although the host information is not limited to the above example.
Note that the second UDID may be generated by processing information such as a device type, a Product ID (PID), a Vendor ID (VID), and the like in the device information of the shared device using an existing UDID generation algorithm.
Therefore, in the device authentication phase, the target proxy acquires the device information of the sharing device needing authentication, processes the device information of the sharing device needing authentication by adopting the UDID generation algorithm, and generates a corresponding first UDID. And then, the target proxy host sends a device authentication request to the service platform, the service platform judges whether the device information of the shared device in the first UDID is one of the device information of the shared device bound with the target proxy host and stored in the device registration stage, if so, the service platform returns an authentication passing message to the target proxy host, and if not, the service platform returns an authentication failure message to the target proxy host.
It can be understood that the service platform returns an authentication passing message to the target proxy host, which indicates that the target proxy host has the authority to invoke the sharing device as the intermediate device of the terminal device. And when the service platform returns an authentication failure message to the target proxy host, the service platform shows that the target proxy host has no authority to be used as the intermediate device of the terminal device to call the sharing device.
In practical situations, the target proxy may be connected to a new device, but the authorized registration operation is not performed, so that the terminal device cannot call the new device through the target proxy. Therefore, on the basis of the above embodiment, if the target proxy has no authority to invoke the sharing device as the intermediate device of the terminal device, the prompting information may also be output, so that the manager may determine whether to execute the authorized registration operation of the sharing device to the target proxy.
Specifically, when the administrator determines to execute an authorized registration operation of the sharing device to the target proxy host, the target proxy host acquires device information of the sharing device that needs to perform the authorized registration operation, and processes the device information of the sharing device according to a UDID generation algorithm to generate the UDID of the sharing device. And reporting the UDID of the sharing equipment needing to be authorized to be registered and operated and the host information of the target proxy host to a service platform by the target proxy host so as to bind and store the host information and the equipment information of the sharing equipment included in the UDID.
Fig. 4 is a flowchart illustrating a further device sharing method according to an exemplary embodiment of the present application. As shown in fig. 4, the device sharing method includes the following steps:
401. the service platform receives a list acquisition request sent by the terminal equipment, wherein the list acquisition request comprises the equipment type required by the terminal equipment.
402. And acquiring the proxy host connected with the sharing equipment belonging to the equipment type according to the list acquisition request and generating a proxy host list.
403. And the service platform returns the proxy host list to the terminal equipment so that the terminal equipment initiates the call of the sharing equipment through a target proxy host in the proxy host list, wherein the target proxy host is the proxy host in the proxy list.
404. The service platform receives a device authentication request sent by a target proxy host, and calls the sharing device to authenticate whether the target proxy host has the authority as the intermediate device of the terminal device;
405. and the service platform returns an authentication passing message to the target proxy host, so that the target proxy host is used as the intermediate equipment of the terminal equipment to acquire the acquired data of the sharing equipment and return the acquired data to the terminal equipment.
In this embodiment, the service platform provides the terminal device with a list of proxy hosts that it can access. After receiving the list acquisition request sent by the terminal equipment, the terminal platform finds out the proxy host connected with the shared equipment of the equipment type required by the terminal equipment, and adds the found proxy host meeting the requirements of the terminal equipment into the proxy host list.
In an alternative embodiment, the host information of the configured proxy may be configured into the service platform during the registration phase of the sharing device. The service platform may real-time the host status of the configured proxy, or the configured proxy periodically reports its own host status to the service platform. In addition, the configured proxy host can also report the device information of the connected sharing device to the service platform periodically. The host state is divided into an abnormal state and a normal state.
Therefore, the service platform finds out the configured proxy in the normal state by analyzing the host state of the configured proxy. And if the device type of the shared device connected with the configured proxy host in the normal state is the device type required by the terminal device, determining the configured proxy host in the normal state as a target proxy host, and adding the target proxy host to a proxy host list.
After the service platform generates the proxy host list accessible by the terminal device, the service platform returns the proxy host list to the terminal device, so that the terminal device initiates a call to the sharing device through the target proxy host in the proxy host list. And then, the target proxy host receives the device calling request sent by the terminal device, and sends a device authentication request to the service platform before calling the collected data of the shared device. And then, the service platform judges whether the target proxy host has the authority to be used as the intermediate equipment of the terminal equipment to call the sharing equipment for authentication.
In an alternative embodiment, in order to ensure that the service platform can perform the device authentication operation, a binding relationship between the host information of the target proxy and the device information of the shared device needs to be generated at the service platform.
Specifically, before the service platform receives the device authentication request sent by the target proxy, the method may further include: the service platform receives an authorization registration request sent by the target proxy host, wherein the authorization registration request comprises host information of the target proxy host and a second UDID of a sharing device connected with the target proxy host; the service platform analyzes the second UDID to acquire equipment information of the shared equipment; and the service platform generates a binding relationship between the host information of the target proxy host and the device information of the shared device.
Therefore, in an optional embodiment, the service platform authenticates that the target proxy host has the right to invoke the sharing device as the intermediate device of the terminal device, specifically: the service platform acquires a first UDID from a device authentication request, wherein the first UDID comprises device information of shared devices connected with the target proxy host; comparing the device information of the shared device connected with the target proxy host, which is included in the first UDID, with the device information of the shared device corresponding to the host information of the target proxy host in a binding relationship maintained in advance; if the two are the same, the service platform returns an authentication passing message to the target proxy host.
It can be understood that the device information of the shared device connected to the target proxy host, which is included in the first UDID, is compared with the device information of the shared device corresponding to the host information of the target proxy host in the binding relationship maintained in advance, and if the two are different, the service platform may return an authentication failure message to the target proxy host.
According to the device sharing method provided by the embodiment of the application, the terminal device obtains the accessible proxy host list from the service platform, the terminal device initiates the call of the sharing device through the proxy host in the proxy host list, and receives the collected data returned by the sharing device and returned by the proxy host in the proxy host list, so that the device sharing is realized. Therefore, the proxy host is adopted to replace the terminal equipment to initiate the calling of the sharing equipment, so that one sharing equipment can be called by a plurality of terminal equipment, and the equipment utilization rate is improved. In addition, external equipment for acquiring different information is not required to be configured for each terminal device, and equipment purchase cost and maintenance cost are reduced.
On the basis of the above embodiment, in order to find out the proxy hosts that can successfully invoke the sharing device as quickly as possible, the service platform may set priorities for the proxy hosts in the proxy host list in the process of generating the proxy host list for the terminal device, so that the terminal device may initiate a device invocation request to the proxy hosts in the proxy host list according to the priorities of the proxy hosts, so that the proxy hosts invoke the sharing device.
In an optional embodiment, the service platform generates the proxy host list, specifically: the service platform determines the proxy host connected with the sharing equipment belonging to the equipment type according to the host state of the configured proxy host and the type of the sharing equipment connected with the configured proxy host and adds the proxy host to a proxy host list; and the service platform calculates the priority among the proxy hosts in the proxy host list and sorts the proxy hosts in the proxy host list according to the sequence of the priority from high to low.
In practical application, the service platform determines the influence factor of the priority of the proxy according to practical situations. In an optional embodiment, in order to objectively and reasonably calculate the priority of each proxy in the proxy list, one or more influence factors such as the host state of the proxy, the state of the sharing device belonging to the device type and connected to the proxy, the historical times of the terminal device successfully accessing the sharing device through the proxy, and the distance information between the terminal device and the proxy can be considered. After the terminal device successfully accesses the proxy host each time, the service platform can increase the historical times of successfully accessing the shared device by the terminal device through the proxy host one time. It can be understood that the more the proxy hosts have been historically, the greater the probability that the terminal device successfully acquires the collected data of the sharing device through the proxy host is.
The distance relationship between the terminal device and the proxy host can be judged based on the distance information between the terminal device and the proxy host. It can be understood that the closer the proxy is to the terminal device, the faster the data transmission speed between the terminal device and the proxy is, and at the same time, the transmitted data is not easily lost.
The distance information between the terminal device and the proxy may be calculated based on the IP address of the terminal device and the IP address of the proxy, and of course, the distance information may be calculated based on the geographical location information of the terminal device and the geographical location information of the proxy, but is not limited thereto.
As an example, the service platform may calculate the priority of each proxy in the proxy list by performing a weighted summation of at least one of a host status of the proxy, a status of a sharing device belonging to the device type to which the proxy is connected, a historical number of times that the sharing device is successfully accessed by the terminal device through the proxy, distance information between the terminal device and the proxy, and the like.
Specifically, for each proxy in the proxy list, the host state of the proxy is recorded as C, the device state of the device connected to the proxy and belonging to the device type is recorded as S, the historical number of times that the terminal device successfully accesses the shared device through the proxy is recorded as num, the distance information between the terminal device and the proxy is recorded as d, and then the score that the proxy can be accessed is recorded as w1*C+w2*S+w3*num+w4D. It will be appreciated that the higher the score, the greater the probability that the proxy will be accessed.
Wherein, w1、w2、w3、w4Respectively, the weight of the above-mentioned influencing factors, w1+w2+w3+w41. In assigning the weight of each influencing factor, the setting may be made according to the actual situation.
The value of the host state C is 0 or 1, and when the host state C is 0, it indicates that the corresponding proxy is in an abnormal state, and when the host state C is 1, it indicates that the corresponding proxy is in a normal state. The value of the device state S is 0 or 1, and when the device state S is 1, it indicates that the corresponding device is available, and when the device state S is 0, it indicates that the corresponding device is unavailable.
Therefore, after the accessible score of each proxy in the proxy list is determined, the priority of each proxy is set according to the accessible score of each proxy. It will be appreciated that the higher the score that a proxy can be accessed, the higher the priority of the proxy, whereas the lower the score that a proxy can be accessed, the lower the priority of the proxy. For example, a plurality of priorities are set, each priority corresponds to a score range, the score range where the proxy can be accessed is judged, and the priority corresponding to the proxy is determined.
It should be noted that the execution subjects of the steps of the methods provided in the above embodiments may be the same device, or different devices may be used as the execution subjects of the methods. For example, the execution subjects of step 201 to step 203 may be device a; for another example, the execution subject of steps 201 and 202 may be device a, and the execution subject of step 203 may be device B; and so on.
In addition, in some of the flows described in the above embodiments and the drawings, a plurality of operations are included in a specific order, but it should be clearly understood that the operations may be executed out of the order presented herein or in parallel, and the sequence numbers of the operations, such as 201, 202, etc., are merely used for distinguishing different operations, and the sequence numbers do not represent any execution order per se. Additionally, the flows may include more or fewer operations, and the operations may be performed sequentially or in parallel. It should be noted that, the descriptions of "first", "second", etc. in this document are used for distinguishing different messages, devices, modules, etc., and do not represent a sequential order, nor limit the types of "first" and "second" to be different.
Fig. 5 is a schematic structural diagram of a terminal device according to an exemplary embodiment of the present application. As shown in fig. 5, the terminal device includes: the method comprises the following steps: memory 11, processor 12 and communication component 13.
The memory 11 is used for storing a computer program and may be configured to store other various data to support operations on the processor. Examples of such data include instructions for any application or method operating on the processor, contact data, phonebook data, messages, pictures, videos, and so forth.
The memory 11 may be implemented by any type or combination of volatile or non-volatile memory devices, such as Static Random Access Memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic or optical disks.
A processor 12, coupled to the memory 11, for executing the computer program in the memory 11 for:
acquiring a proxy host list accessible by the terminal equipment from a service platform, wherein the proxy host list stores proxy hosts accessible by the terminal equipment, and the proxy hosts are connected with shared equipment of the equipment type required by the terminal equipment;
initiating, by a proxy in the proxy list, a call to the shared device;
and receiving collected data returned by the sharing device by the proxy in the proxy list through the communication component 13 to realize device sharing.
Further, when the processor 12 obtains the proxy host list accessible to it, it is specifically configured to:
sending a list acquisition request to a service platform, wherein the list acquisition request comprises a device type required by terminal equipment, so that the service platform can acquire a proxy host connected with shared equipment belonging to the device type and generate a proxy host list; and receiving the proxy host list returned by the service platform.
Further, the proxy hosts in the proxy host list are arranged according to the order of priority from high to low, and when the processor 12 calls the shared device, the processor is specifically configured to: according to the sequence of the priority from high to low, equipment calling requests are sequentially sent to the proxy hosts in the proxy host list, so that the proxy hosts can call the shared equipment under the equipment type connected with the proxy hosts until the target proxy hosts are successfully called;
or, according to the priority between the proxy hosts, selecting a target proxy host from the proxy host list; and sending a device calling request to the target proxy host for the target proxy host to call the sharing device under the device type connected with the target proxy host.
The terminal device shown in fig. 5 may execute the method of the embodiment shown in fig. 2, and the terminal device may be a terminal device such as a notebook computer, a tablet, a mobile phone, and the like, and reference may be made to the related description of the embodiment shown in fig. 2 for a part not described in detail in this embodiment. The implementation process and technical effect of the technical solution refer to the description in the embodiment shown in fig. 2, and are not described herein again.
Further, as shown in fig. 5, the apparatus further includes: display 14, power supply 15, audio 16, and other components. Only some of the components are schematically shown in fig. 5, and it is not meant that the processor includes only the components shown in fig. 5.
Accordingly, the present application further provides a computer-readable storage medium storing a computer program, where the computer program is capable of implementing the steps of the method in the foregoing method embodiment, which can be executed by a processor in the embodiment shown in fig. 2.
Fig. 6 is a schematic structural diagram of a proxy according to an exemplary embodiment of the present application. As shown in fig. 6, the proxy includes: the method comprises the following steps: memory 21, processor 22 and communication component 23.
The memory 21 is used for storing computer programs and may be configured to store other various data to support operations on the processor. Examples of such data include instructions for any application or method operating on the processor, contact data, phonebook data, messages, pictures, videos, and so forth.
The memory 21 may be implemented by any type or combination of volatile or non-volatile memory devices, such as Static Random Access Memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic or optical disks.
A processor 22, coupled to the memory 21, for executing the computer program in the memory 21 for:
responding to a device calling request sent by the terminal device through the communication component 23, wherein the device calling request comprises a device type required by the terminal device;
identifying the state of the shared device under the device type connected with the shared device;
if the shared device is in an available state, the target proxy host judges whether the target proxy host has the authority to be used as the intermediate device of the terminal device to call the shared device;
if yes, the target proxy host acquires the acquired data of the shared device and returns the acquired data to the terminal device.
Further, when determining whether the processor 22 has the right to call the sharing device as the intermediate device of the terminal device, the processor is specifically configured to:
acquiring a first device identification code UDID of the shared device, wherein the first device identification code UDID comprises device information of the shared device;
sending a device authentication request including the first UDID to a service platform, so that the service server authenticates the target proxy according to the device information included in the first UDID and the pre-stored device information of the shared device bound with the target proxy;
and if the authentication passing message returned by the service platform is received, determining that the terminal equipment has the authority to be used as the intermediate equipment of the terminal equipment to call the sharing equipment.
Further, the processor 22, before sending the device authentication request including the first UDID to the service platform, is further configured to:
acquiring equipment information of shared equipment connected with the target proxy host;
generating a second UDID according to the device information of the shared device;
and reporting the second UDID and the host information of the target agent host to a service platform so as to bind and store the host information and the device information of the shared device included in the second UDID.
Further, the device information of the shared device includes a device type, a product identification code, and a vendor identification code of the shared device, and when the processor 22 generates the second UDID, the processor is specifically configured to:
and processing the device type, the product identification code and the supplier identification code of the sharing device according to a UDID generation algorithm to generate the second UDID.
The proxy shown in fig. 6 may execute the method of the embodiment shown in fig. 3, and reference may be made to the related description of the embodiment shown in fig. 3 for a part of this embodiment that is not described in detail. The implementation process and technical effect of the technical solution refer to the description in the embodiment shown in fig. 3, and are not described herein again.
Further, as shown in fig. 6, the proxy further includes: display 24, power supply components 25, audio components 26, and the like. Only some of the components are schematically shown in fig. 6, and it is not meant that the processor includes only the components shown in fig. 6. In addition, the components shown by the dashed boxes in fig. 6 are optional components, not necessary components, and the specific implementation of the device sharing apparatus may be determined. If the proxy is implemented as a terminal device such as a notebook computer, a tablet, a mobile phone, etc., the proxy may include components shown by dotted boxes in fig. 6; if the proxy is implemented as a server device such as a conventional server, a cloud server, or a server array, the components shown by the dashed boxes in fig. 6 are not included.
The proxy further comprises: display, power components, audio components, and the like. The component assemblies are presented and are not meant to imply that a processor includes only the illustrated components. In addition, the components shown by the dashed line boxes are optional components, not necessary components, and the specific implementation form of the device sharing apparatus is specifically seen.
Accordingly, the present application further provides a computer-readable storage medium storing a computer program, where the computer program is capable of implementing the steps of the method in the foregoing method embodiment, which may be executed by a processor in the embodiment shown in fig. 3.
Fig. 7 is a schematic structural diagram of a service platform according to an exemplary embodiment of the present application. As shown in fig. 7, the service platform includes: the method comprises the following steps: memory 31, processor 32, and communications component 33.
The memory 31 is used for storing computer programs and may be configured to store other various data to support operations on the processor. Examples of such data include instructions for any application or method operating on the processor, contact data, phonebook data, messages, pictures, videos, and so forth.
The memory 31 may be implemented by any type or combination of volatile or non-volatile memory devices, such as Static Random Access Memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic or optical disks.
A processor 32, coupled to the memory 31, for executing the computer program in the memory 31 for:
receiving a list acquisition request sent by the terminal device through the communication component 33, where the list acquisition request includes a device type required by the terminal device;
according to the list acquisition request, acquiring a proxy host connected with shared equipment belonging to the equipment type and generating a proxy host list;
returning the proxy host list to the terminal equipment to enable the terminal equipment to initiate the call of the sharing equipment through a target proxy host in the proxy host list, wherein the target proxy host is a proxy host in the proxy list;
receiving a device authentication request sent by a target proxy host through a communication component 33, and calling the sharing device for authentication if the target proxy host has the authority as an intermediate device of the terminal device;
and returning an authentication passing message to the target proxy host so that the target proxy host is used as the intermediate equipment of the terminal equipment to acquire the acquired data of the sharing equipment and return the acquired data to the terminal equipment.
Further, when the processor 32 generates the proxy host list, it is specifically configured to: determining a proxy host connected with sharing equipment belonging to the equipment type according to the host state of the configured proxy host and the type of the sharing equipment connected with the configured proxy host, and adding the proxy host to a proxy host list; and calculating the priority among the proxy hosts in the proxy host list, and sequencing the proxy hosts in the proxy host list according to the sequence from high to low in priority.
Further, when calculating the priority of the proxy in the proxy list, the processor 32 is specifically configured to: for each proxy host in the proxy host list, acquiring at least one of the host state of the proxy host, the state of the shared device connected with the proxy host and belonging to the device type, the historical times of successfully accessing the shared device by the terminal device through the proxy host, and the distance information between the terminal device and the proxy host; calculating the priority between the proxy and other proxies in the proxy list according to the at least one message.
Further, the processor 32 is specifically configured to, when performing device authentication: acquiring a first UDID from a device authentication request, wherein the first UDID comprises device information of shared devices connected with the target proxy host; comparing the device information of the shared device connected with the target proxy host, which is included in the first UDID, with the device information of the shared device corresponding to the host information of the target proxy host in a binding relationship maintained in advance; if the two are the same, the authentication passing message is returned to the target proxy host.
Further, the processor 32 is further configured to, before performing device authentication: receiving an authorization registration request sent by the target proxy host, wherein the authorization registration request comprises host information of the target proxy host and a second UDID of a sharing device connected with the target proxy host; analyzing the second UDID to acquire the equipment information of the shared equipment; and generating a binding relationship between the host information of the target proxy host and the device information of the shared device.
The service platform shown in fig. 7 may execute the method of the embodiment shown in fig. 4, where the service platform may be a server device such as a conventional server, a cloud server, or a server array, and a part not described in detail in this embodiment may refer to the relevant description of the embodiment shown in fig. 4. The implementation process and technical effect of the technical solution refer to the description in the embodiment shown in fig. 4, and are not described herein again.
Further, as shown in fig. 7, the service platform further includes: power supply components 34, and the like. Only some of the components are schematically shown in fig. 7, and the processor is not meant to include only the components shown in fig. 7.
Accordingly, the present application further provides a computer-readable storage medium storing a computer program, where the computer program is capable of implementing the steps of the method in the foregoing method embodiment, which can be executed by a processor in the embodiment shown in fig. 4.
The communication components of fig. 5, 6, and 7 described above are configured to facilitate wired or wireless communication between the device in which the communication component is located and other devices. The device where the communication component is located can access a wireless network based on a communication standard, such as a WiFi, a 2G, 3G, 4G/LTE, 5G and other mobile communication networks, or a combination thereof. In an exemplary embodiment, the communication component receives a broadcast signal or broadcast related information from an external broadcast management system via a broadcast channel. In one exemplary embodiment, the communication component further includes a Near Field Communication (NFC) module to facilitate short-range communications. For example, the NFC module may be implemented based on Radio Frequency Identification (RFID) technology, infrared data association (IrDA) technology, Ultra Wideband (UWB) technology, Bluetooth (BT) technology, and other technologies.
The displays in fig. 5 and 6 include screens, which may include a Liquid Crystal Display (LCD) and a Touch Panel (TP). If the screen includes a touch panel, the screen may be implemented as a touch screen to receive an input signal from a user. The touch panel includes one or more touch sensors to sense touch, slide, and gestures on the touch panel. The touch sensor may not only sense the boundary of a touch or slide action, but also detect the duration and pressure associated with the touch or slide operation.
The power supply modules of fig. 5, 6 and 7 provide power to the various components of the device in which the power supply module is located. The power components may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power for the device in which the power component is located.
The audio component in fig. 5 and 6 may be configured to output and/or input an audio signal. For example, the audio component includes a Microphone (MIC) configured to receive an external audio signal when the device in which the audio component is located is in an operational mode, such as a call mode, a recording mode, and a voice recognition mode. The received audio signal may further be stored in a memory or transmitted via a communication component. In some embodiments, the audio assembly further comprises a speaker for outputting audio signals.
As will be appreciated by one skilled in the art, embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
The present application is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the application. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
In a typical configuration, a computing device includes one or more processors (CPUs), input/output interfaces, network interfaces, and memory.
The memory may include forms of volatile memory in a computer readable medium, Random Access Memory (RAM) and/or non-volatile memory, such as Read Only Memory (ROM) or flash memory (flash RAM). Memory is an example of a computer-readable medium.
Computer-readable media, including both non-transitory and non-transitory, removable and non-removable media, may implement information storage by any method or technology. The information may be computer readable instructions, data structures, modules of a program, or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), Static Random Access Memory (SRAM), Dynamic Random Access Memory (DRAM), other types of Random Access Memory (RAM), Read Only Memory (ROM), Electrically Erasable Programmable Read Only Memory (EEPROM), flash memory or other memory technology, compact disc read only memory (CD-ROM), Digital Versatile Discs (DVD) or other optical storage, magnetic cassettes, magnetic tape magnetic disk storage or other magnetic storage devices, or any other non-transmission medium that can be used to store information that can be accessed by a computing device. As defined herein, a computer readable medium does not include a transitory computer readable medium such as a modulated data signal and a carrier wave.
It should also be noted that the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other like elements in a process, method, article, or apparatus that comprises the element.
The above description is only an example of the present application and is not intended to limit the present application. Various modifications and changes may occur to those skilled in the art. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present application should be included in the scope of the claims of the present application.
Claims (16)
1. A device sharing method, comprising:
the method comprises the steps that terminal equipment obtains an accessible proxy host list from a service platform, wherein the proxy host list stores proxy hosts accessible by the terminal equipment, and the proxy hosts are connected with shared equipment of equipment types required by the terminal equipment;
the terminal equipment initiates the call of the sharing equipment through the proxy host in the proxy host list;
and the terminal equipment receives the collected data returned by the sharing equipment and returned by the proxy in the proxy list so as to realize equipment sharing.
2. The method of claim 1, wherein the terminal device obtaining the list of proxy hosts accessible to the terminal device from the service platform comprises:
the method comprises the steps that terminal equipment sends a list obtaining request to a service platform, wherein the list obtaining request comprises equipment types required by the terminal equipment, so that the service platform obtains a proxy host connected with shared equipment belonging to the equipment types and generates a proxy host list; and receiving the proxy host list returned by the service platform.
3. The method according to claim 1 or 2, wherein the proxy hosts in the proxy host list are arranged in order of priority from high to low, and the terminal device initiates a call to the sharing device through the proxy hosts in the proxy host list, including:
the terminal equipment sequentially sends equipment calling requests to the proxy hosts in the proxy host list according to the sequence of the priority from high to low, so that the proxy hosts can call the shared equipment under the equipment type connected with the proxy hosts until the target proxy hosts are successfully called;
or,
the terminal equipment selects a target proxy host from the proxy host list according to the priority among the proxy hosts;
and sending a device calling request to the target proxy host for the target proxy host to call the sharing device under the device type connected with the target proxy host.
4. A device sharing method, comprising:
the target proxy host responds to a device calling request sent by the terminal device, wherein the device calling request comprises a device type required by the terminal device;
the target proxy host identifies the state of the sharing equipment under the equipment type connected with the target proxy host;
if the shared device is in an available state, the target proxy host judges whether the target proxy host has the authority to be used as the intermediate device of the terminal device to call the shared device;
if yes, the target proxy host acquires the acquired data of the shared device and returns the acquired data to the terminal device.
5. The method of claim 4, wherein the determining, by the target proxy, whether the target proxy has the right to invoke the sharing device as an intermediate device of the terminal device comprises:
the target proxy host acquires a first device identification code (UDID) of the shared device, wherein the first UDID comprises device information of the shared device;
the target agent host sends a device authentication request comprising the first UDID to a service platform so that the service server side authenticates the target agent host according to the device information included in the first UDID and the pre-stored device information of the shared device bound with the target agent host;
and if the target proxy host receives the authentication passing message returned by the service platform, determining that the target proxy host has the authority to be used as the intermediate equipment of the terminal equipment to call the sharing equipment.
6. The method of claim 5, further comprising, prior to the target proxy sending a device authentication request including the first UDID to a service platform:
acquiring equipment information of shared equipment connected with the target proxy host;
generating a second UDID according to the device information of the shared device;
and reporting the second UDID and the host information of the target agent host to a service platform so as to bind and store the host information and the device information of the shared device included in the second UDID.
7. The method of claim 6, wherein the device information of the shared device comprises a device type, a product identification code, and a vendor identification code of the shared device, and wherein generating the second UDID according to the device information of the shared device comprises:
and processing the device type, the product identification code and the supplier identification code of the sharing device according to a UDID generation algorithm to generate the second UDID.
8. A device sharing method, comprising:
the method comprises the steps that a service platform receives a list obtaining request sent by terminal equipment, wherein the list obtaining request comprises an equipment type required by the terminal equipment;
according to the list acquisition request, acquiring a proxy host connected with shared equipment belonging to the equipment type and generating a proxy host list;
the service platform returns the proxy host list to the terminal equipment so that the terminal equipment initiates calling of the sharing equipment through a target proxy host in the proxy host list, wherein the target proxy host is a proxy host in the proxy list;
the service platform receives a device authentication request sent by a target proxy host, and calls the sharing device to authenticate whether the target proxy host has the authority as the intermediate device of the terminal device;
and the service platform returns an authentication passing message to the target proxy host, so that the target proxy host is used as the intermediate equipment of the terminal equipment to acquire the acquired data of the sharing equipment and return the acquired data to the terminal equipment.
9. The method of claim 8, wherein the service platform generating the proxy list comprises:
the service platform determines the proxy host connected with the sharing equipment belonging to the equipment type according to the host state of the configured proxy host and the type of the sharing equipment connected with the configured proxy host and adds the proxy host to a proxy host list;
and the service platform calculates the priority among the proxy hosts in the proxy host list and sorts the proxy hosts in the proxy host list according to the sequence of the priority from high to low.
10. The method of claim 9, wherein the service platform calculates the priority of the proxies in the proxy list, comprising:
for each proxy in the proxy list, the service platform acquires at least one of a host state of the proxy, a state of a shared device connected to the proxy and belonging to the device type, historical times of successfully accessing the shared device by the terminal device through the proxy, and distance information between the terminal device and the proxy;
calculating the priority between the proxy and other proxies in the proxy list according to the at least one message.
11. The method of claim 10, wherein authenticating whether the target proxy host has authority to invoke the shared device as an intermediary device of the end device comprises:
the service platform acquires a first UDID from a device authentication request, wherein the first UDID comprises device information of shared devices connected with the target proxy host; comparing the device information of the shared device connected with the target proxy host, which is included in the first UDID, with the device information of the shared device corresponding to the host information of the target proxy host in a binding relationship maintained in advance;
if the two are the same, the service platform returns an authentication passing message to the target proxy host.
12. The method of claim 11, prior to the service platform receiving the device authentication request sent by the target proxy, further comprising:
the service platform receives an authorization registration request sent by the target proxy host, wherein the authorization registration request comprises host information of the target proxy host and/or a second UDID of a sharing device connected with the target proxy host;
the service platform analyzes the second UDID to acquire equipment information of the shared equipment;
and the service platform generates a binding relationship between the host information of the target proxy host and the device information of the shared device.
13. A terminal device, comprising: a memory, a processor, and a communications component;
the memory for storing a computer program;
the processor, coupled with the memory, to execute the computer program to:
acquiring a proxy host list accessible by the terminal equipment from a service platform, wherein the proxy host list stores proxy hosts accessible by the terminal equipment, and the proxy hosts are connected with shared equipment of the equipment type required by the terminal equipment;
initiating, by a proxy in the proxy list, a call to the shared device;
and receiving collected data returned by the sharing equipment and returned by the proxy in the proxy list through the communication component so as to realize equipment sharing.
14. A proxy, implementable as a target proxy, comprising: a memory, a processor, and a communications component;
the memory for storing a computer program;
the processor, coupled with the memory, to execute the computer program to:
responding to a device calling request sent by the terminal device through the communication component, wherein the device calling request comprises a device type required by the terminal device;
identifying the state of the shared device under the device type connected with the shared device;
if the shared device is in an available state, the target proxy host judges whether the target proxy host has the authority to be used as the intermediate device of the terminal device to call the shared device;
if yes, the target proxy host acquires the acquired data of the shared device and returns the acquired data to the terminal device.
15. A service platform, comprising: a memory, a processor, and a communications component;
the memory for storing a computer program;
the processor, coupled with the memory, to execute the computer program to:
receiving a list acquisition request sent by terminal equipment through a communication component, wherein the list acquisition request comprises an equipment type required by the terminal equipment;
according to the list acquisition request, acquiring a proxy host connected with shared equipment belonging to the equipment type and generating a proxy host list;
returning the proxy host list to the terminal equipment to enable the terminal equipment to initiate the call of the sharing equipment through a target proxy host in the proxy host list, wherein the target proxy host is a proxy host in the proxy list;
receiving a device authentication request sent by a target proxy host through a communication component, and calling the sharing device for authentication if the target proxy host has the authority as an intermediate device of the terminal device;
and returning an authentication passing message to the target proxy host so that the target proxy host is used as the intermediate equipment of the terminal equipment to acquire the acquired data of the sharing equipment and return the acquired data to the terminal equipment.
16. A computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, causes the processor to carry out the steps of the method according to any one of claims 1 to 12.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202010976223.7A CN112217873B (en) | 2020-09-16 | 2020-09-16 | Device sharing method, related device and storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202010976223.7A CN112217873B (en) | 2020-09-16 | 2020-09-16 | Device sharing method, related device and storage medium |
Publications (2)
Publication Number | Publication Date |
---|---|
CN112217873A true CN112217873A (en) | 2021-01-12 |
CN112217873B CN112217873B (en) | 2024-02-02 |
Family
ID=74049587
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202010976223.7A Active CN112217873B (en) | 2020-09-16 | 2020-09-16 | Device sharing method, related device and storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN112217873B (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN112383642A (en) * | 2021-01-16 | 2021-02-19 | 广州技象科技有限公司 | Internet of things equipment data interaction method and device |
WO2023184559A1 (en) * | 2022-04-02 | 2023-10-05 | Oppo广东移动通信有限公司 | Device sharing method and apparatus, and device, storage medium and program product |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1664798A (en) * | 2004-03-02 | 2005-09-07 | 联想(北京)有限公司 | External equipment resource sharing method |
CN105338113A (en) * | 2015-11-25 | 2016-02-17 | 北京航空航天大学 | Multi-platform data interconnected system for sharing urban data resources |
CN108345642A (en) * | 2018-01-12 | 2018-07-31 | 深圳壹账通智能科技有限公司 | Method, storage medium and the server of website data are crawled using Agent IP |
CN109274782A (en) * | 2018-08-24 | 2019-01-25 | 北京创鑫旅程网络技术有限公司 | A kind of method and device acquiring website data |
-
2020
- 2020-09-16 CN CN202010976223.7A patent/CN112217873B/en active Active
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1664798A (en) * | 2004-03-02 | 2005-09-07 | 联想(北京)有限公司 | External equipment resource sharing method |
CN105338113A (en) * | 2015-11-25 | 2016-02-17 | 北京航空航天大学 | Multi-platform data interconnected system for sharing urban data resources |
CN108345642A (en) * | 2018-01-12 | 2018-07-31 | 深圳壹账通智能科技有限公司 | Method, storage medium and the server of website data are crawled using Agent IP |
CN109274782A (en) * | 2018-08-24 | 2019-01-25 | 北京创鑫旅程网络技术有限公司 | A kind of method and device acquiring website data |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN112383642A (en) * | 2021-01-16 | 2021-02-19 | 广州技象科技有限公司 | Internet of things equipment data interaction method and device |
CN112383642B (en) * | 2021-01-16 | 2021-04-09 | 广州技象科技有限公司 | Internet of things equipment data interaction method and device |
WO2023184559A1 (en) * | 2022-04-02 | 2023-10-05 | Oppo广东移动通信有限公司 | Device sharing method and apparatus, and device, storage medium and program product |
Also Published As
Publication number | Publication date |
---|---|
CN112217873B (en) | 2024-02-02 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN110602087B (en) | Intelligent screen projection method and device, intelligent terminal and server | |
EP3255832B1 (en) | Dynamic encryption method, terminal and server | |
CN110011954B (en) | Homomorphic encryption-based biological identification method, device, terminal and business server | |
CN113452719A (en) | Application login method and device, terminal equipment and storage medium | |
WO2015070732A1 (en) | Access control system, authorization method and device thereof, and storage medium | |
US20180343118A1 (en) | Method employed in user authentication system and information processing apparatus included in user authentication system | |
CN112217873B (en) | Device sharing method, related device and storage medium | |
CN111277554A (en) | Authentication method, device, system and storage medium | |
US20170288870A1 (en) | Methods and systems of securing and retrieving secret information | |
US9667784B2 (en) | Methods and devices for providing information in voice service | |
CN110781481A (en) | Single sign-on method, client, server, and storage medium | |
CN106878252B (en) | Method for establishing password-free login relationship, method for clearing account and device thereof | |
CN112465523A (en) | Block chain system-based channel conflict identification method, device, medium and server | |
US11716203B2 (en) | Secure transmission | |
WO2016138743A1 (en) | Secure payment method, mobile terminal, and payment authentication server | |
US20220231837A1 (en) | Intelligent and secure packet captures for cloud solutions | |
CN110457959B (en) | Information transmission method and device based on Trust application | |
CN111064653B (en) | Image exchange method, device and system and electronic equipment | |
CN113656169A (en) | Task request processing method and device, management server and storage medium | |
CN115208555A (en) | Gateway negotiation method, device and storage medium | |
CN112118210A (en) | Authentication key configuration method, device, system and storage medium | |
CN115022004B (en) | Data processing method, device and server | |
US20180198781A1 (en) | Digital frame authentication through crowdsourcing | |
CN116755842B (en) | Identity verification system deployment method, device, equipment and storage medium | |
CN111240868B (en) | Instance processing and calling method, device, system and storage medium |
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 |