CN115643046A - Authorization method of smart device and computer-readable storage medium - Google Patents
Authorization method of smart device and computer-readable storage medium Download PDFInfo
- Publication number
- CN115643046A CN115643046A CN202211122586.XA CN202211122586A CN115643046A CN 115643046 A CN115643046 A CN 115643046A CN 202211122586 A CN202211122586 A CN 202211122586A CN 115643046 A CN115643046 A CN 115643046A
- Authority
- CN
- China
- Prior art keywords
- authorization
- main control
- authorization code
- control device
- controlled
- 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.)
- Pending
Links
- 238000013475 authorization Methods 0.000 title claims abstract description 486
- 238000000034 method Methods 0.000 title claims abstract description 117
- 238000012795 verification Methods 0.000 claims abstract description 94
- 230000004044 response Effects 0.000 claims description 5
- 238000004590 computer program Methods 0.000 claims description 4
- 238000010586 diagram Methods 0.000 description 25
- 230000008569 process Effects 0.000 description 21
- 230000003993 interaction Effects 0.000 description 18
- 238000012545 processing Methods 0.000 description 6
- 230000009286 beneficial effect Effects 0.000 description 3
- 238000004891 communication Methods 0.000 description 3
- 230000006870 function Effects 0.000 description 3
- 230000008859 change Effects 0.000 description 2
- 238000011161 development Methods 0.000 description 2
- 238000012986 modification Methods 0.000 description 2
- 230000004048 modification Effects 0.000 description 2
- 230000005540 biological transmission Effects 0.000 description 1
- 238000006243 chemical reaction Methods 0.000 description 1
- 230000000694 effects Effects 0.000 description 1
- 238000005516 engineering process Methods 0.000 description 1
- 239000004973 liquid crystal related substance Substances 0.000 description 1
- 238000010295 mobile communication Methods 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
- 239000007787 solid Substances 0.000 description 1
- 230000000007 visual effect Effects 0.000 description 1
Images
Landscapes
- Telephonic Communication Services (AREA)
Abstract
The invention relates to an authorization method of intelligent equipment, wherein a controlled device receives a first authorization connection request sent by a main control device, the first authorization connection request comprises first device information, first user identification information and a first authorization code, the first authorization code is generated and sent to the main control device according to second device information and first effective authorization duration after a controlled device receives an authorization code acquisition instruction sent by the main control device, the first effective authorization duration is the effective permission duration of the main control device for controlling the controlled device, the main controlled device carries out verification based on the first device information, the first user identification information and the first authorization code, and after the verification is confirmed to be passed, a first verification success instruction is sent to the main control device to indicate that the main control device and the controlled device are successfully authorized to connect. By adopting the method, the resource occupation can be reduced, and the security is improved by a mode of carrying out authorized connection verification through the decryption authorization code.
Description
Technical Field
The present disclosure relates to the field of computer technologies, and in particular, to an authorization method for an intelligent device and a computer-readable storage medium.
Background
With the continuous development of the smart home system, various smart devices enter the life and work of users, great intelligence and convenience are brought to the life and work of the users, and at present, when the smart devices are used, the relationship between control and control among the smart devices needs to be established, and information interaction among the smart devices is carried out.
In the prior art, a Message Queue Telemetry Transport (MQTT) protocol may be used to implement information interaction between intelligent devices, where the MQTT protocol is a client-server based Message publish/subscribe Transport protocol, and user identification information, device information, and a user password are sent to a controlled device through a master control device, so that the controlled device performs a first connection based on the user identification information and the user password, and after the first connection is successful, in response to an authorization request sent by the master control device, a user is allowed to select whether to authorize the master control device on a pop-up interface, and if authorization is granted, device information is stored in a white list, and an authorization success Message is sent to the master control device to indicate that authorization for the master control device is successful.
However, the prior art has the problem of wasting storage resources, and the white list is lost, which causes the need to authorize the controlled device again, and thus the operation is complicated and the security is low.
Disclosure of Invention
In order to solve the above technical problem or at least partially solve the above technical problem, the present disclosure provides an authorization method for an intelligent device and a computer-readable storage medium, where a first device information, a first user identification information, and a first authorization code included in a first authorization connection request are verified to determine whether the first authorization connection request of a main control device passes through, so as to avoid querying in a white list in the prior art and determining whether the main control device is authorized to trust the operation of the device, that is, the authorized main control device does not need to be stored in the white list, reduce resource occupation, and improve security by decrypting the authorization code to perform authorization connection verification. In order to achieve the above purpose, the technical solutions provided by the embodiments of the present disclosure are as follows:
in a first aspect, the present disclosure provides an authorization method for an intelligent device, which is applied to a controlled device, and includes:
receiving a first authorization connection request sent by a master control device, wherein the first authorization connection request includes first device information, first user identification information and a first authorization code, the first authorization code is generated and sent to the master control device by the controlled device according to second device information and a first effective authorization duration after receiving an authorization code acquisition instruction sent by the master control device, and the first effective authorization duration is an effective permission duration for the master control device to control the controlled device;
and checking based on the first device information, the first user identification information and the first authorization code, and after the checking is determined to be passed, sending a first checking success instruction to the main control device to indicate that the main control device and the controlled device are successfully connected in an authorized mode.
In a second aspect, the present disclosure provides an authorization method for an intelligent device, which is applied to a master control device, and includes:
sending a first authorization connection request to controlled equipment, so that the controlled equipment performs verification based on first equipment information, first user identification information and a first authorization code, and after the verification is determined to be passed, sending a first verification success instruction to the main control equipment, wherein the first authorization request comprises the first equipment information, the first user identification information and the first authorization code;
and receiving the first verification success instruction sent by the controlled device to indicate that the authorized connection between the main control device and the controlled device is successful.
In a third aspect, the present disclosure provides a computer readable storage medium having stored thereon a computer program which, when executed by a processor, performs the method of any of the first or second aspects.
Compared with the prior art, the technical scheme provided by the embodiment of the disclosure has the following advantages: the method comprises the steps that first authorization connection requests are sent to controlled equipment through the main control equipment, the controlled equipment receives the first authorization connection requests sent by the main control equipment, wherein the first authorization connection requests comprise first equipment information, first user identification information and first authorization codes, the first authorization codes are generated and sent to the main control equipment according to second equipment information and first effective authorization duration after the controlled equipment receives authorization code obtaining instructions sent by the main control equipment, the first effective authorization duration is the effective authorization duration of the controlled equipment controlled by the main control equipment, the controlled equipment carries out verification on the basis of the first equipment information, the first user identification information and the first authorization codes, and after the verification is confirmed to be passed, first verification success instructions are sent to the main control equipment to indicate that the main control equipment and the controlled equipment are authorized to be connected successfully. In the process, the first device information, the first user identification information and the first authorization code included in the first authorization connection request are verified to determine whether the first authorization connection request of the main control device passes through, so that the inquiry in a white list in the prior art is avoided, and the operation of the trust device for determining whether the main control device is authorized is determined, that is, the authorized main control device does not need to be stored in the white list, so that the resource occupation is reduced, and the security is improved by decrypting the authorization code to perform authorization connection verification.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present disclosure and together with the description, serve to explain the principles of the disclosure.
In order to more clearly illustrate the embodiments or technical solutions in the prior art of the present disclosure, the drawings used in the description of the embodiments or prior art will be briefly described below, and it is obvious for those skilled in the art that other drawings can be obtained according to the drawings without inventive exercise.
Fig. 1A is a schematic view of an application scenario of an authorization method for an intelligent device according to an embodiment of the present disclosure;
fig. 1B is a schematic diagram of an authorization method of a smart device provided in the prior art;
FIG. 1C is a schematic diagram of another explicit authorization method provided in the prior art;
fig. 2A is a block diagram of a hardware configuration of an electronic device according to one or more embodiments of the present disclosure;
fig. 2B is a software configuration diagram of an electronic device according to one or more embodiments of the present disclosure;
FIG. 2C is a schematic illustration of an icon control interface display of an application program included in a controlled device according to one or more embodiments of the present disclosure;
fig. 3A is a schematic flowchart of an authorization method of an intelligent device according to an embodiment of the present disclosure;
fig. 3B is a schematic diagram of an interaction process of an authorization method of an intelligent device according to an embodiment of the present disclosure;
fig. 4A is a schematic flowchart of another authorization method for an intelligent device according to an embodiment of the present disclosure;
fig. 4B is an interaction diagram of another authorization method for a smart device according to an embodiment of the present disclosure;
fig. 5A is a schematic flowchart of an authorization method of a smart device according to another embodiment of the present disclosure;
fig. 5B is an interaction diagram of another authorization method for a smart device according to an embodiment of the present disclosure;
fig. 6A is a schematic flowchart of another authorization method for an intelligent device according to an embodiment of the present disclosure;
fig. 6B is an interaction diagram of another authorization method for a smart device according to an embodiment of the present disclosure;
fig. 7 is a schematic flowchart of another authorization method for an intelligent device according to an embodiment of the present disclosure;
fig. 8 is a schematic structural diagram of an authorization method and apparatus for an intelligent device according to an embodiment of the present disclosure;
fig. 9 is a schematic structural diagram of an apparatus of another authorization method for an intelligent device according to an embodiment of the present disclosure;
fig. 10 is a schematic structural diagram of an electronic device according to an embodiment of the present disclosure.
Detailed Description
In order that the above objects, features and advantages of the present disclosure may be more clearly understood, aspects of the present disclosure will be further described below. It should be noted that the embodiments and features of the embodiments of the present disclosure may be combined with each other without conflict.
In the following description, numerous specific details are set forth in order to provide a thorough understanding of the present disclosure, but the present disclosure may be practiced in other ways than those described herein; it is to be understood that the embodiments disclosed in the specification are only a few embodiments of the present disclosure, and not all embodiments.
The terms "first" and "second," etc. in this disclosure are used to distinguish between different objects, rather than to describe a particular order of objects. For example, the first processing result, the second processing result, and the like are used to distinguish different processing results, and are not used to describe a specific order of the processing results.
With the continuous development of the smart home system, various smart devices enter the life and work of users, great intelligence and convenience are brought to the life and work of the users, and when the users use the smart devices, the users need to establish the relationship between the control and the control of the smart devices and carry out information interaction between the smart devices. Currently, information interaction between intelligent devices can be realized by using a Message Queue Telemetry Transport (MQTT), which is a client-server based Message publishing/subscription Transport protocol, and for an intelligent device requiring Message interaction, the MQTT serves as a client to connect to an MQTT server, and the MQTT server forwards a Message to a corresponding client (intelligent device) according to publishing or subscription. For example, in the life of a user, a mobile terminal device such as a mobile phone is often used as an analog remote controller for controlling an intelligent device such as a television, so as to control the intelligent device such as the television, then, the mobile terminal device such as the mobile phone is a client of MQTT, and the information interaction between the mobile terminal device such as the mobile phone and the intelligent device such as the television can be realized by connecting the mobile terminal device such as the mobile phone to an MQTT server of the intelligent device such as the television.
However, when the MQTT protocol is used to implement information interaction between the smart devices, in order to ensure the security of the information interaction between the smart devices, it is necessary that the client, that is, the mobile terminal device such as a mobile phone, provides user identification information and a user password, and performs connection based on the user identification information and the user password, but it is impossible to obtain a user intention through this method, and perform authorization on the connected smart device.
However, with the prior art, since the authorization deadline for the controlled device is a permanent deadline specified by the system, or a fixed value is preset by the system, the user cannot change the authorization deadline of the controlled device, and the device information is stored in the white list, which wastes storage resources, and the white list is lost, so that the controlled device needs to be authorized again, which is cumbersome to operate and has low security.
Fig. 1A is a schematic application scenario diagram of an authorization method for an intelligent device according to an embodiment of the present disclosure. In fig. 1A, a mobile smart device, that is, a mobile phone 201, is used as a master device, a display device, that is, a television 200, is used as a controlled device, and when the mobile phone 201 wants to control the display device 200, the display device 200 needs to perform authorized connection authentication on the mobile phone 201, so as to determine whether to allow the mobile phone 201 to control the display device 200.
Fig. 1B is a schematic diagram of an authorization method of an intelligent device provided in the prior art. The method comprises the steps that a master control device sends an authorization connection request to a controlled device, the controlled device responds to the authorization connection request sent by the master control device, a stored white list is consulted, whether information of the master control device, such as device identification, exists in the white list or not is searched, whether the master control device is a trusted device authorized by the controlled device or not is determined, when the information of the master control device is determined to exist in the white list, the master control device is determined to be the trusted device authorized by the controlled device, a message that authorization connection passes is sent to the master control device, the master control device information is stored in the white list, and at the moment, the master control device can control the controlled device after receiving the message that authorization connection passes. However, since authorized main control device information is stored in the white list, storage resources are wasted, and although a user can explicitly authorize the main control device to determine whether to agree that the main control device is a trusted device authorized by the controlled device, the main control device can be authorized only for the first time, and the validity period of the authorization is a permanent period specified by the system, or a fixed value is preset by the system, the user cannot change the authorization period of the controlled device.
Fig. 1C is a schematic diagram of another explicit authorization method provided in the prior art. As shown in fig. 1C, the master device sends an authorization connection request to the controlled device, and the controlled device actively pops up an interface in the controlled device for authorization by the user in response to the authorization connection request, where the interface includes "is the mobile terminal device 1 trying to connect to your television, do you agree with authorization? When the user selects "agree", the controlled device television sends a message that the authorization connection passes to the mobile terminal device 1, and stores the mobile terminal device 1 as the trust device in a white list, and when the user selects "deny", the controlled device television sends a message that the authorization connection fails to the mobile terminal device 1.
In order to solve the problems in the prior art, this embodiment provides an authorization method for an intelligent device, where a first authorization connection request is first sent to a controlled device by a master control device, and the controlled device receives the first authorization connection request sent by the master control device, where the first authorization connection request includes first device information, first user identification information, and a first authorization code, the first authorization code is generated and sent to the master control device according to second device information and a first valid authorization duration after receiving an authorization code acquisition instruction sent by the master control device, the first valid authorization duration is an effective authorization duration for the master control device to control the controlled device, and the controlled device performs verification based on the first device information, the first user identification information, and the first authorization code, and after the verification is determined to be passed, sends a first verification success instruction to the master control device to indicate that the master control device and the controlled device are successfully authorized to connect. In the process, the first device information, the first user identification information and the first authorization code included in the first authorization connection request are verified to determine whether the first authorization connection request of the main control device passes through, so that the inquiry in a white list in the prior art is avoided, and the operation of the trust device for determining whether the main control device is authorized is determined, that is, the authorized main control device does not need to be stored in the white list, so that the resource occupation is reduced, and the security is improved by decrypting the authorization code to perform authorization connection verification.
The authorization method of the intelligent device provided by the embodiment of the disclosure can be implemented based on the electronic device, or a functional module or a functional entity in the electronic device.
The electronic device may be a Personal Computer (PC), a server, a mobile phone, a tablet computer, a notebook computer, a mainframe computer, and the like, which is not specifically limited in this disclosure.
Fig. 2A is a block diagram of a hardware configuration of an electronic device according to one or more embodiments of the present disclosure. As shown in fig. 2A, the electronic apparatus includes: at least one of a tuner demodulator 210, a communicator 220, a detector 230, an external device interface 240, a controller 250, a display 260, an audio output interface 270, a memory, a power supply, and a user interface 280. The controller 250 includes a central processing unit, a video processor, an audio processor, a graphic processor, a RAM, a ROM, a first interface to an nth interface for input/output, among others. The display 260 may be at least one of a liquid crystal display, an OLED display, a touch display, and a projection display, and may also be a projection device and a projection screen. The tuner demodulator 210 receives a broadcast television signal through wired or wireless reception, and demodulates an audio/video signal, such as an EPG audio/video data signal, from a plurality of wireless or wired broadcast television signals. The communicator 220 is a component for communicating with an external device or a server according to various communication protocol types. For example: the communicator may include at least one of a Wifi module, a bluetooth module, a wired ethernet module, and other network communication protocol chips or near field communication protocol chips, and an infrared receiver. The electronic device may establish transmission and reception of control signals and data signals with the server 203 or the local control device 205 through the communicator 220. The detector 230 is used to collect signals of an external environment or interaction with the outside. The controller 250 and the tuner-demodulator 210 may be located in different separate devices, that is, the tuner-demodulator 210 may also be located in an external device of the main device where the controller 250 is located, such as an external set-top box. The user interface 280 may be used to receive control signals for controlling devices, such as infrared remote controls, etc.
In some embodiments, controller 250 controls the operation of the electronic device and responds to user actions through various software control programs stored in memory. The controller 250 controls the overall operation of the electronic device. The user may input a user command through a Graphical User Interface (GUI) displayed on the display 260, and the user input interface receives the user input command through the Graphical User Interface (GUI). Alternatively, the user may input the user command by inputting a specific sound or gesture, and the user input interface receives the user input command by recognizing the sound or gesture through the sensor.
In some embodiments, a "user interface" is a media interface for interaction and information exchange between an application or operating system and a user that enables conversion between an internal form of information and a form that is acceptable to the user. A commonly used presentation form of the User Interface is a Graphical User Interface (GUI), which refers to a User Interface related to computer operation and displayed in a graphical manner. It may be an interface element such as an icon, a window, and a control displayed in a display screen of the electronic device, where the control may include at least one of an icon, a button, a menu, a tab, a text box, a dialog box, a status bar, a navigation bar, a Widget, and other visual interface elements.
Fig. 2B is a schematic software configuration diagram of an electronic device according to one or more embodiments of the present disclosure, and as shown in fig. 2B, the system is divided into four layers, which are, from top to bottom, an Application (Applications) layer (referred to as an "Application layer"), an Application Framework (Application Framework) layer (referred to as a "Framework layer"), an Android runtime (Android runtime) and system library layer (referred to as a "system runtime library layer"), and a kernel layer.
In some embodiments, at least one application program runs in the application program layer, and the application programs may be windows (windows) programs carried by an operating system, system setting programs, clock programs or the like; or may be an application developed by a third party developer. In particular implementations, applications in the application layer include, but are not limited to, the above examples.
In some embodiments, the system runtime layer provides support for the upper layer, i.e., the framework layer, and when the framework layer is used, the android operating system runs the C/C + + library included in the system runtime layer to implement the functions to be implemented by the framework layer.
In some embodiments, the kernel layer is a layer between hardware and software, including at least one of the following drivers: audio drive, display driver, bluetooth drive, camera drive, WIFI drive, USB drive, HDMI drive, sensor drive (like fingerprint sensor, temperature sensor, pressure sensor etc.) and power drive etc..
Fig. 2C is a schematic diagram illustrating an icon control interface display of an application program included in a controlled device (mainly, an intelligent playback device, such as an intelligent television, a digital cinema system, or a video server), according to one or more embodiments of the present disclosure, as shown in fig. 2C, an application layer includes at least one application program that can display a corresponding icon control in a display, for example: the system comprises a live television application icon control, a video on demand VOD application icon control, a media center application icon control, an application center icon control, a game application icon control and the like. The live television application program can provide live television through different signal sources. A video on demand VOD application may provide video from different storage sources. Unlike live television applications, video on demand provides a video display from some storage source. The media center application program can provide various applications for playing multimedia contents. The application program center can provide and store various application programs.
The authorization method of the intelligent device provided by the embodiment of the application can be realized based on the electronic device.
For describing the present solution in more detail, the following description is made in an exemplary manner with reference to fig. 3A, and it is understood that the steps involved in fig. 3A may include more steps or fewer steps in actual implementation, and the order between the steps may also be different, subject to the authorization method that can be applied to the smart device on the controlled device side provided in the embodiment of the present application.
Fig. 3A is a schematic flowchart of an authorization method of an intelligent device according to an embodiment of the present disclosure. Fig. 3B is an interaction schematic diagram of an authorization method for an intelligent device according to an embodiment of the present disclosure, where the embodiment is applied to a controlled device. The method of the embodiment is executed by an authorization method device applied to the intelligent device on the controlled device side, and the authorization method device can be implemented in a hardware/software manner and can be configured in the electronic device. As shown in fig. 3A, the authorization method of the smart device specifically includes the following steps:
s310, receiving a first authorization connection request sent by the main control device.
The first authorization connection request includes first device information, first user identification information, and a first authorization code, where the first authorization code is generated according to second device information and a first valid authorization duration and is sent to the master control device after the controlled device receives an authorization code acquisition instruction sent by the master control device, and the first valid authorization duration is an effective permission duration for the master control device to control the controlled device, that is, an authorization effective duration for the master control device to control the controlled device, which is set according to a user requirement.
The above-mentioned master control device is a device that controls a controlled device in a scene with a plurality of intelligent devices, and the master control device may be, for example, a mobile phone, a tablet computer, an intelligent center control screen, and the like, but is not limited thereto, and the disclosure is not particularly limited. In a scenario where the controlled device is provided with multiple intelligent devices, the controlled device is controlled by the master control device, and the intelligent device may be, for example, a television, a personal computer, a video server, and the like, but is not limited thereto, and the disclosure is not particularly limited.
The first device information refers to information corresponding to the main control device, and the device information may be identification information of the main control device, and is unique information used for representing the main control device, for example, a name of the main control device and a serial number of the main control device, but is not limited thereto. The first user identification information refers to information corresponding to a user using the main control device, and the first user identification information may be a user name, a mobile phone number, a mailbox, and the like, but is not limited thereto. The first authorization code includes device information of the main control device and valid authorization duration, and the first authorization code may be a character string for encryption or an encrypted number string composed of arabic numbers, but is not limited thereto.
Specifically, the master control device sends a first authorized connection request including first device information, first user identification information, and a first authorized code to the controlled device, and the controlled device receives the first authorized connection request.
It should be noted that, the first authorization connection request from the master device to the controlled device is sent based on the MQTT protocol, but is not limited thereto, and the disclosure is not limited in particular.
S320, checking based on the first device information, the first user identification information and the first authorization code, and sending a first checking success instruction to the main control device after the checking is confirmed to be passed.
And the first verification success instruction indicates that the authorized connection between the master control device and the controlled device is successful.
Specifically, after receiving a first authorized connection request sent by the master control device, the controlled device responds to the first authorized connection request, performs verification according to the first device information, the first user identification information, and the first authorization code, and after it is determined that the verification is passed, the controlled device sends a first verification success instruction to the master control device, which indicates that the authorized connection between the master control device and the controlled device is successful, and at this time, after receiving the first verification success instruction sent by the controlled device, the master control device can perform control operation on the controlled device.
In this way, the authorization method for the intelligent device provided in this embodiment includes first sending, by the master device, a first authorization connection request to the controlled device, and receiving, by the controlled device, the first authorization connection request sent by the master device, where the first authorization connection request includes first device information, first user identification information, and a first authorization code, the first authorization code is generated and sent to the master device according to second device information and a first valid authorization duration after receiving an authorization code acquisition instruction sent by the master device, the first valid authorization duration is an effective permission duration for the master device to control the controlled device, and the controlled device performs verification based on the first device information, the first user identification information, and the first authorization code, and after it is determined that the verification is passed, sends a first verification success instruction to the master device, so as to indicate that the master device and the controlled device are successfully authorized to connect. In the process, the first device information, the first user identification information and the first authorization code included in the first authorization connection request are verified to determine whether the first authorization connection request of the main control device passes through, so that the inquiry in a white list in the prior art is avoided, and the operation of the trust device for determining whether the main control device is authorized is determined, that is, the authorized main control device does not need to be stored in the white list, so that the resource occupation is reduced, and the security is improved by decrypting the authorization code to perform authorization connection verification.
Fig. 4A is a schematic flowchart of another authorization method for an intelligent device according to an embodiment of the present disclosure. Fig. 4B is an interaction schematic diagram of another authorization method for an intelligent device provided in the embodiment of the present disclosure, optionally, this embodiment is applied to a controlled device side, and as shown in fig. 4A, before executing receiving a first authorization connection request sent by a master control device, the method further includes the following steps:
s410, receiving a first connection request sent by the main control equipment.
The first connection request comprises second equipment information, second user identification information and a user password. It should be noted that, when the master control device connects the controlled device for the first time, before obtaining the authorization authority for the controlled device, the connection needs to be performed based on the MQTT protocol, and after the connection is successful, the first authorization code is further obtained through the explicit authorization of S430 to S440, so that the master control device can perform the authorization connection directly based on the authorization code, the device information, and the user identification information when connecting the controlled device for the next time.
Specifically, before the master control device sends the first authorized connection request to the controlled device, the master control device sends the first connection request containing the second device information, the second user identification information and the user password to the controlled device by using the MQTT protocol.
And S420, verifying according to the second user identification information and the user password, and after the verification is confirmed to be passed, sending a second verification success instruction to the main control equipment.
And the second verification success instruction indicates that the master control device is successfully connected with the controlled device, and sends the first authorization request to the controlled device.
Specifically, after receiving a first connection request including second device information, second user identification information and a user password sent by the main control device, the controlled device performs verification according to the second user identification information and the user password, and when the second user identification information and the user password are determined to be correct, the verification is passed, and the controlled device sends a second verification success instruction to the main control device to indicate that the main control device and the controlled device are successfully connected. At this time, after receiving the second verification success instruction sent by the controlled device, the master control device determines that the connection between the master control device and the controlled device is successful, and sends the first authorization request to the controlled device, so as to perform an explicit authorization process on the controlled device.
S430, responding to the first authorization request sent by the main control device, authorizing according to the second device information and the first effective authorization duration, and sending a first authorization success instruction to the main control device when the authorization is determined to be successful.
The first authorization success instruction indicates that the authorization of the master control device and the authorization of the controlled device are successful, and sends an authorization code acquisition instruction to the controlled device.
Specifically, after receiving a second successful verification instruction sent by the controlled device, the master control device determines that the connection with the controlled device is successful, the master control device sends a first authorization request to the controlled device, the controlled device receives the first authorization request sent by the master control device, responds to the first authorization request, and performs explicit authorization according to the second device information and the first valid authorization duration, and after the authorization is determined to be successful, the controlled device sends a first successful authorization instruction to the master control device, at this time, the master control device determines that the master control device controls the controlled device to be successfully authorized after receiving the first successful authorization instruction sent by the controlled device, and at this time, the master control device sends an authorization code acquisition instruction to the controlled device.
S440, responding to the authorization code obtaining instruction sent by the main control device, generating a first authorization code based on the second device information and the first effective authorization duration, and sending the first authorization code to the main control device.
Specifically, the controlled device receives an authorization code obtaining instruction sent by the main control device, responds to the authorization code obtaining instruction, generates a first authorization code according to the second device information and the first effective authorization duration by using an encryption algorithm, and sends the first authorization code to the main control device.
In this way, in the authorization method for the intelligent device provided in this embodiment, in the above process, the connection between the main control device and the controlled device is performed based on the MQTT protocol, after the connection is successful, the main control device is further authorized, and after the authorization is successful, the first authorization code is obtained, so that the subsequent user can perform authorization connection based on the first authorization code directly, the security of MQTT connection is ensured, the query in the white list is avoided, and the operation of the trusted device that determines whether the main control device is authorized or not is determined, that is, the authorized main control device does not need to be stored in the white list, so that the resource occupation is reduced, and the security is improved by decrypting the authorization code to perform authorization connection verification.
Fig. 5A is a schematic flowchart of another authorization method for an intelligent device according to an embodiment of the present disclosure, and fig. 5B is an interaction schematic diagram of another authorization method for an intelligent device according to an embodiment of the present disclosure; fig. 5A is a schematic diagram of, on the basis of fig. 4A, checking the first device information, the first user identification information, and the first authorization code, and after it is determined that the checking is passed, sending a first verification success instruction to the main control device to indicate that the authorized connection between the main control device and the controlled device is successful, where an implementation manner of the first verification success instruction is:
s510, the first authorization code is decrypted to obtain second device information and first effective authorization duration.
Since the first authorization code is an encrypted character string or a digital string, in order to obtain information included in the authorization code, the authorization code needs to be decrypted, so as to obtain the second device information and the first valid authorization duration included in the authorization code. The second device information is device information of the main control device that sends the authorization code obtaining instruction to the controlled device, and the device information may be, for example, identification information of the main control device, and unique information used to represent the main control device, such as a name of the main control device and a serial number of the main control device, but is not limited thereto.
S520, calculating a first duration according to a first time when the controlled device generates the first authorization code and a second time when the controlled device decrypts the first authorization code.
The first time is the time when the master control device sends an authorization code obtaining instruction to the controlled device, the controlled device receives the authorization code obtaining instruction and responds to the authorization code obtaining instruction to generate a first authorization code, the first time can be determined according to a built-in clock in the controlled device, and the second time is the time when the controlled device receives a first authorization connection request sent by the master control device and needs to verify the first authorization connection request, that is, the first authorization code needs to be decrypted to obtain information contained in the first authorization code, so that the verification is further performed.
Specifically, a first time when the controlled device generates the first authorization code and a second time when the controlled device decrypts the first authorization code are calculated to obtain the first duration.
For example, with the above embodiment, it is known that the first valid authorization duration is 10 days, that is, 240 hours, if the first time of the controlled device generating the first authorization code is 10 am at 1 month and 1 month in 2022, and the second time of the controlled device decrypting the first authorization code is 10 am at 1 month and 5 months in 2022, the first time and the second time are calculated to obtain the first duration of 96 hours, but the disclosure is not limited thereto, and a person skilled in the art may calculate the first duration according to actual situations.
S530, if the first time length is less than or equal to the first effective authorization time length, the first device information is consistent with the second device information, and the first user identification information is consistent with the second user identification information, the verification is passed, and a first verification success instruction is sent to the main control device.
Specifically, a first time length calculated by the controlled device at a first time when the controlled device generates a first authorization code and a second time when the controlled device decrypts the first authorization code is compared with a first effective authorization time length, the first device information is compared with the second device information, the first user identification information is compared with the second user identification information, when the first time length is determined to be smaller than or equal to the first effective authorization time length and the first device information is consistent with the second device information and the first user identification information is consistent with the second user identification information, the first authorization connection request is determined to be checked to be passed, a first check success instruction is sent to the main control device to indicate that the main control device and the controlled device are authorized to be connected successfully, and at the moment, after the main control device receives the first check success instruction sent by the controlled device, the main control device can control and operate the controlled device.
Therefore, in the authorization method for the intelligent device provided by this embodiment, in the process of verifying the first authorization connection request, querying in the white list is avoided, and an operation of determining whether the main control device is authorized as a trusted device is determined, that is, the authorized main control device does not need to be stored in the white list, so that resource occupation is reduced, and security is improved by decrypting the authorization code to perform authorization connection verification.
Optionally, on the basis of the foregoing embodiments, in some embodiments of the present disclosure, the method further includes:
and step A, when the first time length is longer than the first effective authorization time length, sending a first verification failure instruction to the main control equipment.
Specifically, when the controlled device compares the first time length with the first effective authorization time length, and when it is determined that the first time length is longer than the first effective authorization time length, if the authorization control of the controlled device by the master control device at this time is invalid, the controlled device sends a first verification failure instruction to the master control device, and correspondingly, after receiving the first verification failure instruction sent by the controlled device, the master control device determines that the controlled device at this time cannot perform control operation.
And step B, responding to a first authorization code updating instruction sent by the main control equipment, updating the first authorization code based on the second effective authorization duration to obtain a second authorization code, and sending the second authorization code to the main control equipment.
The first update authorization code instruction refers to an instruction that the master control device sends re-authorization to the controlled device to obtain an authorization code.
Specifically, the master control device determines that authorization control over the controlled device is failed at the moment, sends a first update authorization code instruction to the controlled device, receives and responds to the first update authorization code instruction, performs explicit authorization again on the master control device according to a second valid authorization duration to obtain a second authorization code, and sends the second authorization code to the master control device when receiving an authorization code acquisition instruction sent by the controlled device.
Optionally, for the process of obtaining the second authorization code by authorizing the main control device again based on the first update authorization code instruction, refer to S410-S440 in the above embodiment, which is not described herein again.
In this way, in the authorization method for the intelligent device provided by this embodiment, in the above process, when the main control device receives the first verification failure instruction sent by the controlled device, and determines that the authorization code is invalid, that is, when the main control device cannot control the controlled device, the main control device needs to be further authorized again, so that it is ensured that the main control device can still realize authorized connection to the controlled device based on the authorization code in subsequent use, and the use experience of the user is improved.
Optionally, on the basis of the foregoing embodiments, in some embodiments of the present disclosure, the method further includes:
and step C, responding to a second authorization code updating instruction sent by the main control equipment, updating the first authorization code based on the third effective authorization duration to obtain a third authorization code, and sending the third authorization code to the main control equipment.
The second update authorization code instruction is generated when the first effective authorization duration is permanently effective, that is, when it is determined that the effective authorization duration of the master control device to the controlled device is permanently effective, in order to avoid that the master control device is attacked by a hacker once so that the hacker can control the controlled device all the time, the master control device sends the second update authorization code instruction so that the controlled device deletes the permanently effective authorization control of the master control device, and authorizes the master control device again based on the third effective authorization duration, thereby solving the above problem.
Specifically, the master control device sends a second update authorization code instruction to the controlled device when determining that the valid authorization duration of the controlled device is permanently valid at this time, the controlled device receives and responds to the second update authorization code instruction, performs explicit authorization again on the master control device according to a third valid authorization duration to obtain a third authorization code, and sends the third authorization code to the master control device when receiving an authorization code obtaining instruction sent by the controlled device.
Optionally, for the process of obtaining the third authorization code by authorizing the main control device again based on the second update authorization code instruction, refer to S410-S440 in the above embodiment, which is not described herein again.
In this way, in the authorization method for the intelligent device provided in this embodiment, in the above process, when the main control device determines that the valid authorization duration for the controlled device is permanently valid, in order to avoid that once the main control device is attacked by a hacker, the hacker can always control the controlled device, the main control device sends the second update authorization code instruction, and further, after the controlled device receives the second update authorization code instruction, the main control device is authorized again, so that the security is improved, and the use experience of the user is improved.
Fig. 6A is a flowchart illustrating a method for authorizing an intelligent device according to an embodiment of the present disclosure. Fig. 6B is an interaction schematic diagram of another authorization method for an intelligent device according to an embodiment of the present disclosure, where the embodiment is applied to a master control device side. The method of the embodiment can be executed by an authorization method device applied to the intelligent device, and the device can be implemented in a hardware/software manner and can be configured in the electronic device. As shown in fig. 6A, the method specifically includes the following steps:
s610, sending a first authorization connection request to the controlled device.
The controlled device is verified based on the first device information, the first user identification information and the first authorization code through the first authorization connection request, and after the verification is confirmed to be passed, a first verification success command is sent to the main control device, wherein the first authorization request comprises the first device information, the first user identification information and the first authorization code.
And S620, receiving a first verification success command sent by the controlled device.
And the first verification success instruction indicates that the authorized connection between the master control device and the controlled device is successful.
In this embodiment, the slave master device executes the above S610-S620, and the specific implementation process refers to S310-S320, which is not described herein again.
The authorization method for the intelligent device provided in this embodiment includes first sending, by the master device, a first authorization connection request to the controlled device, and receiving, by the controlled device, the first authorization connection request sent by the master device, where the first authorization connection request includes first device information, first user identification information, and a first authorization code, the first authorization code is generated and sent to the master device according to second device information and a first valid authorization duration after the controlled device receives an authorization code acquisition instruction sent by the master device, the first valid authorization duration is an effective permission duration for the master device to control the controlled device, the master device performs verification based on the first device information, the first user identification information, and the first authorization code, and after it is determined that the verification is passed, sending a first verification success instruction to the master device, so as to indicate that the master device and the controlled device are successfully authorized to connect. In the process, the first device information, the first user identification information and the first authorization code included in the first authorization connection request are verified to determine whether the first authorization connection request of the main control device passes through, so that the inquiry in a white list in the prior art is avoided, and the operation of the trust device for determining whether the main control device is authorized is determined, that is, the authorized main control device does not need to be stored in the white list, so that the resource occupation is reduced, and the security is improved by decrypting the authorization code to perform authorization connection verification.
Fig. 7 is a flowchart illustrating a further authorization method for an intelligent device according to an embodiment of the present disclosure. Fig. 7 is a specific process based on fig. 6A before sending the first authorized connection request to the controlled device is performed. As shown in fig. 7, the method specifically includes the following steps:
s710, sending a first connection request to the controlled device.
The first connection request enables the controlled device to perform verification based on the second user identification information and the user password, after the verification is confirmed to be passed, a second verification success instruction is sent to the main control device, the second verification success instruction indicates that the main control device and the controlled device are successfully connected, and a first authorization request is sent to the controlled device, wherein the first connection request at least comprises the second device information, the second user identification information and the user password.
S720, responding to the second verification success command sent by the controlled device, so as to determine that the connection between the main control device and the controlled device is successful, and sending the first authorization request to the controlled device.
And S730, responding to the first authorization success instruction sent by the controlled device to determine that the authorization between the main control device and the controlled device is successful, and sending an authorization code acquisition instruction to the controlled device.
The authorization code obtaining instruction is used for indicating the controlled device to generate a first authorization code based on the second device information and the first effective authorization duration and sending the first authorization code to the main control device.
And S740, receiving the first authorization code sent by the controlled device.
In this embodiment, the slave master device executes the above S710-S740, and the specific implementation process refers to S410-S440, which is not described herein in detail.
In the authorization method for the intelligent device, in the above process, the connection between the main control device and the controlled device is performed based on the MQTT protocol, after the connection is successful, the main control device is further authorized, and after the authorization is successful, the first authorization code is obtained, so that a subsequent user can perform authorization connection directly based on the first authorization code, the security of MQTT connection is ensured, query in a white list is avoided, and whether the main control device is authorized to trust the operation of the device is determined, that is, the authorized main control device does not need to be stored in the white list, resource occupation is reduced, and the security is further improved by decrypting the authorization code.
Optionally, on the basis of the foregoing embodiments, in some embodiments of the present disclosure, the method further includes:
and D, responding to a first verification failure instruction sent by the controlled device to indicate that the first time length is longer than the first effective authorization time length, sending a first updating authorization code instruction to the controlled device to indicate that the controlled device updates the first authorization code based on the second effective authorization time length to obtain a second authorization code, and sending the second authorization code to the main control device.
And E, receiving a second authorization code sent by the controlled equipment.
In this embodiment, the slave master device executes the steps D to E, and the specific implementation process refers to the steps a to B, which are not described in detail herein.
In this way, in the authorization method for the intelligent device provided by this embodiment, in the above process, when the main control device receives the first verification failure instruction sent by the controlled device, and determines that the authorization code is invalid, that is, when the main control device cannot control the controlled device, the main control device needs to be further authorized again, so that it is ensured that the main control device can still realize authorized connection to the controlled device based on the authorization code in subsequent use, and the use experience of the user is improved.
Optionally, on the basis of the foregoing embodiments, in some embodiments of the present disclosure, the method further includes:
and step F, when the first effective authorization duration is determined to be permanently effective, sending a second updating authorization code instruction to the controlled equipment to instruct the controlled equipment to update the first authorization code based on the third effective authorization duration to obtain a third authorization code, and sending the third authorization code to the main control equipment.
And G, receiving a third authorization code sent by the controlled equipment.
In this embodiment, the slave master device executes the steps F to G, and the specific implementation process refers to step C, which is not described herein in too much detail.
In this way, according to the authorization method for the intelligent device provided by this embodiment, in the foregoing process, when the main control device determines that the effective authorization duration for the controlled device is permanently valid, in order to avoid that once the main control device is attacked by a hacker, the hacker can control the controlled device all the time, the main control device sends the second update authorization code instruction, and further, after the controlled device receives the second update authorization code instruction, the main control device is authorized again, so that the security is improved, and the use experience of the user is improved.
Fig. 8 is a schematic structural diagram of an authorization method and apparatus for an intelligent device according to an embodiment of the present disclosure. The device is applied to the controlled equipment, and the device is configured in the electronic equipment, so that the authorization method applied to the intelligent equipment at the controlled equipment side in any embodiment of the application can be realized. The device specifically comprises the following steps:
a first authorization connection request receiving module 11, configured to receive a first authorization connection request sent by a main control device, where the first authorization connection request includes first device information, first user identification information, and a first authorization code, the first authorization code is generated and sent to the main control device according to second device information and a first valid authorization duration after the controlled device receives an authorization code acquisition instruction sent by the main control device, and the first valid authorization duration is a valid permission duration for the main control device to control the controlled device;
a checking module 12, configured to perform checking based on the first device information, the first user identification information, and the first authorization code, and after it is determined that the checking passes, send a first checking success instruction to the main control device to indicate that the authorized connection between the main control device and the controlled device is successful.
As an optional implementation manner of the embodiment of the present disclosure, the apparatus further includes: a first connection request receiving module, configured to receive a first connection request sent by the master device, where the first connection request includes the second device information, second user identification information, and a user password;
the verification module 12 is further configured to perform verification according to the second user identification information and the user password, and after the verification is determined to be passed, send a second verification success instruction to the main control device to indicate that the main control device and the controlled device are successfully connected, and send a first authorization request to the controlled device;
the authorization module is configured to perform authorization according to the second device information and the first valid authorization duration in response to the first authorization request sent by the master device, send a first authorization success instruction to the master device to indicate that the authorization between the master device and the controlled device is successful when the authorization is determined to be successful, and send the authorization code acquisition instruction to the controlled device;
and the first authorization code generation module is used for responding to the authorization code acquisition instruction sent by the main control device, generating the first authorization code based on the second device information and the first valid authorization duration, and sending the first authorization code to the main control device.
As an optional implementation manner of the embodiment of the present disclosure, the verification module 12 is specifically configured to decrypt the first authorization code to obtain the second device information and the first valid authorization duration;
calculating a first duration according to a first time when the controlled device generates the first authorization code and a second time when the controlled device decrypts the first authorization code;
and if the first time length is less than or equal to the first effective authorization time length, the first device information is consistent with the second device information, and the first user identification information is consistent with the second user identification information, the verification is passed, and a first verification success instruction is sent to the main control device.
As an optional implementation manner of the embodiment of the present disclosure, the apparatus further includes:
a first updating module, configured to send a first verification failure instruction to the master device when the first time length is greater than the first valid authorization time length;
and responding to a first authorization code updating instruction sent by the main control equipment, updating the first authorization code based on a second effective authorization duration to obtain a second authorization code, and sending the second authorization code to the main control equipment.
As an optional implementation manner of the embodiment of the present disclosure, the first update module is further configured to update the first authorization code based on a third valid authorization duration in response to a second update authorization code instruction sent by the main control device, obtain a third authorization code, and send the third authorization code to the main control device, where the second update authorization code instruction is generated when the first valid authorization duration is permanently valid.
The authorization method and apparatus for an intelligent device provided in the embodiments of the present disclosure may execute the authorization method applied to an intelligent device on a controlled device side provided in any embodiments of the present disclosure, have corresponding functional modules and beneficial effects of the execution method, and are not described herein again to avoid repetition.
Fig. 9 is a schematic structural diagram of another authorization method apparatus for an intelligent device according to an embodiment of the present disclosure. The device is applied to the main control equipment, is configured in the electronic equipment, and can realize the authorization method applied to the intelligent equipment at the main control equipment side in any embodiment of the application. The device specifically comprises the following steps:
a first authorization connection request sending module 21, configured to send a first authorization connection request to a controlled device, so that the controlled device performs verification based on first device information, first user identification information, and a first authorization code, and after it is determined that the verification passes, send a first verification success instruction to the main control device, where the first authorization request includes the first device information, the first user identification information, and the first authorization code;
a first verification success instruction receiving module 22, configured to receive the first verification success instruction sent by the controlled device, so as to indicate that the authorization connection between the master control device and the controlled device is successful.
As an optional implementation manner of the embodiment of the present disclosure, the apparatus further includes:
a first connection request sending module, configured to send a first connection request to the controlled device, so that the controlled device performs verification based on second user identification information and a user password, after it is determined that the verification passes, send a second verification success instruction to the main control device, so as to indicate that the main control device and the controlled device are successfully connected, and send a first authorization request to the controlled device, where the first connection request at least includes second device information, the second user identification information, and the user password;
a first authorization request sending module, configured to respond to the second verification success instruction sent by the controlled device, to determine that the connection between the master device and the controlled device is successful, and send a first authorization request to the controlled device;
an authorization code obtaining instruction sending module, configured to respond to a first authorization success instruction sent by the controlled device, to determine that the master device and the controlled device are authorized successfully, and send an authorization code obtaining instruction to the controlled device, so as to instruct the controlled device to generate a first authorization code based on the second device information and a first valid authorization duration, and send the first authorization code to the master device;
and the authorization code receiving module is used for receiving the first authorization code sent by the controlled device.
As an optional implementation manner of the embodiment of the present disclosure, the apparatus further includes:
a second updating module, configured to respond to a first verification failure instruction sent by the controlled device to indicate that a first duration is longer than a first valid authorization duration, send a first updating authorization code instruction to the controlled device to indicate that the controlled device updates the first authorization code based on a second valid authorization duration, obtain a second authorization code, and send the second authorization code to the main control device;
and the authorization code receiving module is further configured to receive the second authorization code sent by the controlled device.
As an optional implementation manner of the embodiment of the present disclosure, the second update module is further configured to, when it is determined that the first valid authorization duration is permanently valid, send a second update authorization code instruction to the controlled device, so as to instruct the controlled device to update the first authorization code based on a third valid authorization duration, obtain a third authorization code, and send the third authorization code to the main control device;
and the authorization code receiving module is further configured to receive the third authorization code sent by the controlled device.
The authorization method device of the intelligent device provided by the embodiment of the disclosure can execute the authorization method of the intelligent device provided by any embodiment of the disclosure, has the corresponding functional modules and beneficial effects of the execution method, and is not repeated here to avoid repetition.
An embodiment of the present disclosure provides an electronic device, including: one or more processors; a storage device for storing one or more programs which, when executed by the one or more processors, cause the one or more processors to implement the method of authorizing a smart device of any of the embodiments of the present disclosure.
Fig. 10 is a schematic structural diagram of an electronic device provided in an embodiment of the present disclosure. As shown in fig. 10, the electronic device includes a processor 1010 and a storage 1020; the number of the processors 1010 in the electronic device may be one or more, and one processor 1010 is taken as an example in fig. 10; the processor 1010 and the storage 1020 in the electronic device may be connected by a bus or other means, and fig. 10 illustrates the connection by the bus as an example.
The storage device 1020, which is a computer-readable storage medium, may be used to store software programs, computer-executable programs, and modules, such as program instructions/modules corresponding to the authorization method of the smart device in the embodiments of the present disclosure. The processor 1010 executes various functional applications and data processing of the electronic device by executing software programs, instructions and modules stored in the storage 1020, so as to implement the authorization method of the smart device provided by the embodiment of the present disclosure.
The storage 1020 may mainly include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application program required for at least one function; the storage data area may store data created according to the use of the terminal, and the like. Further, the storage 1020 may include high speed random access memory and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other non-volatile solid state storage device. In some examples, the storage 1020 may further include memory located remotely from the processor 1010, which may be connected to electronic devices over a network. Examples of such networks include, but are not limited to, the internet, intranets, local area networks, mobile communication networks, and combinations thereof.
The electronic device provided by the embodiment can be used for executing the authorization method of the intelligent device provided by any embodiment, and has corresponding functions and beneficial effects.
The disclosed embodiment provides a computer-readable storage medium, on which a computer program is stored, where the computer program, when executed by a processor, implements each process executed by the authorization method of the intelligent device, and can achieve the same technical effect, and in order to avoid repetition, the details are not repeated here.
The computer-readable storage medium may be a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk.
The foregoing description, for purposes of explanation, has been presented in conjunction with specific embodiments. However, the foregoing discussion in some embodiments is not intended to be exhaustive or to limit the implementations to the precise forms disclosed above. Many modifications and variations are possible in light of the above teaching. The embodiments were chosen and described in order to best explain the principles and the practical application, to thereby enable others skilled in the art to best utilize the embodiments and various embodiments with various modifications as are suited to the particular use contemplated.
Claims (10)
1. An authorization method of an intelligent device is applied to a controlled device, and comprises the following steps:
receiving a first authorization connection request sent by a master control device, wherein the first authorization connection request includes first device information, first user identification information and a first authorization code, the first authorization code is generated and sent to the master control device by the controlled device according to second device information and a first effective authorization duration after receiving an authorization code acquisition instruction sent by the master control device, and the first effective authorization duration is an effective permission duration for the master control device to control the controlled device;
and checking based on the first device information, the first user identification information and the first authorization code, and after the checking is confirmed to pass, sending a first checking success instruction to the main control device to indicate that the main control device and the controlled device are successfully authorized to be connected.
2. The smart device authorization method according to claim 1, characterized in that the method further comprises:
receiving a first connection request sent by the master control device, wherein the first connection request comprises the second device information, second user identification information and a user password;
verifying according to the second user identification information and the user password, after the verification is confirmed to be passed, sending a second verification success instruction to the main control device to indicate that the main control device and the controlled device are successfully connected, and sending a first authorization request to the controlled device;
responding to the first authorization request sent by the main control device, authorizing according to the second device information and the first valid authorization duration, and when the authorization is determined to be successful, sending a first authorization success instruction to the main control device to indicate that the authorization between the main control device and the controlled device is successful, and sending the authorization code acquisition instruction to the controlled device;
and responding to the authorization code acquisition instruction sent by the main control equipment, and generating the first authorization code and sending the first authorization code to the main control equipment based on the second equipment information and the first effective authorization duration.
3. The method according to claim 1, wherein the verifying based on the first device information, the first user identification information, and the first authorization code, and after the verification is determined to be successful, sending a first verification success instruction to the master device includes:
decrypting the first authorization code to obtain the second device information and the first effective authorization duration;
calculating a first duration according to a first time when the controlled device generates the first authorization code and a second time when the controlled device decrypts the first authorization code;
and if the first time length is less than or equal to the first effective authorization time length, the first device information is consistent with the second device information, and the first user identification information is consistent with the second user identification information, the verification is passed, and a first verification success instruction is sent to the main control device.
4. The smart device authorization method according to claim 3, characterized in that the method further comprises:
when the first time length is longer than the first effective authorization time length, sending a first verification failure instruction to the main control equipment;
and responding to a first authorization code updating instruction sent by the main control equipment, updating the first authorization code based on a second effective authorization duration to obtain a second authorization code, and sending the second authorization code to the main control equipment.
5. The smart device authorization method according to claim 1, characterized in that the method further comprises:
and in response to a second update authorization code instruction sent by the main control device, updating the first authorization code based on a third effective authorization duration to obtain a third authorization code, and sending the third authorization code to the main control device, wherein the second update authorization code instruction is generated when the first effective authorization duration is permanently effective.
6. An authorization method of an intelligent device is applied to a main control device, and comprises the following steps:
sending a first authorization connection request to controlled equipment, so that the controlled equipment performs verification based on first equipment information, first user identification information and a first authorization code, and after the verification is determined to be passed, sending a first verification success instruction to the main control equipment, wherein the first authorization request comprises the first equipment information, the first user identification information and the first authorization code;
and receiving the first verification success instruction sent by the controlled device to indicate that the authorized connection between the main control device and the controlled device is successful.
7. The smart device authorization method according to claim 6, characterized in that the method further comprises:
sending a first connection request to the controlled device, so that the controlled device performs verification based on second user identification information and a user password, after the verification is determined to be passed, sending a second verification success instruction to the main control device to indicate that the main control device and the controlled device are successfully connected, and sending a first authorization request to the controlled device, wherein the first connection request at least comprises second device information, the second user identification information and the user password;
responding to the second verification success instruction sent by the controlled equipment to determine that the connection between the main control equipment and the controlled equipment is successful, and sending a first authorization request to the controlled equipment;
responding to a first authorization success instruction sent by the controlled device to determine that the authorization of the main control device and the controlled device is successful, and sending an authorization code acquisition instruction to the controlled device to indicate that the controlled device generates a first authorization code based on the second device information and a first valid authorization duration and sends the first authorization code to the main control device;
and receiving the first authorization code sent by the controlled equipment.
8. The smart device authorization method according to claim 7, characterized in that the method further comprises:
responding to a first verification failure instruction sent by the controlled device to indicate that a first time length is longer than a first effective authorization time length, sending a first updating authorization code instruction to the controlled device to indicate that the controlled device updates the first authorization code based on a second effective authorization time length to obtain a second authorization code, and sending the second authorization code to the main control device;
and receiving the second authorization code sent by the controlled device.
9. The smart device authorization method according to claim 6, characterized in that the method further comprises:
when the first effective authorization duration is determined to be permanently effective, sending a second updating authorization code instruction to the controlled device to indicate the controlled device to update the first authorization code based on a third effective authorization duration to obtain a third authorization code, and sending the third authorization code to the main control device;
and receiving the third authorization code sent by the controlled device.
10. A computer-readable storage medium, on which a computer program is stored, which program, when being executed by a processor, carries out the method of any one of claims 1 to 5 or the method of any one of claims 6 to 9.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202211122586.XA CN115643046A (en) | 2022-09-15 | 2022-09-15 | Authorization method of smart device and computer-readable storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202211122586.XA CN115643046A (en) | 2022-09-15 | 2022-09-15 | Authorization method of smart device and computer-readable storage medium |
Publications (1)
Publication Number | Publication Date |
---|---|
CN115643046A true CN115643046A (en) | 2023-01-24 |
Family
ID=84942871
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202211122586.XA Pending CN115643046A (en) | 2022-09-15 | 2022-09-15 | Authorization method of smart device and computer-readable storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN115643046A (en) |
-
2022
- 2022-09-15 CN CN202211122586.XA patent/CN115643046A/en active Pending
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US10778670B2 (en) | Apparatus and method for secure authentication of a communication device | |
US11669465B1 (en) | Secure storage of data through a multifaceted security scheme | |
US10498723B2 (en) | Method, and apparatus for authenticating access | |
EP3365824B1 (en) | Password-less authentication for access management | |
US9813428B2 (en) | Apparatus and method for securely managing the accessibility to content and applications | |
US9760708B2 (en) | Information processing apparatus, information processing system, information processing method, and program | |
CN109074440B (en) | Configuration for multi-factor event authorization | |
JP6936169B2 (en) | Authenticator management device, authenticator management method, authenticator management program and authenticator management system | |
EP3603014B1 (en) | Methods and systems of performing preemptive generation of second factor authentication | |
CN110115014B (en) | Electronic device, control authority authentication method of electronic device and user terminal device | |
KR20150017844A (en) | Controlling Method For Input Status and Electronic Device supporting the same | |
CN111757422B (en) | Equipment activation method and device, user terminal, equipment to be activated and storage medium | |
KR102242720B1 (en) | An OTP configuration method of setting time seed with unique cycle by using active time offset window per each client | |
US20150074826A1 (en) | Authorization information management system, electronic device and method for managing authorization information | |
WO2018012444A1 (en) | Service providing system, service communicating system, service providing method and recording medium | |
WO2024001257A1 (en) | Display device and processing method for display device | |
CN115643046A (en) | Authorization method of smart device and computer-readable storage medium | |
JP2017183930A (en) | Server management system, server device, server management method, and program | |
KR20200053752A (en) | Providing Method of Autofill function and electric device including the same | |
WO2017170235A1 (en) | Service provision system, service delivery system, service provision method, and program | |
WO2017170237A1 (en) | Service providing system, serving receiving system, service providing method and program | |
CN115459903A (en) | Access authentication method and device of equipment and electronic equipment | |
JP6638808B2 (en) | Service providing system, service giving / receiving system, service providing method, and program | |
CN113301432B (en) | Display device, terminal device and communication connection method | |
CN117650903A (en) | Controlled device, device authorization management method, 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 |