CN113918343A - Authentication method, authentication device, electronic equipment, storage medium and computer program product - Google Patents
Authentication method, authentication device, electronic equipment, storage medium and computer program product Download PDFInfo
- Publication number
- CN113918343A CN113918343A CN202111261584.4A CN202111261584A CN113918343A CN 113918343 A CN113918343 A CN 113918343A CN 202111261584 A CN202111261584 A CN 202111261584A CN 113918343 A CN113918343 A CN 113918343A
- Authority
- CN
- China
- Prior art keywords
- party application
- service process
- multimedia service
- authentication
- authentication result
- 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
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
- G06F9/46—Multiprogramming arrangements
- G06F9/50—Allocation of resources, e.g. of the central processing unit [CPU]
- G06F9/5005—Allocation of resources, e.g. of the central processing unit [CPU] to service a request
- G06F9/5027—Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resource being a machine, e.g. CPUs, Servers, Terminals
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
- G06F9/46—Multiprogramming arrangements
- G06F9/54—Interprogram communication
- G06F9/546—Message passing systems or structures, e.g. queues
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
- G06F9/46—Multiprogramming arrangements
- G06F9/54—Interprogram communication
- G06F9/547—Remote procedure calls [RPC]; Web services
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F2209/00—Indexing scheme relating to G06F9/00
- G06F2209/54—Indexing scheme relating to G06F9/54
- G06F2209/548—Queue
Landscapes
- Engineering & Computer Science (AREA)
- Software Systems (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Telephonic Communication Services (AREA)
Abstract
The application relates to an authentication method, an authentication device, an electronic device, a storage medium and a computer program product. The method comprises the following steps: the third-party application acquires multimedia capability provided by an operating system of the electronic equipment; the third party application calls the multimedia service process to authenticate the third party application; and if the authentication result of the multimedia service process for authenticating the third-party application is that the authentication is passed, the operating system continues to provide the multimedia capability for the third-party application. The method can provide a safe and quick authentication scheme.
Description
Technical Field
The present application relates to the field of authentication technologies, and in particular, to an authentication method, an authentication apparatus, an electronic device, a storage medium, and a computer program product.
Background
Along with the popularization and application of electronic equipment, the electronic equipment can support more and more applications and has more and more powerful functions, and becomes an indispensable electronic product in the life of users.
At present, manufacturers of electronic devices make more investment and innovation for image processing, including hardware, software, algorithms and effects. However, these efforts have many customized contents and are only available to applications developed by vendors. In order to make more third party applications available to these efforts, a secure and fast authentication scheme is first devised.
Disclosure of Invention
In view of the foregoing, it is desirable to provide a secure and fast authentication method, apparatus, electronic device, storage medium and computer program product for solving the above technical problems.
In a first aspect, the present application provides an authentication method for use in an electronic device, where the electronic device includes a third-party application and a multimedia service process resident by an operating system, and the method includes:
the method comprises the steps that a third-party application obtains multimedia capability provided by an operating system of the electronic equipment;
the third party application calls a multimedia service process to authenticate the third party application;
and if the authentication result of the multimedia service process for authenticating the third-party application is that the authentication is passed, the operating system continues to provide the multimedia capability for the third-party application.
In one embodiment, the third party application invoking the multimedia service process to authenticate the third party application includes:
the third party application calls a multimedia service process;
searching a history authentication result of the third-party application in a pre-established cache queue by the multimedia service process;
and if the historical authentication result does not exist, the multimedia service process authenticates the third-party application.
In one embodiment, if there is no historical authentication result, after the multimedia service process authenticates the third-party application, the method further includes:
and the multimedia service process correspondingly stores the authentication result and the application identifier of the third-party application in a cache queue.
In one embodiment, the method further comprises:
and if the historical authentication result exists, taking the historical authentication result as the authentication result of the multimedia service process for authenticating the third-party application.
In one embodiment, if the history authentication result exists, the using, by the multimedia service process, the history authentication result as the authentication result for the multimedia service process to authenticate the third-party application includes:
if the historical authentication result exists, the multimedia service process carries out validity check on the historical authentication result;
and if the validity check is passed, taking the historical authentication result as an authentication result of the multimedia service process for authenticating the third-party application.
In one embodiment, the method further comprises:
and if the validity check is not passed, re-authenticating the third-party application by the multimedia service process, and taking an authentication result obtained by re-authentication as an authentication result of the authentication of the third-party application by the multimedia service process.
In one embodiment, the verifying the validity of the historical authentication result by the multimedia service process includes:
the multimedia service process determines whether the authentication code of the third party application is within the validity period;
and if the authentication code applied by the third party is in the valid period, determining that the validity check is passed.
In one embodiment, the operating system is an android system, and before the multimedia service process searches a cache queue created in advance for a historical authentication result of a third-party application, the method further includes:
the multimedia service process acquires the binder through the acquisition service interface so as to establish process communication between the third-party application and the multimedia service process based on the binder.
In a second aspect, the present application further provides an authentication apparatus for use in an electronic device, where the electronic device includes a third-party application and a multimedia service process resident by an operating system, and the apparatus includes:
the first capability acquisition module is used for acquiring multimedia capability provided by an operating system of the electronic equipment by a third-party application;
the authentication module is used for the third-party application to call the multimedia service process to authenticate the third-party application;
and the second capability obtaining module is used for continuing to provide the multimedia capability for the third-party application by the operating system if the authentication result of the authentication of the third-party application by the multimedia service process is that the authentication is passed.
In one embodiment, the authentication module is specifically configured to invoke a multimedia service process by a third-party application; searching a history authentication result of the third-party application in a pre-established cache queue by the multimedia service process; and if the historical authentication result does not exist, the multimedia service process authenticates the third-party application.
In one embodiment, the apparatus further comprises:
and the storage module is used for correspondingly storing the authentication result and the application identifier of the third-party application in the cache queue by the multimedia service process.
In one embodiment, the authentication module is further configured to use the historical authentication result as an authentication result for authenticating the third-party application by the multimedia service process if the historical authentication result exists.
In one embodiment, the authentication module is specifically configured to, if a historical authentication result exists, perform validity check on the historical authentication result by the multimedia service process; and if the validity check is passed, taking the historical authentication result as an authentication result of the multimedia service process for authenticating the third-party application.
In one embodiment, the authentication module is further configured to re-authenticate the third-party application by the multimedia service process if the validity check fails, and use an authentication result obtained by re-authentication as an authentication result of the multimedia service process for authenticating the third-party application.
In one embodiment, the authentication module is specifically configured to determine whether an authentication code of a third-party application is within a validity period by a multimedia service process; and if the authentication code applied by the third party is in the valid period, determining that the validity check is passed.
In one embodiment, the operating system is an android system, and the authentication module is further configured to enable the multimedia service process to acquire the binder through the acquisition service interface, so as to establish process communication between the third-party application and the multimedia service process based on the binder.
In a third aspect, the present application further provides an electronic device, which includes a memory and a processor, where the memory stores a computer program, and the processor implements the following steps when executing the computer program:
the method comprises the steps that a third-party application obtains multimedia capability provided by an operating system of the electronic equipment;
the third party application calls a multimedia service process to authenticate the third party application;
and if the authentication result of the multimedia service process for authenticating the third-party application is that the authentication is passed, the operating system continues to provide the multimedia capability for the third-party application.
In a fourth aspect, the present application further provides a computer-readable storage medium. The computer-readable storage medium having stored thereon a computer program which, when executed by a processor, performs the steps of:
the method comprises the steps that a third-party application obtains multimedia capability provided by an operating system of the electronic equipment;
the third party application calls a multimedia service process to authenticate the third party application;
and if the authentication result of the multimedia service process for authenticating the third-party application is that the authentication is passed, the operating system continues to provide the multimedia capability for the third-party application.
In a fifth aspect, the present application further provides a computer program product. The computer program product comprising a computer program which when executed by a processor performs the steps of:
the method comprises the steps that a third-party application obtains multimedia capability provided by an operating system of the electronic equipment;
the third party application calls a multimedia service process to authenticate the third party application;
and if the authentication result of the multimedia service process for authenticating the third-party application is that the authentication is passed, the operating system continues to provide the multimedia capability for the third-party application.
According to the authentication method, the authentication device, the electronic equipment, the storage medium and the computer program product, the third-party application acquires the multimedia capability provided by the operating system of the electronic equipment; the third party application calls a multimedia service process to authenticate the third party application; and if the authentication result of the multimedia service process for authenticating the third-party application is that the authentication is passed, the operating system continues to provide the multimedia capability for the third-party application. In the embodiment of the application, because the multimedia service process is a resident process in the operating system, the authentication of the third-party application is performed by using the multimedia service process, so that the process creation time and the memory resource can be saved, and the authentication scheme is safe and quick.
Drawings
FIG. 1 is a flow diagram illustrating an authentication method in one embodiment;
FIG. 2 is a schematic flow chart illustrating the steps of authenticating a third party application in one embodiment;
FIG. 3 is a second flowchart illustrating the authentication procedure for the third party application according to an embodiment;
FIG. 4 is a third flowchart illustrating the authentication procedure for the third party application in one embodiment;
FIG. 5 is a flowchart illustrating steps of using a historical authentication result as an authentication result for authenticating a third party application by a multimedia service process in one embodiment;
FIG. 6 is a second flowchart illustrating the step of authenticating the third party application using the historical authentication result as the authentication result of the multimedia service process in one embodiment;
FIG. 7 is a fourth flowchart illustrating the authentication procedure for the third party application in one embodiment;
FIG. 8a is a flowchart illustrating an authentication method according to another embodiment;
FIG. 8b is a second flowchart illustrating an authentication method according to another embodiment;
FIG. 9 is a block diagram showing the structure of an authentication apparatus according to an embodiment;
FIG. 10 is a second block diagram of the authentication device according to an embodiment;
FIG. 11 is a diagram illustrating the internal architecture of an electronic device in one embodiment.
Detailed Description
In order to make the objects, technical solutions and advantages of the present application more apparent, the present application is described in further detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the present application and are not intended to limit the present application.
First, before specifically describing the technical solution of the embodiment of the present application, a technical background on which the embodiment of the present application is based is described. At present, manufacturers of electronic devices make more investment and innovation for image processing, including hardware, software, algorithms and effects. However, these efforts have many customized contents and are only available to applications developed by vendors. In order to make more third-party applications capable of using the achievements, designing a safe and fast authentication scheme becomes a problem to be solved urgently.
The technical scheme provided by the embodiment of the application is used in the electronic equipment, and the electronic equipment comprises a third-party application and a resident multimedia service process of an operating system. In the process of using the electronic equipment, the third-party application acquires the multimedia capability provided by the operating system of the electronic equipment; the third party application calls a multimedia service process to authenticate the third party application; and if the authentication result of the multimedia service process for authenticating the third-party application is that the authentication is passed, the operating system continues to provide the multimedia capability for the third-party application. Because the multimedia service process is a resident process in the operating system and can be established after the electronic equipment is started, the multimedia service process is used for authentication, the process establishing time and the memory resource can be saved, and a safe and rapid authentication scheme is provided.
In one embodiment, as shown in fig. 1, an authentication method is provided, which is exemplified by the application of the method to an electronic device, which may be, but is not limited to, various personal computers, laptops, smartphones, tablets, internet of things devices, and portable wearable devices. The electronic device comprises a third-party application and a resident multimedia service process of an operating system, and the embodiment of the application can comprise the following steps:
The third party application calls a multimedia interface provided by the operating system first, calls a multimedia development kit through the multimedia interface, and then calls a multimedia service process and a multimedia hardware abstraction process to acquire the multimedia capability provided by the operating system.
Taking the multimedia service process as the camera service process as an example, the third-party application may call the camera unit interface (CameraUnit API) first, and then call the camera unit development kit (CameraUnit SDK); thereafter, the Camera unit development kit calls a Camera service process (Camera Server) and a Camera hardware abstraction process (Camera HAL), thereby acquiring Camera capabilities. For example, the image processing capability of the camera such as beauty, filter, anti-shake is obtained.
The multimedia service process may include a camera service process, an audio and video coding service process, and the like, which is not limited in this embodiment of the present application.
And the third party application acquires the multimedia capability and calls a multimedia service process to authenticate the third party application. Still taking the multimedia service process as the camera service process as an example, the third party application calls the camera service process to authenticate the third party application.
In the prior art, it is common to create a separate authentication process by which third party applications are authenticated. In some cases, for example, when the third-party application is a large application, the third-party application is started, a load of a Central Processing Unit (CPU) in the electronic device may be high, and time consumed for the authentication process to wait for respective resources of the CPU and perform authentication is long, which affects a starting speed of the third-party application.
In the embodiment of the application, the multimedia service process is used for authentication, and the electronic equipment is established to provide the multimedia service when being started up because the multimedia service process is a resident process in the operating system, so that the process establishing time and the memory resource can be saved, and the authentication speed and the starting speed of the third-party application can be improved.
And the multimedia service process authenticates the third-party application to obtain an authentication result, if the authentication result is that the authentication is passed, the electronic equipment indicates that the third-party application allows the multimedia capability to be used, the data corresponding to the multimedia capability is fed back to the third-party application, and the third-party application can continuously acquire the multimedia capability. If the authentication result is that the authentication is not passed, the electronic device indicates that the third-party application is not allowed to use the multimedia capability, data corresponding to the multimedia capability is not fed back to the third-party application, and the third-party application cannot continue to acquire the multimedia capability. It can be understood that, under the condition that the authentication is passed, the third-party application can continue to use the multimedia capability, and the safety of the electronic device can be ensured.
Taking the multimedia service process as the camera service process as an example, if the camera service process determines that the authentication result is that the authentication is passed, the third party application can continue to acquire the camera capability.
In the authentication method, a third party application acquires multimedia capability provided by an operating system of the electronic equipment; the third party application calls a multimedia service process to authenticate the third party application; and if the authentication result of the multimedia service process for authenticating the third-party application is that the authentication is passed, the operating system continues to provide the multimedia capability for the third-party application. In the embodiment of the application, because the multimedia service process is a resident process in the operating system, the authentication of the third-party application is performed by using the multimedia service process, so that the process creation time and the memory resource can be saved, and the authentication scheme is safe and quick.
In an embodiment, as shown in fig. 2, the process of the third party application invoking the multimedia service process to authenticate the third party application may include the following steps:
in step 201, a third party application invokes a multimedia service process.
After the authentication is started, the third-party application invokes the multimedia service process, and referring to the foregoing embodiment, the invoking process may include: the multimedia interface is called first, the multimedia development kit is called through the multimedia interface, and then the multimedia service process is called through the multimedia development kit. The calling process is not limited in the embodiment of the application.
A cache queue is created in the electronic equipment in advance, and when the multimedia service process authenticates the third-party application, the historical authentication result of the third-party application is searched from the cache queue. Specifically, the third-party application transmits the application identifier to the multimedia service process, and the multimedia service process searches the history authentication result of the third-party application in the cache queue according to the application identifier of the third-party application.
And if the historical authentication result of the third-party application does not exist in the cache queue, the multimedia service process does not authenticate the third-party application in the historical period, or the historical authentication result of the third-party application is eliminated from the cache queue, the multimedia service process authenticates the third-party application. In particular, the third party application may pass the authentication code to the multimedia service process, which authenticates according to the authentication code. The embodiment of the present application does not limit this.
In the above embodiment, the third party application invokes the multimedia service process; searching a history authentication result of the third-party application in a pre-established cache queue by the multimedia service process; and if the historical authentication result does not exist, the multimedia service process authenticates the third-party application. By the embodiment of the application, the cache queue is used for authentication, so that the authentication time can be saved, and the authentication speed and the starting speed of third-party application can be improved.
As shown in fig. 3, on the basis of the above embodiment, the embodiment of the present application may further include:
The multimedia service process authenticates the third-party application to obtain an authentication result; and then, correspondingly storing the authentication result and the application identifier of the third-party application into a cache queue, so that the authentication result corresponding to the third-party application can be searched from the cache queue when the third-party application is authenticated subsequently.
It can be understood that the electronic device authenticates the third-party application once after being powered on, then stores the authentication result in the cache queue, and then can acquire the authentication result from the cache queue, thereby greatly saving the authentication time.
As shown in fig. 4, on the basis of the above embodiment, the embodiment of the present application may further include:
In the process of authenticating the third-party application by the multimedia service process, if the historical authentication result of the third-party application is found from the cache queue, the historical authentication result can be used as the authentication result of the multimedia service process for authenticating the third-party application.
It can be understood that, if the history authentication result of the third-party application exists in the cache queue, which indicates that the third-party application is authenticated, the history authentication result searched from the cache queue is used as the authentication result instead of performing authentication, so that the authentication time can be saved, and the authentication speed can be increased.
In an embodiment, as shown in fig. 5, the above-mentioned process of using the historical authentication result as the authentication result for authenticating the third-party application by the multimedia service process if the historical authentication result exists may further include the following steps:
After the multimedia service process finds the historical authentication result from the buffer queue, the multimedia service process may also check whether the historical authentication result is valid, and if so, execute step 2052.
In one embodiment, the process of checking the historical authentication result by the multimedia service process may include: the multimedia service process determines whether the authentication code of the third party application is within the validity period; and if the authentication code applied by the third party is in the valid period, determining that the validity check is passed.
In practical applications, the authentication code may carry an effective time, and the multimedia service process compares the effective time with the current time to determine whether the authentication code is within the effective period. For example, the validity time carried by the authentication code is valid 11/1/2022, and if the current time is 31/10/2021, the multimedia service process determines that the authentication code is within the validity period and determines that the validity check is passed. If the current time is 2021, 11, month, and 2, the multimedia service process determines that the authentication code is not within the validity period and determines that the validity check fails.
The process of verifying the historical authentication result by the multimedia service process may further include: determining whether a revocation authentication has been applied to the third party; if the authentication is not cancelled, determining that the validity check is passed; and if the authentication is cancelled, determining that the validity check fails.
In practical applications, the way of revoking the authentication of the third-party application may include: upgrading and canceling authentication through the configuration file; revocation of authentication by the remote server; the authentication is revoked through the user's system settings. The embodiment of the present application does not limit the way of revocation authentication.
And step 2052, if the validity check is passed, taking the historical authentication result as an authentication result of the multimedia service process for authenticating the third-party application.
As shown in fig. 6, on the basis of the above embodiment, the embodiment of the present application may further include:
and step 2053, if the validity check fails, the multimedia service process re-authenticates the third-party application, and takes the authentication result obtained by re-authentication as the authentication result of the multimedia service process for authenticating the third-party application.
If the validity check of the historical authentication result fails, the multimedia service process can re-authenticate according to the authentication code of the third-party application, and the authentication result obtained by re-authentication is used as the authentication result of the multimedia service process for authenticating the third-party application.
In one embodiment, after obtaining the authentication result, the multimedia service process may also feed back the authentication result to the third-party application, so that the third-party application may perform corresponding processing.
For example, the authentication result that passes the authentication is fed back to the third party application, and the third party application continues to acquire the multimedia capability according to the authentication result. And feeding back the authentication result which fails to pass the authentication to the third party application, wherein the third party application can output prompt information which does not allow the third party application to be used according to the authentication result, and can also acquire the authentication code again, call the multimedia service process to re-authenticate and the like. The embodiment of the present application does not limit the processing of the third-party application.
In the above embodiment, if the historical authentication result exists, the multimedia service process performs validity check on the historical authentication result; if the validity check is passed, taking the historical authentication result as an authentication result of the multimedia service process for authenticating the third-party application; and if the validity check is not passed, re-authenticating the third-party application by the multimedia service process, and taking an authentication result obtained by re-authentication as an authentication result of the authentication of the third-party application by the multimedia service process. In the embodiment of the application, the safety of the authentication result can be ensured by checking the validity of the historical authentication result, so that a safe and effective authentication scheme is provided.
In an embodiment, the operating system is an android system, as shown in fig. 7, before the multimedia service process searches a cache queue created in advance for a historical authentication result of the third-party application, the embodiment of the present application further includes the following steps:
in step 206, the multimedia service process obtains the binder through the obtaining service interface, so as to establish process communication between the third-party application and the multimedia service process based on the binder.
Since the multimedia service process is a resident process of the operating system, it is created when the electronic device is powered on, i.e., the binder is obtained after the electronic device is powered on. Thereafter, upon authenticating the third-party application, the multimedia service process may obtain the binder via an obtain service (getService) interface, thereby establishing process communication between the third-party application and the multimedia service process based on the binder.
And then, the third-party application can call the multimedia service process to authenticate the third-party application through the process communication, and the multimedia service process can also feed back an authentication result to the third-party application through the process communication.
In the above embodiment, the multimedia service process acquires the binder through the acquisition service interface, so as to establish process communication between the third-party application and the multimedia service process based on the binder. In the embodiment of the application, because the multimedia service process is a resident process in the operating system, the binder can be quickly acquired through the acquisition service interface, so that the authentication time is greatly reduced, and the authentication speed is improved.
In one embodiment, as shown in fig. 8a and 8b, an authentication method is provided, and the embodiment of the present application is exemplified by applying the method to an electronic device, where the electronic device includes a third-party application and an operating system resident multimedia service process, and the method may include the following steps:
in step 301, a third party application obtains multimedia capabilities provided by an operating system of an electronic device.
In step 302, the third party application invokes a multimedia service process.
And step 306, if the validity check is passed, taking the historical authentication result as an authentication result of the multimedia service process for authenticating the third-party application.
And 307, if the validity check fails, re-authenticating the third-party application by the multimedia service process, and taking an authentication result obtained by re-authentication as an authentication result of the authentication of the third-party application by the multimedia service process.
In step 310, if the authentication result of the multimedia service process for authenticating the third-party application is that the authentication is passed, the operating system continues to provide the multimedia capability to the third-party application.
In the embodiment, after the third-party application acquires the multimedia capability, the multimedia service process is called for authentication, the electronic equipment is established after being started up because the multimedia service process is a resident process of an operating system, and the multimedia service process quickly acquires the binder through the acquisition service interface, so that the authentication time is shortened, and the authentication speed is increased; and because the multimedia service process is multiplexed, an authentication process does not need to be newly established, the process creation time can be reduced, and the authentication speed is further improved.
It should be understood that, although the steps in the flowcharts related to the embodiments as described above are sequentially displayed as indicated by arrows, the steps are not necessarily performed sequentially as indicated by the arrows. The steps are not performed in the exact order shown and described, and may be performed in other orders, unless explicitly stated otherwise. Moreover, at least a part of the steps in the flowcharts related to the embodiments described above may include multiple steps or multiple stages, which are not necessarily performed at the same time, but may be performed at different times, and the execution order of the steps or stages is not necessarily sequential, but may be rotated or alternated with other steps or at least a part of the steps or stages in other steps.
Based on the same inventive concept, the embodiment of the present application further provides an authentication device for implementing the above-mentioned authentication method. The implementation scheme for solving the problem provided by the device is similar to the implementation scheme recorded in the method, so the specific limitations in one or more embodiments of the authentication device provided below can refer to the limitations on the authentication method in the above, and are not described herein again.
In one embodiment, as shown in fig. 9, there is provided an authentication apparatus for use in an electronic device, the electronic device including a third-party application and an operating system resident multimedia service process, the apparatus including:
a first capability obtaining module 401, configured to obtain, by a third-party application, a multimedia capability provided by an operating system of the electronic device;
an authentication module 402, configured to invoke a multimedia service process by a third-party application to authenticate the third-party application;
a second capability obtaining module 403, configured to, if the authentication result obtained by authenticating the third-party application by the multimedia service process is that the authentication is passed, continue to provide the multimedia capability to the third-party application by the operating system.
In one embodiment, the authentication module 402 is specifically configured to invoke a multimedia service process by a third-party application; searching a history authentication result of the third-party application in a pre-established cache queue by the multimedia service process; and if the historical authentication result does not exist, the multimedia service process authenticates the third-party application.
In one embodiment, as shown in fig. 10, the apparatus further comprises:
the storage module 404 is configured to store the authentication result and the application identifier of the third-party application in the cache queue by the multimedia service process.
In one embodiment, the authentication module 402 is further configured to use the historical authentication result as an authentication result for authenticating the third-party application by the multimedia service process if the historical authentication result exists.
In one embodiment, the authentication module 402 is specifically configured to, if a historical authentication result exists, perform validity check on the historical authentication result by the multimedia service process; and if the validity check is passed, taking the historical authentication result as an authentication result of the multimedia service process for authenticating the third-party application.
In one embodiment, the authentication module 402 is further configured to re-authenticate the third-party application by the multimedia service process if the validity check fails, and use an authentication result obtained by re-authentication as an authentication result of the multimedia service process for authenticating the third-party application.
In one embodiment, the authentication module 402 is specifically configured to determine whether an authentication code of a third-party application is within a validity period by the multimedia service process; and if the authentication code applied by the third party is in the valid period, determining that the validity check is passed.
In one embodiment, the operating system is an android system, and the authentication module 402 is further configured to enable the multimedia service process to acquire a binder through the acquisition service interface, so as to establish process communication between the third-party application and the multimedia service process based on the binder.
The modules in the authentication device can be wholly or partially implemented by software, hardware and a combination thereof. The modules can be embedded in a hardware form or independent of a processor in the electronic device, or can be stored in a memory in the electronic device in a software form, so that the processor can call and execute operations corresponding to the modules.
In one embodiment, an electronic device is provided, which may be a terminal, and its internal structure diagram may be as shown in fig. 11. The electronic device comprises a processor, a memory, a communication interface, a display screen and an input device which are connected through a system bus. Wherein the processor of the electronic device is configured to provide computing and control capabilities. The memory of the electronic equipment comprises a nonvolatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of an operating system and computer programs in the non-volatile storage medium. The communication interface of the electronic device is used for carrying out wired or wireless communication with an external terminal, and the wireless communication can be realized through WIFI, a mobile cellular network, NFC (near field communication) or other technologies. The computer program is executed by a processor to implement an authentication method. The display screen of the electronic equipment can be a liquid crystal display screen or an electronic ink display screen, and the input device of the electronic equipment can be a touch layer covered on the display screen, a key, a track ball or a touch pad arranged on the shell of the electronic equipment, an external keyboard, a touch pad or a mouse and the like.
Those skilled in the art will appreciate that the architecture shown in fig. 11 is a block diagram of only a portion of the architecture associated with the subject application, and does not constitute a limitation on the electronic devices to which the subject application may be applied, and that a particular electronic device may include more or less components than those shown, or may combine certain components, or have a different arrangement of components.
In one embodiment, an electronic device is provided, comprising a memory and a processor, the memory having a computer program stored therein, the processor implementing the following steps when executing the computer program:
the method comprises the steps that a third-party application obtains multimedia capability provided by an operating system of the electronic equipment;
the third party application calls a multimedia service process to authenticate the third party application;
and if the authentication result of the multimedia service process for authenticating the third-party application is that the authentication is passed, the operating system continues to provide the multimedia capability for the third-party application.
In one embodiment, the processor, when executing the computer program, performs the steps of:
the third party application calls a multimedia service process;
searching a history authentication result of the third-party application in a pre-established cache queue by the multimedia service process;
and if the historical authentication result does not exist, the multimedia service process authenticates the third-party application.
In one embodiment, the processor, when executing the computer program, performs the steps of:
and the multimedia service process correspondingly stores the authentication result and the application identifier of the third-party application in a cache queue.
In one embodiment, the processor, when executing the computer program, performs the steps of:
and if the historical authentication result exists, taking the historical authentication result as the authentication result of the multimedia service process for authenticating the third-party application.
In one embodiment, the processor, when executing the computer program, performs the steps of:
if the historical authentication result exists, the multimedia service process carries out validity check on the historical authentication result;
and if the validity check is passed, taking the historical authentication result as an authentication result of the multimedia service process for authenticating the third-party application.
In one embodiment, the processor, when executing the computer program, performs the steps of:
and if the validity check is not passed, re-authenticating the third-party application by the multimedia service process, and taking an authentication result obtained by re-authentication as an authentication result of the authentication of the third-party application by the multimedia service process.
In one embodiment, the processor, when executing the computer program, performs the steps of:
the multimedia service process determines whether the authentication code of the third party application is within the validity period;
and if the authentication code applied by the third party is in the valid period, determining that the validity check is passed.
In one embodiment, the operating system is an android system, and the processor, when executing the computer program, implements the following steps:
the multimedia service process acquires the binder through the acquisition service interface so as to establish process communication between the third-party application and the multimedia service process based on the binder.
In one embodiment, a computer-readable storage medium is provided, having a computer program stored thereon, which when executed by a processor, performs the steps of:
the method comprises the steps that a third-party application obtains multimedia capability provided by an operating system of the electronic equipment;
the third party application calls a multimedia service process to authenticate the third party application;
and if the authentication result of the multimedia service process for authenticating the feedback of the third-party application is that the authentication is passed, the operating system continues to provide the multimedia capability for the third-party application.
In one embodiment, the computer program when executed by the processor further performs the steps of:
the third party application calls a multimedia service process;
searching a history authentication result of the third-party application in a pre-established cache queue by the multimedia service process;
and if the historical authentication result does not exist, the multimedia service process authenticates the third-party application.
In one embodiment, the computer program when executed by the processor further performs the steps of:
and the multimedia service process correspondingly stores the authentication result and the application identifier of the third-party application in a cache queue.
In one embodiment, the computer program when executed by the processor further performs the steps of:
and if the historical authentication result exists, taking the historical authentication result as the authentication result of the multimedia service process for authenticating the third-party application.
In one embodiment, the computer program when executed by the processor further performs the steps of:
if the historical authentication result exists, the multimedia service process carries out validity check on the historical authentication result;
and if the validity check is passed, taking the historical authentication result as an authentication result of the multimedia service process for authenticating the third-party application.
In one embodiment, the computer program when executed by the processor further performs the steps of:
and if the validity check is not passed, re-authenticating the third-party application by the multimedia service process, and taking an authentication result obtained by re-authentication as an authentication result of the authentication of the third-party application by the multimedia service process.
In one embodiment, the computer program when executed by the processor further performs the steps of:
the multimedia service process determines whether the authentication code of the third party application is within the validity period;
and if the authentication code applied by the third party is in the valid period, determining that the validity check is passed.
In one embodiment, the operating system is an android system, and the computer program when executed by the processor further performs the steps of:
the multimedia service process acquires the binder through the acquisition service interface so as to establish process communication between the third-party application and the multimedia service process based on the binder.
In one embodiment, a computer program product is provided, comprising a computer program which, when executed by a processor, performs the steps of:
the method comprises the steps that a third-party application obtains multimedia capability provided by an operating system of the electronic equipment;
the third party application calls a multimedia service process to authenticate the third party application;
and if the authentication result of the multimedia service process for authenticating the third-party application is that the authentication is passed, the operating system continues to provide the multimedia capability for the third-party application.
In one embodiment, the computer program when executed by the processor further performs the steps of:
the third party application calls a multimedia service process;
searching a history authentication result of the third-party application in a pre-established cache queue by the multimedia service process;
and if the historical authentication result does not exist, the multimedia service process authenticates the third-party application.
In one embodiment, the computer program when executed by the processor further performs the steps of:
and the multimedia service process correspondingly stores the authentication result and the application identifier of the third-party application in a cache queue.
In one embodiment, the computer program when executed by the processor further performs the steps of:
and if the historical authentication result exists, taking the historical authentication result as the authentication result of the multimedia service process for authenticating the third-party application.
In one embodiment, the computer program when executed by the processor further performs the steps of:
if the historical authentication result exists, the multimedia service process carries out validity check on the historical authentication result;
and if the validity check is passed, taking the historical authentication result as an authentication result of the multimedia service process for authenticating the third-party application.
In one embodiment, the computer program when executed by the processor further performs the steps of:
and if the validity check is not passed, re-authenticating the third-party application by the multimedia service process, and taking an authentication result obtained by re-authentication as an authentication result of the authentication of the third-party application by the multimedia service process.
In one embodiment, the computer program when executed by the processor further performs the steps of:
the multimedia service process determines whether the authentication code of the third party application is within the validity period;
and if the authentication code applied by the third party is in the valid period, determining that the validity check is passed.
In one embodiment, the operating system is an android system, and the computer program when executed by the processor further performs the steps of:
the multimedia service process acquires the binder through the acquisition service interface so as to establish process communication between the third-party application and the multimedia service process based on the binder.
It will be understood by those skilled in the art that all or part of the processes of the methods of the embodiments described above can be implemented by hardware instructions of a computer program, which can be stored in a non-volatile computer-readable storage medium, and when executed, can include the processes of the embodiments of the methods described above. Any reference to memory, database, or other medium used in the embodiments provided herein may include at least one of non-volatile and volatile memory. The nonvolatile Memory may include Read-Only Memory (ROM), magnetic tape, floppy disk, flash Memory, optical Memory, high-density embedded nonvolatile Memory, resistive Random Access Memory (ReRAM), Magnetic Random Access Memory (MRAM), Ferroelectric Random Access Memory (FRAM), Phase Change Memory (PCM), graphene Memory, and the like. Volatile Memory can include Random Access Memory (RAM), external cache Memory, and the like. By way of illustration and not limitation, RAM can take many forms, such as Static Random Access Memory (SRAM) or Dynamic Random Access Memory (DRAM), among others. The databases referred to in various embodiments provided herein may include at least one of relational and non-relational databases. The non-relational database may include, but is not limited to, a block chain based distributed database, and the like. The processors referred to in the embodiments provided herein may be general purpose processors, central processing units, graphics processors, digital signal processors, programmable logic devices, quantum computing based data processing logic devices, etc., without limitation.
The technical features of the above embodiments can be arbitrarily combined, and for the sake of brevity, all possible combinations of the technical features in the above embodiments are not described, but should be considered as the scope of the present specification as long as there is no contradiction between the combinations of the technical features.
The above-mentioned embodiments only express several embodiments of the present application, and the description thereof is more specific and detailed, but not construed as limiting the scope of the present application. It should be noted that, for a person skilled in the art, several variations and modifications can be made without departing from the concept of the present application, which falls within the scope of protection of the present application. Therefore, the protection scope of the present application shall be subject to the appended claims.
Claims (12)
1. An authentication method, used in an electronic device, wherein the electronic device includes a third-party application and a multimedia service process in which an operating system resides, the method comprising:
the third-party application acquires multimedia capability provided by an operating system of the electronic equipment;
the third party application calls the multimedia service process to authenticate the third party application;
and if the authentication result of the multimedia service process for authenticating the third-party application is authentication passing, the operating system continues to provide the multimedia capability for the third-party application.
2. The method of claim 1, wherein the third party application invoking the multimedia service process to authenticate the third party application comprises:
the third party application calls the multimedia service process;
the multimedia service process searches a history authentication result of the third-party application in a pre-established cache queue;
and if the historical authentication result does not exist, the multimedia service process authenticates the third-party application.
3. The method of claim 2, wherein after the multimedia service process authenticates the third party application if the historical authentication result does not exist, the method further comprises:
and the multimedia service process correspondingly stores the authentication result and the application identifier of the third-party application in the cache queue.
4. The method of claim 2, further comprising:
and if the historical authentication result exists, taking the historical authentication result as the authentication result of the multimedia service process for authenticating the third-party application.
5. The method of claim 4, wherein the using the historical authentication result as the authentication result for the multimedia service process to authenticate the third-party application if the historical authentication result exists comprises:
if the historical authentication result exists, the multimedia service process carries out validity check on the historical authentication result;
and if the validity check is passed, taking the historical authentication result as an authentication result of the multimedia service process for authenticating the third-party application.
6. The method of claim 5, further comprising:
and if the validity check is not passed, re-authenticating the third-party application by the multimedia service process, and taking an authentication result obtained by re-authentication as an authentication result of the multimedia service process for authenticating the third-party application.
7. The method of claim 5, wherein the multimedia service process performing a validity check on the historical authentication result comprises:
the multimedia service process determining whether an authentication code of the third party application is within a validity period;
and if the authentication code of the third-party application is in the valid period, determining that the validity check is passed.
8. The method of claim 2, wherein the operating system is an android system, and before the multimedia service process searches a pre-created cache queue for the historical authentication result of the third-party application, the method further comprises:
and the multimedia service process acquires the binder through the acquisition service interface so as to establish process communication between the third-party application and the multimedia service process based on the binder.
9. An authentication apparatus, for use in an electronic device, the electronic device including a third-party application and an operating system resident multimedia service process, the apparatus comprising:
the first capability acquisition module is used for acquiring the multimedia capability provided by the operating system of the electronic equipment by the third-party application;
the authentication module is used for calling the multimedia service process by the third-party application to authenticate the third-party application;
and the second capability obtaining module is used for continuing to provide the multimedia capability for the third-party application by the operating system if the authentication result of the authentication of the third-party application by the multimedia service process is that the authentication is passed.
10. An electronic device comprising a memory and a processor, the memory storing a computer program, characterized in that the processor realizes the steps of the method of any of claims 1 to 8 when executing the computer program.
11. A computer-readable storage medium, on which a computer program is stored, which, when being executed by a processor, carries out the steps of the method of any one of claims 1 to 8.
12. A computer program product comprising a computer program, characterized in that the computer program realizes the steps of the method of any one of claims 1 to 8 when executed by a processor.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202111261584.4A CN113918343A (en) | 2021-10-28 | 2021-10-28 | Authentication method, authentication device, electronic equipment, storage medium and computer program product |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202111261584.4A CN113918343A (en) | 2021-10-28 | 2021-10-28 | Authentication method, authentication device, electronic equipment, storage medium and computer program product |
Publications (1)
Publication Number | Publication Date |
---|---|
CN113918343A true CN113918343A (en) | 2022-01-11 |
Family
ID=79243500
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202111261584.4A Pending CN113918343A (en) | 2021-10-28 | 2021-10-28 | Authentication method, authentication device, electronic equipment, storage medium and computer program product |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN113918343A (en) |
-
2021
- 2021-10-28 CN CN202111261584.4A patent/CN113918343A/en active Pending
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN109617907B (en) | Authentication method, electronic device, and computer-readable storage medium | |
CN107659632B (en) | File encryption and decryption method and device and computer readable storage medium | |
US11888980B2 (en) | Stateless service-mediated security module | |
JP6079875B2 (en) | Application execution program, application execution method, and information processing terminal device for executing application | |
US20160350148A1 (en) | Thin client system, server device, policy management device, control method, and non-transitory computer readable recording medium | |
US11196554B2 (en) | Default password removal | |
KR20130133028A (en) | Method and device for managing digital usage rights of documents | |
JP2012508931A5 (en) | ||
US20160234340A1 (en) | Systems and methods for adaptive cloning of mobile devices | |
US8302202B2 (en) | Transportable computing environment apparatus system and method | |
CN109144487B (en) | Method, device, computer equipment and storage medium for developing business of parts | |
US11544415B2 (en) | Context-aware obfuscation and unobfuscation of sensitive content | |
US20180004982A1 (en) | Transparent execution of secret content | |
TW201516729A (en) | Terminal authentication and registration system, method for authenticating and registering terminal, and storage medium | |
CN109257426B (en) | Service line resource loading method and device, computer equipment and storage medium | |
CN111045743B (en) | Operating system safe starting method, management method, device and equipment | |
CN111382425B (en) | Application installation management method under multi-signature mechanism, intelligent terminal and storage medium | |
CN109766084B (en) | Customized development method and device for payment application, computer equipment and storage medium | |
CN112052432A (en) | Terminal device authorization method and device | |
CN113918343A (en) | Authentication method, authentication device, electronic equipment, storage medium and computer program product | |
CN114448722B (en) | Cross-browser login method and device, computer equipment and storage medium | |
US11526339B1 (en) | Systems and methods for improving application installation | |
CN110995437B (en) | ETC system-based user information input method, device, equipment and storage medium | |
TW201939333A (en) | Method and system for safely managing electronic device with electronic key with portable, safe, and convenient effects | |
Tangaro et al. | The Laniakea Dashboard and Storage Encryption Components: A Foundation for Developing On-Demand Cloud Services for Life Science |
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 |