WO2017156784A1 - 一种通知消息处理方法、装置及终端 - Google Patents

一种通知消息处理方法、装置及终端 Download PDF

Info

Publication number
WO2017156784A1
WO2017156784A1 PCT/CN2016/076798 CN2016076798W WO2017156784A1 WO 2017156784 A1 WO2017156784 A1 WO 2017156784A1 CN 2016076798 W CN2016076798 W CN 2016076798W WO 2017156784 A1 WO2017156784 A1 WO 2017156784A1
Authority
WO
WIPO (PCT)
Prior art keywords
trusted
application
tui
tee
notification
Prior art date
Application number
PCT/CN2016/076798
Other languages
English (en)
French (fr)
Inventor
李茹
吴黄伟
Original Assignee
华为技术有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 华为技术有限公司 filed Critical 华为技术有限公司
Priority to PCT/CN2016/076798 priority Critical patent/WO2017156784A1/zh
Priority to CN201680049422.5A priority patent/CN107924449B/zh
Publication of WO2017156784A1 publication Critical patent/WO2017156784A1/zh

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/70Protecting specific internal or peripheral components, in which the protection of a component leads to protection of the entire computer
    • G06F21/71Protecting specific internal or peripheral components, in which the protection of a component leads to protection of the entire computer to assure secure computing or processing of information
    • G06F21/74Protecting specific internal or peripheral components, in which the protection of a component leads to protection of the entire computer to assure secure computing or processing of information operating in dual or compartmented mode, i.e. at least one secure mode

Definitions

  • the present invention relates to the field of computer technologies, and in particular, to a notification message processing method, apparatus, and terminal.
  • the terminal can have two execution environments, namely a Trusted Executive Environment (TEE) and a rich execution environment ( Rich Execution Environment, REE), where the trusted execution environment coexists with the rich execution environment, but is independent of the rich execution environment.
  • the trusted execution environment has security features that meet security-related requirements, protects resources under the TEE from software attacks, and sets strict security measures to protect data and software access rights; rich execution environments are rich operating systems ( Rich Operation System (Rich OS) management, which is connected with the callable peripherals, is located outside the TEE.
  • Rich Operation System (Rich OS) management which is connected with the callable peripherals, is located outside the TEE.
  • the rich execution environment and the client application (CA) on it are not the main target of security, but The main goal is to have rich features, so the rich execution environment and its applications are considered untrustworthy.
  • the security display under the TEE must ensure that the information displayed to the user cannot be accessed by unauthorized applications in the REE or TEE.
  • a trusted application (TA) under the TEE requires a trusted user interface (Trusted User Interface)
  • the access of the TA to the TUI interface display resource must be exclusive. Therefore, multiple TUI sessions cannot access the screen display resources at the same time (a TUI session controls a TUI interface display), and the TA is exclusive to the TUI interface.
  • the TA when a TUI session is reserved for the TA, the TA is allowed to control the input and output of the TUI interface only if the TA starts to display using the TUI interface; the TUI session guarantees the control of the TA for the TUI interface.
  • There is a timeout limit when the TUI session of the TA starts and the TUI interface displays the end time (when the TA occupies the TUI session but the TUI interface is not displayed, the timeout is started), the timeout period arrives after the TUI session At the end, at this time, other applications are allowed to access the TUI interface, so that other applications can not display the notification message received by the TA when it is displayed by the TUI interface.
  • the present application provides a method, a device, and a terminal for processing a notification message.
  • the notification notification application (Notification TA) passed by the TEE environment authentication can simultaneously display the notifications received by multiple applications on the TUI interface. Message.
  • a first aspect of the embodiments of the present invention provides a method for processing a notification message, which is applied to a terminal having a rich execution environment REE and a trusted execution environment TEE.
  • the REE and the TEE are two execution environments independently running in the terminal.
  • the method includes: when the client application CA receives the notification message, the CA sends a detection command to the trusted notification application under the TEE; wherein the trusted notification application is a trusted application for processing the notification message by the TEE authentication
  • the trusted notification application can detect whether the TEE takes over the trusted user interface TUI of the terminal, and if the TEE takes over the TUI interface of the terminal, the CA transmits the notification message received by the CA to the trusted notification application; the trusted notification application can control the TUI The interface displays the notification message. It can be seen that the embodiment of the present invention can not only ensure the security of the TA display information in the TEE environment, but also display the notification message received by other applications on the TUI interface through the trusted notification application when the TA uses the TUI interface to display
  • the trusted application TA of the TEE can control the second area of the TUI interface to display the TA
  • the information of the TA may be an application interface or a notification message of the TA, etc.; correspondingly, the trusted notification application controls the TUI interface to display the notification message, which may be: the trusted notification application establishes a first TUI session connection with the TUI interface of the terminal. And displaying a notification message in a first area of the control TUI interface; the first area does not coincide with the second area, or the first area is in the second area.
  • the second area of the trusted application TA controlling the TUI interface of the TEE displays the information of the TA.
  • the TA may establish a second TUI session connection with the TUI interface to control the information of the second area of the TUI interface. It can be seen that this embodiment can control the TUI interface in the TEE environment while displaying the information of the TA and the notification message of the CA.
  • the trusted notification application controls the TUI interface to display the notification message, and the trusted notification application Receiving an input operation of the user for the notification message; in response to the input operation
  • the trusted notification application controls the CA to take over the TUI interface of the terminal.
  • the input operation may be received through the TUI interface when the TUI interface is taken over by the TEE environment, and the trusted notification application controls the CA to take over the TUI interface. Since the CA runs in the REE environment, it is equivalent to the REE environment taking over the TUI interface to display the application of the CA.
  • the interface is convenient for the user to process the notification message. If the notification message is an incoming call, the user can process the incoming call in time through the implementation manner.
  • the trusted notification application detects whether the TEE can take over the terminal Before the user interface TUI is trusted, the trusted notification application determines that the application identifier of the CA exists in the registration list, and the registration list includes an application identifier of the client application that allows the notification message to be displayed on the TUI interface by the trusted notification application. For example, if the CA is a WeChat application, only when the application identifier of the WeChat application exists in the registration list, the trusted notification application detects whether the TEE takes over the TUI interface of the terminal, and determines whether to control the TUI interface to display the WeChat application in the TEE environment.
  • the trusted notification application determines Before the application identifier of the CA exists in the registration list, the CA sends a registration request message to the trusted notification application, where the registration request message includes the application identifier of the CA; the trusted notification application adds the application identifier to the registration list, thereby making the trusted notification
  • the operation is performed to control the TUI interface to display the notification message of the CA.
  • the trusted notification application detects whether the TEE is taken over
  • the TUI interface of the terminal includes: the trusted notification application detects whether the TA has established a second TUI session connection with the TUI interface; if the TA and the TUI interface have established a second TUI session connection, the trusted notification application determines the TUI interface of the TEE takeover terminal .
  • the trusted notification application Detecting whether the TEE takes over the TUI interface of the terminal, including: the trusted notification application determines whether the TEE takes over the TUI interface of the terminal according to the display parameter of the terminal in the system setting parameter. It can be seen that if the TIE interface of the terminal is not taken over by the TEE, the notification message of controlling the display UI of the TUI interface in the REE environment can be implemented by using the prior art; if the TUI interface of the terminal is taken over by the TEE, the TEE environment can be controlled by the trusted notification application. TUI interface displays CA Notification message.
  • a second aspect of the embodiments of the present invention provides a notification message processing apparatus, which has a behavior function for implementing the method provided by the foregoing first aspect, and the function may be implemented by hardware, or may execute corresponding software through hardware. achieve.
  • the hardware or software includes one or more modules corresponding to the functions described above.
  • a third aspect of the embodiments of the present invention provides a terminal, where the terminal includes a memory, a display screen, and a processor.
  • the memory, the display screen and the processor cooperate with each other, and can be used to implement the method provided by the above first aspect.
  • FIG. 1 is a structural diagram of a terminal disclosed in an embodiment of the present invention.
  • FIG. 2 is a schematic flowchart of establishing a session connection between a CA in a REE environment and a TA in a TEE environment according to an embodiment of the present invention
  • FIG. 3 is a schematic flowchart of a method for processing a notification message according to an embodiment of the present invention
  • FIG. 4 is a schematic flowchart diagram of another method for processing a notification message according to an embodiment of the present invention.
  • FIG. 5 is a schematic flowchart diagram of another method for processing a notification message according to an embodiment of the present invention.
  • FIG. 6 is a schematic flowchart of another method for processing a notification message according to an embodiment of the present invention.
  • FIG. 7 is a schematic structural diagram of a notification message processing apparatus according to an embodiment of the present invention.
  • FIG. 1 is a structural diagram of a terminal according to an embodiment of the present invention.
  • the terminal shown in FIG. 1 may be any mobile or portable electronic device, including but not limited to a mobile phone, a mobile computer, a computer, a personal digital assistant (PDA), a media player, a smart TV, etc., the present invention The embodiment is not limited.
  • the terminal includes a rich execution environment REE and a trusted execution environment TEE, wherein the execution environment (EE) is composed of a series of hardware and software components that can provide necessary facilities for supporting application operation.
  • REE rich execution environment
  • TEE trusted execution environment
  • hardware components mainly include processors, peripherals (such as display screens, physical input keys, microphones, cameras, touch screens), memories (such as caches, volatile memory, non-volatile memory), and the like.
  • REE is mainly managed by rich operating system Rich OS along with other supported operating systems and virtual management programs.
  • TEE has security features to meet security-related requirements, protects resources in the TEE environment from software attacks, and is strictly set. Security measures to protect data in the TEE environment and access to the software.
  • the Rich OS (Rich OS) running in the REE environment can provide a variety of functions compared to the Trusted Operation System (Trusted OS) running in TEE.
  • Trusted Operation System Trusted Operation System
  • Trusted OS is mainly used to ensure the security of TEE.
  • Applications running in rich execution environments are considered to be untrustworthy, called Client Application (Client Application, CA); applications running in a trusted execution environment are trusted, called Trusted Application (TA).
  • Client Application CA
  • Trusted Application TA
  • a structure of the terminal may be as shown in FIG. 1 , the common processor 511 is separated from the trusted processor 512 , and the public processor 511 is a control center of the terminal in the REE environment, and is stored in the execution center.
  • a storage unit such as a software program and data in an external non-volatile or volatile memory, processes data or performs various functions of the terminal;
  • the trusted processor 512 is a control center of the terminal in the TEE environment, Software programs and data stored in a storage unit, such as an external non-volatile or volatile memory, processing data or performing various functions of the terminal;
  • the public cryptographic accelerator 521 is physically separated from the trusted cryptographic accelerator 522,
  • the public cryptographic accelerator 521 provides an encryption mechanism for the REE environment, and the trusted cryptographic accelerator 522 provides an encryption mechanism for the TEE environment;
  • the public one-time programmable area 561 can perform a one-time on-chip programming operation of public data in the REE environment, and enhance the encryption function.
  • the trusted one-time programmable encryption area 562 can perform one-time on-chip programming operation of trusted data in a TEE environment; external volatile storage
  • the storage 570 and the external non-volatile memory 580 also correspondingly partition the protected area accessible by the trusted processor 512; in the terminal structure, the public processor 511 in the REE environment
  • the public cryptographic accelerator 521, the public cache 531, the common memory 541, the common peripheral 551, the common one-time programmable area 561, the external volatile memory 570, and the protected area in the external non-volatile memory 580 may be combined.
  • the storage space performs data processing and performs various functions for the CA in the REE environment; the trusted processor 512 in the TEE environment can be combined with the trusted encryption accelerator 522, the trusted cache 532, the trusted memory 542, the trusted peripheral 552, and the The one-time programmable area 562, the external volatile memory 570, and the protected area in the external non-volatile memory 580 perform data processing and perform various functions for the TA in the TEE environment, through the security area in the terminal/
  • the isolation mechanism for non-secure areas provides a secure execution environment for sensitive applications or data.
  • the operation steps of the session connection between the CA in the REE environment and the TA in the TEE environment include establishing a context connection between the two, establishing a session connection between the two, performing a specific operation, and performing a specific operation to close the conversation between the two. Connect, and then close the context connection of the two, as shown in Figure 2, including the following command:
  • TEEC_initializeContext is the context connection between the CA and the TA.
  • the context connection is a logical connection.
  • the command format is as follows:
  • the command format is as follows:
  • the TA performs a specific operation corresponding to the command in the operation parameter according to the TEEC_InvokeCommand;
  • the command format for closing the context connection is:
  • the CA After the session connection is successfully established, the CA performs the previously described TEEC_InvokeCommand to transmit the notification message to the trusted notification application, and indicates that the trusted notification application is established.
  • the trusted notification application Connected to the TUI session of the TUI interface, the trusted notification application establishes the TUI session connection through the TEE_Result TEE_TUIInitSession command, and controls the TUI interface to display the notification message of the CA.
  • the premise that the trusted notification application is used for the TUI interface display is that the TEE has taken over the TUI interface of the terminal. The “takeover” means that the TA under the TEE is displaying information by using the TUI interface, and the display operation under the TEE is guaranteed.
  • Display security, exclusive and operational order atomicity that is, when the TA under the TEE occupies the end of the TUI interface display, the CA can access the TUI interface to display the notification message, but the trusted notification application can take over the TUI interface at the TEE. At the same time, the notification message received by the CA is displayed.
  • the notification message may be a notification message of a system-level application provided by the operating system in the REE environment, such as a short message received by the short message application provided by the operating system, and an incoming call reminder received by the phone application.
  • the notification message of the third-party application installed in the REE environment such as the chat message received by the instant messaging application, the shopping-related reminder message received by the shopping platform application, and the like, etc. limited.
  • the security operation can be completed in the TEE environment, such as a phone call or a short message plus Decryption operation, etc.
  • the body can be completed by executing the Operation command described earlier.
  • the CA under the REE may be a system-level application such as a phone or a short message, and may be a third-party application that is subsequently installed by a terminal such as a WeChat, an Alipay, a Weibo, and a schedule management, which is not limited in the embodiment of the present invention.
  • first and second are used for descriptive purposes only, and are not to be understood as indicating or implying relative importance or implicitly indicating the number of indicated technical features, for example, a trusted notification application.
  • Establishing a first TUI session connection with the terminal's TUI interface the first TUI session connection may control the TUI interface to display a notification message; in the TEE environment, the TA establishes a second TUI session connection with the terminal's TUI interface, and the second TUI session connection
  • the TUI interface can be controlled to display information of the TA, such as an application interface of the TA.
  • the first TUI session connection and the second TUI session connection are session connections of different applications and the TUI interface, and the first and second do not represent the establishment order of the TUI session connection unless explicitly and specifically defined.
  • FIG. 3 is a schematic flowchart of a method for processing a notification message according to an embodiment of the present invention.
  • the notification message processing method is applied to a terminal having a rich execution environment REE and a trusted execution environment TEE, where REE and TEE are The two execution environments run independently of each other in the terminal.
  • the notification message processing method may include the following steps:
  • the CA sends a detection command to the trusted notification application under the TEE.
  • the trusted notification application detects whether the TEE takes over the trusted user interface TUI of the terminal, and if it takes over, performs step S103; otherwise, the process ends.
  • whether the TEE takes over the TUI interface of the terminal that is, whether the TA under the TEE occupies the TUI interface display information, for example, the Alipay TA occupies the TUI interface to display the amount to be paid, and input the payment password.
  • the trusted notification application detects whether the TEE takes over the TUI interface of the terminal, including:
  • the trusted notification application determines whether the TEE takes over the TUI interface of the terminal according to the display parameter of the terminal in the system setting parameter.
  • the notification message may be displayed in the method displayed on the TUI interface according to the notification message applied in the prior art, which is not detailed in the embodiment of the present invention.
  • the CA sends a detection command to the trusted notification application, and may send a TEEC_Check command to the trusted notification application to determine whether the TEE takes over the TUI interface of the terminal. If the TUI interface of the terminal is taken over, the trusted notification application passes the TEEC_Response The command sends a response message to the CA that the TEE environment takes over the TUI interface, so that the CA performs step S103.
  • the CA transmits a notification message received by the CA to the trusted notification application.
  • the CA may perform a session connection between the TEEC_InitializeContext and the TEEC_OpenSession command to establish a session connection with the trusted notification application.
  • the CA may execute the TEEC_InvokeCommand command described above to execute the operation indicated by the Operation parameter. And transmitting, to the trusted notification application, the notification message received by the CA, where the Destination parameter is a universal unique identifier of the trusted notification application, and the Operation parameter indicates that the trusted notification application performs the operation of step S104.
  • the trusted notification application controls the TUI interface to display a notification message.
  • the method further includes: the trusted application TA under the TEE controls the second area of the TUI interface to display the information of the TA, such as the Alipay TA control TUI.
  • the second area of the interface displays the password input prompt information, etc.
  • the trusted notification application controls the TUI interface to display the notification message, which may also be: the trusted notification application establishes a first TUI session connection with the TUI interface, and utilizes the first TUI session. Connect to control the first area of the TUI interface to display a notification message.
  • the method further includes: the trusted notification application receives an input operation of the user for the notification message; and is trusted in response to the input operation
  • the notification application controls the CA to take over the TUI interface of the terminal, thereby facilitating the user to switch from the TEE environment to the REE environment, and processing the CA notification message, such as making a call, replying to a short message, and the like.
  • the client application CA in the REE environment receives the notification message.
  • the trusted notification application sends a detection command to the trusted notification application
  • the trusted notification application detects whether the TUI interface is taken over by the TEE environment. If the TEE environment takes over, the CA can transmit the notification message of the CA to the trusted notification.
  • the application controls the TUI interface to display the notification message. It can be seen that the embodiment of the present invention can not only ensure the security of the TA display information in the TEE environment, but also display the notification message received by other applications on the TUI interface through the trusted notification application when the TA uses the TUI interface to display.
  • FIG. 4 is a schematic flowchart of another method for processing a notification message according to an embodiment of the present invention.
  • the Alipay CA in the REE environment is executed by the Alipay TA in the TEE environment.
  • the notification message received by the short message application in the REE environment is the short message verification code information, and the following steps may be performed to display the notification message.
  • the name parameter in the TEEC_InitializeContext command is the identification name of the Alipay TA
  • the context parameter indicates the Alipay CA establishment and the Alipay TA.
  • the context parameter in the TEEC_OpenSession command, the context parameter also indicates the context connection between the Alipay CA and the Alipay TA, the session parameter indicates that the Alipay CA establishes a session connection with the Alipay TA, and the destination parameter is the universal unique identification code of the Alipay TA
  • the connectionMethod parameter indicates how the Alipay CA establishes a session connection with the Alipay TA.
  • the login information may be provided by the Alipay CA, or the user inputs the Alipay TA login account and password; the connectionData parameter is the specific login data. If the connectionMethod parameter indicates that the login information is provided by the user input, the value of the connectionData parameter may be NULL; the returnOrigin parameter refers to the return value of the Alipay CA after establishing a session connection with the Alipay TA.
  • the Alipay CA requests the Alipay TA to enable the TUI interface to display the secure payment information by using the TEEC_InvokeCommand command.
  • the security payment information may be a password prompt character (such as asking the user to input an Alipay payment password or asking the user to input a fingerprint to complete a payment operation, etc.), or a password input box, or a payment input required for credit card payment.
  • a password prompt character such as asking the user to input an Alipay payment password or asking the user to input a fingerprint to complete a payment operation, etc.
  • a password input box or a payment input required for credit card payment.
  • the information and the like are not limited in the embodiment of the present invention.
  • the operation command described in the execution of the TEEC_InvokeCommand command in the execution of the TEEC_InvokeCommand command by the Alipay TA indicates that the invoked command establishes a TUI session connection to control the TUI interface to display the secure payment information.
  • the TUI interface is switched from the REE environment to the TEE environment to display the secure payment information.
  • the short message application When the short message application receives the short message verification code information for the secure payment information, the short message application sends a TEEC_check detection command to the trusted notification application.
  • the trusted notification application detects whether the TUI interface is taken over by the TEE environment; if it is connected by the TEE environment Go to step S206, otherwise end the process.
  • the short message application establishes a session connection with the trusted notification application by using the TEEC_InitializeContext and the TEEC_OpenSession command described earlier.
  • the name parameter in the TEEC_InitializeContext command is the identifier name of the trusted notification application, and the context parameter indicates that the short message application is established and available.
  • the letter informs the context connection between the applications; in the TEEC_OpenSession command, the context parameter also indicates a context connection between the short message application and the trusted notification application, and the session parameter indicates that the short message application establishes a session connection with the trusted notification application, and the destination parameter is The universal unique identifier of the trusted notification application, the connectionMethod parameter indicates that the short message application establishes the login information after the session connection with the trusted notification application, the login information may be provided by the short message application, or may be input by the user; the connectionData parameter is specific The login data, if the connectionMethod parameter indicates input by the user, the value of the connectionData parameter may be NULL; the returnOrigin parameter refers to the return value of the short message application after establishing a session connection with the trusted notification application.
  • the short message application requests the trusted notification application to enable the TUI interface to display the short message verification code information by using the TEEC_InvokeCommand command described earlier.
  • the session parameter in the TEEC_InvokeCommand command refers to the effective session connection between the short message application and the trusted notification application in step S207
  • the CommandID parameter refers to the command ID that is invoked when the trusted notification application enables the TUI interface
  • the operation parameter refers to The letter informs the application that the payload of the command is invoked when the TUI interface is enabled. It contains multiple structures, each of which points to a different command; returnOrigin is the return value of the TEEC_InvokeCommand command.
  • the trusted notification application establishes a TUI session connection by executing an operation parameter in the TEEC_InvokeCommand command by using the Operation command described earlier to control the TUI interface.
  • the TUI interface is still taken over by the TEE environment, and the trusted notification application controls the TUI interface to display the short message verification code information.
  • the Alipay TA receives the SMS verification code and the payment password input by the user, and returns the payment password input by the user to the Alipay CA, and the Alipay TA sends an interrupt TUI interface display request to the trusted notification application;
  • S212 The Alipay TA closes the TUI session connection by using the TEEC_CloseSession command, and interrupts the display of the secure payment information on the TUI interface;
  • the trusted notification application ends the session connection with the short message application established in step S207 by using TEEC_FinalizeContext.
  • the Alipay TA ends the session connection with the Alipay CA established in step S201 by using the TEEC_FinalizeContext.
  • the Alipay CA in the REE environment when the Alipay CA in the REE environment receives the transfer button operation, the Alipay CA establishes a session connection between the CA in the REE environment and the TA in the TEE environment, and establishes an Alipay TA in the TEE environment.
  • Inter-session connection through which the Alipay TA establishes a first TUI session connection to enable the TUI interface to display secure payment information; when the SMS application in the REE environment receives the SMS verification code information for the secure payment information and the TUI interface is TEE environment
  • the SMS application can also establish a session connection with the trusted notification application according to the operation procedure of establishing a session connection between the CA in the REE environment and the TA in the TEE environment, and establish a second TUI through the session connection trusted notification application.
  • the session connection enables the TUI interface to display the SMS verification code information on the TUI interface. It can be seen that the embodiment of the present invention can not only ensure the security of the payment password input through the Alipay TA in the TEE environment, but also display the short message verification code through the trusted notification application when the TIE environment occupies the TUI interface.
  • FIG. 5 is a schematic flowchart of another method for processing a notification message according to an embodiment of the present invention.
  • the Alipay CA in the REE environment is executed by the Alipay TA in the TEE environment.
  • the secure payment operation, the WeChat application in the REE environment receives the WeChat event such as the chat message and the video request, that is, when the notification message is a WeChat event of the WeChat application, the following steps can be performed to display the WeChat event:
  • the registration request message includes an application identifier of the WeChat application, and the application identifier may be a unique universal identifier UIID of the WeChat application or the like.
  • the WeChat application establishes a session connection with the trusted notification application by using the TEEC_InitializeContext and TEEC_OpenSession commands described previously.
  • the WeChat application requests the trusted notification application to enable the TUI interface to display the WeChat event by using the TEEC_InvokeCommand command described earlier.
  • the trusted notification application executes the operation parameter in the TEEC_InvokeCommand command by using the Operation command described earlier, and establishes a TUI session connection to control the TUI interface to display the WeChat event.
  • the trusted notification application receives the input operation of the user, and determines whether the user continues to perform the payment operation or the operation of the WeChat event in the REE environment. If the user continues to perform the payment operation, steps S313 to S316 are performed; if the user processes the REE environment For the operation of the WeChat event, perform steps S317 to 319.
  • the trusted notification application sends an interrupt TUI interface display request to the Alipay TA.
  • the Alipay TA closes the TUI session connection by using the TEEC_CloseSession command, interrupts the display of the secure payment information on the TUI interface, and ends the session connection established with the Alipay CA established in step S303 through the TEEC_FinalizeContext;
  • the Alipay CA in the REE environment when the Alipay CA in the REE environment receives the transfer button operation, the Alipay CA establishes a session connection between the CA in the REE environment and the TA in the TEE environment, and establishes an Alipay TA in the TEE environment.
  • Inter-session connection through which the Alipay TA establishes the first TUI session connection to enable the TUI interface to display secure payment information;
  • the WeChat application in the REE environment receives the WeChat event and the TUI interface is taken over by the TEE environment, the WeChat application can also In the REE environment, the CA establishes a session connection with the TA in the TEE environment, establishes a session connection with the trusted notification application, and enables the trusted notification application to establish a second TUI session connection.
  • the TUI interface is enabled to display the WeChat event in the TUI. On the interface.
  • steps S401 to S409 are the same as the contents of steps S201 to S209 shown in FIG. 4, and describe a process of controlling the TUI interface to display the short message verification code information, which will not be described in detail herein.
  • the WeChat application sends a TEEC_check detection command to the trusted notification application when receiving the WeChat event.
  • step S411 The trusted notification application determines whether the application identifier of the WeChat application is included in the registration list, and the TUI interface is taken over by the TEE environment. If the application identifier of the WeChat application is included and the TUI interface is taken over by the TEE environment, step S412 is performed; otherwise, the process ends.
  • the trusted notification application sends a response message that the TUI interface is taken over by the TEE environment to the WeChat application by using the TEEC_response command.
  • Steps S412 to S415 are the same as the contents of steps S308 to S311 shown in FIG. 5, and describe a process of controlling the TUI interface to display a WeChat event, which will not be described in detail herein.
  • the TUI interface displays the security payment information, the short message verification code information, and the WeChat event respectively in a page or a plurality of areas that do not overlap each other.
  • the Alipay TA receives the SMS verification code and the payment password input by the user, and returns the payment password input by the user to the Alipay CA, and the Alipay TA sends an interrupt TUI interface display request to the trusted notification application;
  • the trusted notification application receives the interrupt TUI interface display request to close the TUI session connection by using the TEEC_CloseSession command, interrupts the display of the WeChat event and the SMS verification code information on the TUI interface, and ends the communication with the WeChat application and the SMS application respectively by using the TEEC_FinalizeContext command. Session connection
  • Alipay TA closes the TUI session connection through the TEEC_CloseSession command, interrupts the display of the secure payment information on the TUI interface; and ends the payment with CA via TEEC_FinalizeContext Session connection
  • the Alipay CA receives the payment password returned by the Alipay TA, and sends a payment request including the payment password to the payment server to complete the payment operation.
  • the trusted notification application sends an interrupt TUI interface display request to the Alipay TA.
  • the Alipay TA After receiving the interrupt TUI interface display request, the Alipay TA closes the TUI session connection by using the TEEC_CloseSession command, interrupts the display of the secure payment information on the TUI interface, and ends the session connection with the Alipay CA through the TEEC_FinalizeContext;
  • the trusted notification application closes the TUI session connection by using the TEEC_CloseSession command, interrupts the display of the WeChat event and the SMS verification code information on the TUI interface, and ends the session connection with the WeChat application and the SMS application respectively by using the TEEC_FinalizeContext command.
  • step S416 after the Alipay TA ends the session connection with the Alipay CA, it returns to the REE environment, and the Alipay CA performs step S417 to complete the payment operation; in step S420, the trusted notification application ends with the WeChat application and the short message application. After the session is connected, the REE environment is returned, and the WeChat application can process the WeChat event or the SMS application can process the SMS verification code information.
  • steps S401 to S405 describe a process in which the Alipay TA displays the secure payment information on the TUI interface; and steps S406 to S409 describe the process in which the trusted notification application displays the short message verification code information on the TUI interface.
  • S410 to S415 describe the process of displaying the WeChat event on the TUI interface;
  • S416 to S420 describe that when the user continues to perform the payment operation, the Alipay TA returns the received payment password to the Alipay CA, by Alipay CA.
  • S421 to S423 describe the end of all sessions in the TEE environment when the user processes the WeChat event or SMS verification code information in the REE environment. process.
  • the short message verification code information received by the short message application can be automatically filled in the verification code input box in the TUI interface to display the secure payment information after being displayed on the TUI interface.
  • the Alipay TA can return the payment password returned by the user to the Alipay CA, and the encryption return process is prior art, which is not detailed here;
  • the Alipay TA can return the payment password to the Alipay CA without being directly encrypted, and then send it to the payment-related server authentication to complete the payment operation.
  • the Alipay CA in the REE environment when the Alipay CA in the REE environment receives the transfer button operation, the Alipay CA establishes a session connection between the CA in the REE environment and the TA in the TEE environment, and establishes an Alipay TA in the TEE environment.
  • Inter-session connection through which the Alipay TA establishes the first TUI session connection to enable the TUI interface to display secure payment information; when the REE environment receives the SMS verification code information and the WeChat application receives the WeChat event and the TUI interface is TEE environment During the takeover, the SMS application and the WeChat application can respectively establish a session connection with the trusted notification application according to the operation steps of establishing a session connection between the CA in the REE environment and the TA in the TEE environment, so that the trusted notification application respectively establishes the TUI.
  • the session connection enables the TUI interface to display the SMS verification code information and the WeChat event on the TUI interface.
  • the embodiment of the present invention can not only ensure the security of the payment password input through the Alipay TA in the TEE environment, but also display the short message verification code information of the short message application and the WeChat application of the WeChat application through the trusted notification application when the TEE environment occupies the TUI interface. event. Further, the trusted notification application can receive the input operation of the user, determine whether to continue to perform the payment operation, or return to the SMS verification code information or the WeChat event in the REE environment, so that the user can select the content displayed on the TUI interface, and improve the operation of the user. Experience.
  • FIG. 7 is a schematic structural diagram of a notification message processing apparatus according to an embodiment of the present invention.
  • the notification message processing apparatus may perform the steps described in any of the embodiments shown in FIG. 2 to FIG. The description in the embodiments is also applicable to the device embodiment and will not be repeated here.
  • the notification message processing apparatus is applied to a terminal having two rich execution environments REE and a trusted execution environment TEE that operate independently of each other.
  • the notification message processing apparatus may at least include a communication module 610, a detection module 620, and a control module 630, where:
  • the communication module 610 may include a public processor 511 and a trusted processor 512, configured to send a detection command to the trusted notification application under the TEE through the CA when the client application CA receives the notification message under the REE; wherein the trusted notification application A trusted application for handling notification messages for TEE authentication;
  • the detecting module 620 can include a trusted processor 512, configured to detect, by the trusted notification application, whether the TEE takes over the trusted user interface TUI of the terminal;
  • the communication module 610 is further configured to use the public processor 511 to transmit, to the trusted notification application, the notification message received by the CA when the TEE takes over the TUI interface of the terminal;
  • the control module 630 can include a trusted processor 512 for controlling the TUI boundary by the trusted notification application The notification message is displayed.
  • control module 630 is further configured to: before the trusted notification application detects whether the TEE takes over the trusted user interface TUI of the terminal, the trusted application TA of the TEE controls the second area of the TUI interface to display the information of the TA;
  • the module 630 is specifically configured to establish a first TUI session connection with the TUI interface of the terminal by using the trusted notification application, to control the first area of the TUI interface to display the notification message received by the CA; wherein the first area does not coincide with the second area Or the first area is in the second area.
  • the notification message processing apparatus shown in FIG. 7 may further include a receiving module 640.
  • the receiving module 640 may include an input interface such as a microphone, a camera, or a touch screen, and is used to control the control module 630 through the trusted notification application. After the TUI interface displays the notification message, the input operation of the user for the notification message is received by the trusted notification application;
  • control module 630 may further include a common processor 511 for controlling the CA to take over the TUI interface of the terminal by the trusted notification application in response to the input operation.
  • the CA runs in the REE environment, it is equivalent to REE.
  • the environment takes over the TUI interface of the terminal to display the application interface of the CA.
  • the notification message processing apparatus shown in FIG. 7 may further include a determining module 650, where the determining module 650 may include a trusted processor 511, configured to detect, by the detecting module 620, whether the TEE takes over the terminal through the trusted notification application.
  • the application identifier of the CA existing in the registration list is determined by the trusted notification application, and the registration list includes an application identifier of the client application that allows the notification message to be displayed on the TUI interface by the trusted notification application.
  • the communication module 610 is further configured to: before the determining module 650 determines, by using the trusted notification application, that the application identifier of the CA exists in the registration list, send a registration request message to the trusted notification application by using the CA, where the registration request message is included.
  • the application identifier of the CA
  • the notification message processing apparatus shown in FIG. 7 may further include an adding module 660, which may include a trusted processor 512 for adding an application identifier to the registration list by the trusted notification application.
  • an adding module 660 may include a trusted processor 512 for adding an application identifier to the registration list by the trusted notification application.
  • the detecting module 620 is specifically configured to detect, by using the trusted notification application, whether the TA has established a second TUI session connection with the TUI interface; if the TA and the TUI interface have established a second TUI session connection, the The trusted notification application determines the TUI interface of the TEE takeover terminal.
  • the detecting module 620 is specifically configured to determine, by the trusted notification application, whether the TEE takes over the TUI interface of the terminal according to the display parameter of the terminal in the system setting parameter.
  • the communication module can send a detection command to the trusted notification application of the TEE through the CA when the client application CA receives the notification message, so that the detection module detects whether the TEE is taken over by the trusted notification application.
  • the trusted user interface TUI of the terminal further, the communication module may transmit the notification message received by the CA to the trusted notification application when the TEE takes over the TUI interface of the terminal; so that the control module displays the CA reception through the trusted notification application control TUI interface Notification message to.
  • the notification message processing apparatus in the embodiment of the present invention may further include an input module, which may enable the control module to control the CA to take over the TUI interface according to the input operation of the user for the notification message received by the input module, even if the TUI interface is taken over by the REE environment.
  • the notification message processing apparatus in the embodiment of the present invention may further include a determining module and an adding module, so that the detecting module determines the registration by the determining module before detecting, by the trusted notification application, whether the TEE takes over the TUI interface of the terminal.
  • the application identifier of the CA exists in the list, or the application identifier of the CA is added to the registration list by the adding module, so that the notification message processed by the notification message processing apparatus is derived from the CA that the trusted notification application authenticates, and further guarantees the TEE.
  • the security of the data or application is derived from the CA that the trusted notification application authenticates.
  • FIG. 1 is a schematic structural diagram of a terminal according to an embodiment of the present invention.
  • the terminal may include: a public processor 511, a trusted processor 512, a public cryptographic accelerator 521, and a trusted Encryption accelerator 522, public cache 531, trusted cache 532, common memory 541, trusted memory 542, common peripheral 551, trusted peripheral 552, common one-time programmable area 561, trusted one-time programmable area 562, An external volatile memory 570 and an external non-volatile memory 580, wherein the external volatile memory 570 included in the memory of the terminal and the external non-volatile memory 580 each include a protected area for storing trusted execution
  • the software code corresponding to the environment TEE, wherein the non-protected area is used to store the software code corresponding to the rich execution environment REE;
  • the public peripherals and trusted peripherals of the terminal may include a display screen for displaying the user interface, and Receiving input operations of the user;
  • the processor 511 of the terminal includes a public cache 5
  • the CA When the REE client application CA receives the notification message, the CA sends a detection command to the trusted notification application under the TEE; the trusted notification application is used by the TEE authentication to process the notification message. Trusted application;
  • the trusted notification application detects whether the TEE takes over the trusted user interface TUI of the terminal;
  • the CA transmits the notification message received by the CA to the trusted notification application;
  • the trusted notification application controls the TUI interface to display the notification message on a display screen.
  • the processor 511 includes a common processor 511 that runs the software code corresponding to the REE, and the trusted processor 512 runs the software code corresponding to the TEE to perform the following steps:
  • the trusted application TA of the TEE controls the second area of the TUI interface to display the information of the TA;
  • the trusted processor 512 runs the software code corresponding to the TEE, and is specifically configured to perform the following steps:
  • the trusted notification application establishes a first TUI session connection with the TUI interface of the terminal, to control the first area of the TUI interface to display the notification message; the first area does not coincide with the second area Or the first area is in the second area.
  • the processor 511 includes a common processor 511 that runs the software code corresponding to the REE, and the trusted processor 512 runs the software code corresponding to the TEE to perform the following steps:
  • the trusted notification application After the trusted notification application controls the TUI interface to display the notification message, the trusted notification application receives an input operation of the user for the notification message through a display screen;
  • the trusted notification application controls the CA to take over the TUI interface of the terminal.
  • the trusted processor 512 included in the processor runs the software code corresponding to the TEE to perform the following steps:
  • the trusted notification application Before the trusted notification application detects whether the TEE takes over the trusted user interface TUI of the terminal, determining that an application identifier of the CA exists in the registration list, where the registration list includes allowing the trusted notification application to be used by the The application identifier of the client application that displays the notification message on the TUI interface.
  • the processor 511 includes a common processor 511 that runs the software code corresponding to the REE, and the trusted processor 512 runs the software code corresponding to the TEE to perform the following steps:
  • the CA Before the trusted notification application determines that the application identifier of the CA exists in the registration list, the CA sends a registration request message to the trusted notification application, where the registration request message includes an application identifier of the CA;
  • the trusted notification application adds the application identification to a registration list.
  • the processor includes a trusted processor 512 running a TEE corresponding Software code to perform the following steps:
  • the processor includes a trusted processor 512 running the software code corresponding to the TEE to perform the following steps:
  • the trusted notification application determines whether the TEE takes over the TUI interface of the terminal according to the display parameter of the terminal in the system setting parameter.
  • the memory stores the software code corresponding to the execution environment REE and the software code corresponding to the trusted execution environment TEE
  • the processor is configured to run the software code corresponding to the REE and the software code corresponding to the TEE, when the REE client
  • the application CA receives the notification message
  • the CA sends a detection command to the trusted notification application under the TEE
  • the trusted notification application is a trusted application for processing the notification message by the TEE authentication
  • the trusted notification application detects whether the TEE takes over the terminal.
  • the trusted user interface TUI if the TEE takes over the TUI interface of the terminal, the CA transmits the notification message received by the CA to the trusted notification application; the trusted notification application controls the TUI interface to display the notification message on the display screen.
  • the embodiment of the present invention can not only ensure the security of the TA display information in the TEE environment, but also display the notification message received by other applications on the TUI interface through the trusted notification application.
  • an embodiment of the present invention further discloses a computer storage medium storing a computer program.
  • the computer program in the computer storage medium is read into a computer, the computer can cause the computer to complete the disclosure of the embodiment of the present invention. The full steps of the notification message processing method.
  • the program may be stored in a computer readable storage medium, and the storage medium may include: Flash disk, read-only memory (Read-Only Memory, ROM), random access memory (RAM), disk or optical disc.

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Computer Hardware Design (AREA)
  • Theoretical Computer Science (AREA)
  • Mathematical Physics (AREA)
  • Computer Security & Cryptography (AREA)
  • Software Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • User Interface Of Digital Computer (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

本发明实施例公开了一种通知消息的处理方法、装置及终端,该通知消息的处理方法中,当REE环境下的客户端应用CA接收到通知消息时,可以向可信执行环境TEE下可信通知应用发送检测命令,由可信通知应用检测TUI界面是否被TEE环境接管,若被TEE环境接管,CA可以将该通知消息传输给可信通知应用,使得可信通知应用将该通知消息显示在TUI界面上。可见,本发明实施例不仅能够保证TEE环境下的TA显示信息的安全性,还能在TA利用TUI界面显示时,通过可信通知应用在TUI界面显示其他应用接收到的通知消息。

Description

一种通知消息处理方法、装置及终端 技术领域
本发明涉及计算机技术领域,尤其涉及一种通知消息处理方法、装置及终端。
背景技术
随着计算机技术的发展,不断普及的终端可以安装各种各样的应用为人们的工作、生活及娱乐带来诸多便利,然而,由于终端存储着人们的大量敏感数据,其安全问题也逐渐得到重视。
为了确保终端中各种敏感数据在一个可信环境中被存储、处理及保护,终端中可以具有并存的两个执行环境,分别是可信执行环境(Trusted Executive Environment,TEE)以及富执行环境(Rich Execution Environment,REE),其中,可信执行环境虽然与富执行环境并存,但独立于富执行环境。可信执行环境具有安全性能,满足安全相关的要求,可以保护TEE下的资源免受软件的攻击,并设置严格的安全措施来保护数据以及软件的访问权限;富执行环境是由富操作系统(Rich Operation System,Rich OS)管理,与可调用的外设连接构成的,位于TEE的外部,该富执行环境及其上的客户端应用(Client Application,CA)不是以安全作为主要目标,而是以功能丰富为主要目标,因此,该富执行环境及其上的应用被认为是不可信的。
目前,TEE下的安全显示必须保证显示给用户的信息不能被REE或TEE中未授权的应用访问,当TEE下的一个可信应用(Trusted Application,TA)需求可信用户界面(Trusted User Interface,TUI)进行显示时,TA对于TUI界面显示资源的访问必须保证排他性,因此,多个TUI会话就无法同时访问屏幕显示资源(一个TUI会话控制一个TUI界面显示),并且TA对于TUI界面具有排他性及操作的顺序原子性。也就是说,当一个TUI会话被保留给TA的时候,当且仅当TA开始利用TUI界面显示的时候,才允许TA对于TUI界面的输入和输出控制权;TUI会话保证TA对于TUI界面的控制有超时限制,当TA的TUI会话开始并且TUI界面显示结束的时候开始计时(当TA占用TUI会话但是TUI界面不显示的时候开始进行超时计时),超时计时时间到达后TUI会话 结束,此时,才允许其他应用对TUI界面的访问,从而导致其他应用在TA利用TUI界面显示时,其接收到的通知消息无法显示。
发明内容
本申请提供了一种通知消息处理方法、装置及终端,可以在TA利用TUI界面显示时,通过TEE环境认证通过的可信通知应用(Notification TA)同时在TUI界面显示多个应用接收到的通知消息。
本发明实施例第一方面提供了一种通知消息处理方法,该方法应用于具有富执行环境REE和可信执行环境TEE的终端中,REE与TEE为相互独立运行于终端中的两个执行环境,该方法包括:当REE下客户端应用CA接收到通知消息时,CA向TEE下可信通知应用发送检测命令;其中,可信通知应用为TEE认证通过的用于处理通知消息的可信应用;该可信通知应用可以检测TEE是否接管终端的可信用户界面TUI,若TEE接管终端的TUI界面,则该CA向可信通知应用传输CA接收到的通知消息;可信通知应用可以控制TUI界面显示该通知消息。可见,本发明实施例不仅能够保证TEE环境下的TA显示信息的安全性,还能在TA利用TUI界面显示时,通过可信通知应用在TUI界面显示其他应用接收到的通知消息。
在第一方面的第一种可能的实现方式中,可信通知应用检测TEE是否接管终端的可信用户界面TUI之前,TEE下可信应用TA可以控制TUI界面的第二区域显示所述TA的信息,该TA的信息可以为TA的应用界面或通知消息等;相应地,可信通知应用控制TUI界面显示通知消息,可以为:可信通知应用建立与终端的TUI界面的第一TUI会话连接,以控制TUI界面的第一区域显示通知消息;该第一区域与第二区域不重合,或者第一区域在第二区域中。其中,TEE下可信应用TA控制TUI界面的第二区域显示TA的信息,可以为:TA建立与TUI界面的第二TUI会话连接,以控制TUI界面的第二区域显示TA的信息。可见,该实施方式可以在TEE环境下控制TUI界面同时显示TA的信息以及CA的通知消息。
结合第一方面的实现方式或者第一方面的第一种可能的实现方式,在第一方面的第二种可能的实现方式中,可信通知应用控制TUI界面显示通知消息之后,可信通知应用可以接收用户针对通知消息的输入操作;响应于该输入操 作,可信通知应用控制CA接管终端的TUI界面。其中,输入操作可以是通过TEE环境接管TUI界面时通过TUI界面接收,可信通知应用控制CA接管TUI界面,由于CA运行于REE环境下,因此相当于REE环境接管TUI界面,以显示CA的应用界面,方便用户对通知消息进行处理,如该通知消息为来电时,用户可以通过该实施方式及时处理该来电。
结合第一方面的实现方式,或者第一方面的第一种或第二种可能的实现方式,在第一方面的第三种可能的实现方式中,可信通知应用检测TEE是否接管终端的可信用户界面TUI之前,可信通知应用确定注册列表中存在CA的应用标识,该注册列表中包括允许通过可信通知应用在所述TUI界面上显示通知消息的客户端应用的应用标识。例如,该CA为微信应用,则仅在注册列表中存在该微信应用的应用标识时,可信通知应用才检测TEE是否接管终端的TUI界面,确定是否在TEE环境下控制TUI界面显示微信应用的通知消息。相应地,结合第一方面的实现方式,或者第一方面的第一种至第三种任一种可能的实现方式,在第一方面的第四种可能的实现方式中,可信通知应用确定注册列表中存在CA的应用标识之前,CA向可信通知应用发送注册请求消息,注册请求消息中包括CA的应用标识;可信通知应用将应用标识添加到注册列表中,从而,使得可信通知应用在确定注册列表中包括CA的应用标识时,执行上述操作以控制TUI界面显示该CA的通知消息,可见,该实施方式进一步的保证了TEE环境下TUI界面显示信息的安全性。
结合第一方面的实现方式,或者第一方面的第一种至第四种任一种可能的实现方式,在第一方面的第五种可能的实现方式中,可信通知应用检测TEE是否接管终端的TUI界面,包括:可信通知应用检测TA是否与TUI界面已建立第二TUI会话连接;若TA与TUI界面已建立第二TUI会话连接,则可信通知应用确定TEE接管终端的TUI界面。可选地,结合第一方面的实现方式,或者第一方面的第一种至第四种任一种可能的实现方式,在第一方面的第六种可能的实现方式中,可信通知应用检测所述TEE是否接管终端的TUI界面,包括:可信通知应用根据系统设置参数中终端的显示屏参数确定TEE是否接管终端的TUI界面。可见,若TEE未接管终端的TUI界面,则可以采用现有技术实现REE环境下控制TUI界面显示CA的通知消息;若TEE接管终端的TUI界面,则可以通过可信通知应用实现TEE环境下控制TUI界面显示CA 的通知消息。
本发明实施例第二方面提供了一种通知消息处理装置,该通知消息处理装置具有实现上述第一方面提供的方法的行为功能,所述功能可以通过硬件实现,也可以通过硬件执行相应的软件实现。所述硬件或软件包括一个或多个与上述功能相对应的模块。
本发明实施例第三方面提供了一种终端,该终端包括存储器、显示屏及处理器。其中,存储器、显示屏及处理器相互配合,可以用于实现上述第一方面提供的方法。
附图说明
为了更清楚地说明本发明实施例中的技术方案,下面将对实施例中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本发明的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动性的前提下,还可以根据这些附图获得其他的附图。
图1是本发明实施例公开的终端的一种结构图;
图2是本发明实施例公开的一种REE环境下CA与TEE环境下TA之间建立会话连接的流程示意图;
图3是本发明实施例公开的一种通知消息处理方法的流程示意图;
图4是本发明实施例公开的另一种通知消息处理方法的流程示意图;
图5是本发明实施例公开的另一种通知消息处理方法的流程示意图;
图6是本发明实施例公开的另一种通知消息处理方法的流程示意图;
图7是本发明实施例公开的一种通知消息处理装置的结构示意图。
具体实施方式
下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅是本发明一部分实施例,而不是全部的实施例。基于本发明中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都属于本发明保护的范围。
为了便于理解,这里先介绍下本发明实施例的一种终端的结构图,请参阅 图1,图1是本发明实施例公开的一种终端的结构图。其中,图1所示的终端可以是任何移动或便携式电子设备,包括但不限于移动电话、移动电脑、电脑、个人数字助理(Personal Digital Assistant,PDA)、媒体播放器、智能电视等,本发明实施例不作限定。如图1所示,该终端包括富执行环境REE以及可信执行环境TEE,其中,执行环境(Execution Environment,EE)是由可以提供支撑应用运行的必要设施的一系列硬件和软件部件构成的,例如,硬件部件主要有处理器、外设(如显示屏,实体输入键、麦克风、摄像头、触控屏)、存储器(如缓存,易失性存储器,非易失性存储器)等。REE主要是由富操作系统Rich OS连同其他可支持的操作系统和虚拟管理程序来管理,TEE具有安全性能,满足安全相关的要求,可以保护TEE环境下的资源免受软件的攻击,并设置严格的安全措施来保护TEE环境下数据以及软件的访问权限。运行于REE环境中的富操作系统(Rich Operation System,Rich OS)与运行于TEE中的可信操作系统(Trusted Operation System,Trusted OS)相比,Rich OS通常可以提供多样化的功能,而且可以兼容各种应用,以功能和性能为目标而不是安全性,而Trusted OS主要用于保证TEE的安全,运行于富执行环境的应用被认为是不可信的,称为客户端应用(Client Application,CA);运行于可信执行环境的应用是可信的,称为可信应用(Trusted Application,TA)。
本发明实施例中,终端的一种结构可以如图1所示,公共处理器511与可信处理器512划区隔离,公共处理器511为终端在REE环境下的控制中心,通过执行存储在存储单元,如外部非易失性或易失性存储器中的软件程序及数据,对数据进行处理或执行终端的各种功能;可信处理器512为终端在TEE环境下的控制中心,通过执行存储在存储单元,如外部非易失性或易失性存储器中的软件程序及数据,对数据进行处理或执行终端的各种功能;公共加密加速器521与可信加密加速器522物理划区隔离,公共加密加速器521为REE环境提供加密机制,可信加密加速器522为TEE环境提供加密机制;公共一次性可编程区域561可在REE环境下进行公共数据的一次性片内编程操作,增强加密功能,可信一次性可编程加密区域562可在TEE环境下进行可信数据的一次性片内编程操作;外部易失性存储器570和外部非易失性存储器580也相应的划分出由可信处理器512可以访问的受保护区域;该终端结构中,REE环境下公共处理器511 可以结合公共加密加速器521、公共缓存531、公共内存541、公共外设551、公共一次性可编程区域561、外部易失性存储器570以及外部非易失性存储器580中的受保护区域之外的存储空间为REE环境下的CA进行数据处理及执行各种功能;TEE环境下可信处理器512可以结合可信加密加速器522、可信缓存532、可信内存542、可信外设552、可信一次性可编程区域562、外部易失性存储器570以及外部非易失性存储器580中的受保护区域,为TEE环境下的TA进行数据处理及执行各种功能,通过上述终端中安全区域/非安全区域的隔离机制,为敏感应用或数据提供了安全的执行环境。
本发明实施例中,REE环境下CA与TEE环境下TA之间会话连接的操作步骤包括建立两者的上下文连接、建立两者的会话连接、执行具体操作、执行具体操作后关闭两者的会话连接,继而关闭两者的上下文连接,具体如图2所示包括以下命令:
1.TEEC_InitializeContext
TEEC_initializeContext为CA与TA之间进行的上下文连接,该上下文连接为逻辑连接,命令格式如下:
TEEC_Result TEEC_InitializeContext(
Const char*name,
TEEC_Context*context)
其中,name是TA的标识名,便于建立CA与TA之间的第一会话连接。
2.TEEC_OpenSession
当CA与TA之间的上下文连接建立成功后,CA建立与TA之间的会话连接,该会话连接也是逻辑连接,命令格式如下:
Figure PCTCN2016076798-appb-000001
Figure PCTCN2016076798-appb-000002
Destination参数是指目标TA的通用唯一识别码(Universally Unique Identifier,UUID),Operation参数是指针指向TA的具体操作,例如,请求支付宝TA启用TUI界面显示安全支付信息时,Destination参数为支付宝TA的通用唯一识别码,Operation参数指示支付宝TA调用相关命令控制TUI界面显示安全支付信息;connectionMethod参数是指CA建立与TA会话连接后如何登陆的方法,例如登陆信息可以是CA提供的,也可以是用户输入提供的;connectionData参数是具体的登陆数据,若connectionMethod参数指示由用户输入提供登陆信息,则该connectionData参数的值可以为NULL;returnOrigin参数是指CA建立与TA的会话连接后的返回值。
3.TEEC_InvokeCommand
CA建立与TA之间的会话连接后,触发执行指向TA的具体操作,该触发命令具体为:
Figure PCTCN2016076798-appb-000003
其中,session参数是指上述步骤1、2建立的有效会话连接,CommandID参数是指目标TA具体要调用的命令ID,operation参数是指TA执行的具体操作时调用命令的有效载荷,包含多个结构体,每个结构体指向不同的命令;returnOrigin为TEEC_InvokeCommand命令的返回值。
4.Operation
TA根据TEEC_InvokeCommand执行operation参数中命令对应的具体的操作;
5.TEEC_CloseSession
当TA执行具体操作后,会向CA返回关闭会话TEEC_CloseSession命令,该关闭会话的命令格式为:
Void TEEC_CloseSession(
TEEC_Session*    session);
6.TEEC_FinalizeContext
关闭会话后,即可关闭上下文连接,该关闭上下文连接的命令格式为:
Void TEEC_FinalizeContext(
TEEC_Context*    context).
本发明实施例公开的一种通知消息处理方法,能够通过TEE环境认证的可信通知应用(Notification TA)根据上述CA与TA之间会话连接的操作步骤,在屏幕被TEE占用时,建立基于多个CA的多个TUI会话连接,在多个TUI界面上显示多个CA接收到的通知消息。其中,可信通知应用为TEE环境认证通过的在TEE环境下运行的,用于多个TUI界面显示的系统级可信应用,例如,针对每个接收到通知消息的CA,首先,CA需要执行之前描述的TEEC_InitializeContext及TEEC_OpenSession命令建立与可信通知应用之间的会话连接,在该会话连接建立成功后,CA执行之前描述的TEEC_InvokeCommand将通知消息传输给可信通知应用,并指示可信通知应用建立与TUI界面的TUI会话连接,可信通知应用通过TEE_Result TEE_TUIInitSession命令建立该TUI会话连接,控制TUI界面显示该CA的通知消息。需要说明的是,可信通知应用用于TUI界面显示的前提是TEE已接管终端的TUI界面,该“接管”是指TEE下的TA正在利用TUI界面显示信息,并且TEE下的显示操作为了保证显示安全,具有排他性及操作的顺序原子性,即当TEE下的TA占用TUI界面显示结束时,CA才可以访问TUI界面显示通知消息,但利用可信通知应用就能够在TEE已接管TUI界面的同时,显示CA接收到的通知消息。
本发明实施例中,通知消息可以为REE环境下操作系统自带的系统级应用的通知消息,如操作系统自带的短信应用所接收到的短信息、电话应用所接收到的来电提醒等,也可以为REE环境下安装的第三方应用的通知消息,如即时通信应用接收到的聊天消息,购物平台应用接收到的到货、待支付等购物相关的提醒消息等,本发明实施例不做限定。其中,当终端中TEE环境接管TUI界面时,上述REE环境下的系统级应用或第三方应用与可信通知应用建立会话连接后,可以在TEE环境下完成安全性的操作,如电话或短信加解密操作等,具 体可以执行之前描述的Operation命令完成。
本发明实施例中,REE下的CA可以为电话、短信等系统级应用,也可以为微信、支付宝、微博、日程管理等终端后续安装的第三方应用,本发明实施例不做限定。
本发明实施例中,术语“第一”、“第二”仅用于描述目的,而不能理解为指示或暗示相对重要性或者隐含指明所指示的技术特征的数量,例如,可信通知应用建立与终端的TUI界面的第一TUI会话连接,该第一TUI会话连接可以控制TUI界面显示通知消息;TEE环境下TA建立与终端的TUI界面的第二TUI会话连接,该第二TUI会话连接可以控制TUI界面显示该TA的信息,如该TA的应用界面。其中,第一TUI会话连接与第二TUI会话连接是不同应用与TUI界面的会话连接,第一、第二不代表TUI会话连接的建立次序,除非另有明确具体的限定。
请参阅图3,图3是本发明实施例公开的一种通知消息处理方法的流程示意图,该通知消息处理方法应用于具有富执行环境REE和可信执行环境TEE的终端中,REE与TEE为相互独立运行于终端中的两个执行环境,如图3所示,该通知消息处理方法可以包括以下步骤:
S101、当REE下客户端应用CA接收到通知消息时,CA向TEE下可信通知应用发送检测命令;
S102、可信通知应用检测TEE是否接管终端的可信用户界面TUI,若接管,则执行步骤S103,否则结束本流程。
本发明实施例中,TEE是否接管终端的TUI界面,即TEE下的TA是否占用TUI界面显示信息,如支付宝TA占用TUI界面显示需要支付的金额、输入支付密码等信息。
作为一种可选的实施方式,可信通知应用检测TEE是否接管终端的TUI界面,包括:
可信通知应用检测TA是否与TUI界面已建立第二TUI会话连接;
若TA与TUI界面已建立第二TUI会话连接,则可信通知应用确定TEE接管所述终端的TUI界面。
该实施方式中,由于若TA与TUI界面已建立第二TUI会话连接,TA对于TUI界面的占用具有排他性及独占性,即其他应用的通知消息无法通过该TUI会话连接在TUI界面上显示,需要借助可信通知应用来处理通知消息,因此,若TA与TUI界面已建立第二TUI会话连接,则可信通知应用确定TEE接管所述终端的TUI界面。
作为另一种可选的实施方式,可信通知应用检测TEE是否接管终端的TUI界面,包括:
可信通知应用根据系统设置参数中终端的显示屏参数确定TEE是否接管终端的TUI界面。
该实施方式中,若TEE下TA占用终端的显示屏显示TA的信息,如TA的内容展示或操作界面等,则系统设置参数中终端的显示屏参数会被设置为TA的标识,同样,由于TA的安全显示使得TA对TUI界面的占用具有排他性及独占性,于是,可以确定TEE是否接管终端的TUI界面。
本发明实施例中,若TEE未接管终端的TUI界面,则可以根据现有技术中应用的通知消息在TUI界面显示的方法显示该通知消息,本发明实施例不再详述。
本发明实施例中,CA向可信通知应用发送检测命令,可以为CA向可信通知应用发送TEEC_Check命令,确定TEE是否接管终端的TUI界面,若接管终端的TUI界面,可信通知应用通过TEEC_Response命令向CA发送TEE环境接管TUI界面的响应消息,使得CA执行步骤S103。
S103、CA向可信通知应用传输CA接收到的通知消息;
本发明实施例中,CA可以执行之前描述的TEEC_InitializeContext及TEEC_OpenSession命令建立与可信通知应用之间的会话连接,该会话连接建立成功时,CA可以执行之前描述的TEEC_InvokeCommand命令执行Operation参数所指示的操作,向可信通知应用传输CA接收到的通知消息,其中,TEEC_OpenSession以及TEEC_InvokeCommand命令中,Destination参数为可信通知应用的通用唯一识别码,Operation参数指示可信通知应用执行步骤S104的操作。
S104、可信通知应用控制TUI界面显示通知消息。
本发明实施例中,可信通知应用控制TUI界面显示通知消息可以为:可信通知应用建立与TUI界面的第一TUI会话连接,利用该第一TUI会话连接,以控制TUI界面显示通知消息。
本发明实施例中,可信通知应用在检测TEE是否接管终端的TUI界面之前,所述方法还包括:TEE下可信应用TA控制TUI界面的第二区域显示TA的信息,如支付宝TA控制TUI界面的第二区域显示密码输入提示信息等,相应地,可信通知应用控制TUI界面显示通知消息还可以为:可信通知应用建立与TUI界面的第一TUI会话连接,利用该第一TUI会话连接,以控制TUI界面的第一区域显示通知消息。其中,TUI界面的第一区域和第二区域可以为互不重合的区域,或者第一区域在第二区域中,本发明实施例不做限定。需要注意的是,TUI界面的第一区域显示通知消息,第二区域显示TA的信息均是在TEE环境下执行的。
作为一种可选的实施方式,CA的通知消息显示在终端的TUI界面上之后,所述方法还包括:可信通知应用接收用户针对该通知消息的输入操作;响应于该输入操作,可信通知应用控制CA接管终端的TUI界面,从而便于用户选择从TEE环境切换到REE环境,处理CA的通知消息,如打电话、回复短信等操作。作为另一种可选的实施方式,CA的通知消息显示在终端的TUI界面上之后,所述方法还包括:可信通知应用接收用户针对TA的输入操作,响应于该输入操作,可信通知应用可以中断CA的通知消息在TUI界面的显示,继续执行TA的操作,如支付宝密码输入操作。
作为一种可选的实施方式,可信通知应用检测TEE是否接管所述终端的可信用户界面TUI之前,还需确定注册列表中存在该CA的应用标识,注册列表中包括允许通过可信通知应用在TUI界面上显示通知消息的客户端应用的应用标识。即可信通知应用确定注册列表中存在CA的应用标识之前,CA可以向可信通知应用发送注册请求消息,该注册请求消息中包括CA的应用标识;可信通知应用将该应用标识添加到注册列表中。可见,该实施方式保证了可以将通知消息显示在TUI界面的CA为可信通知应用认证注册的CA,保证了显示的安全性。
可见,本发明实施例中,当REE环境下的客户端应用CA接收到通知消息 时,可以向可信执行环境TEE下可信通知应用发送检测命令,由可信通知应用检测TUI界面是否被TEE环境接管,若被TEE环境接管,CA可以将CA的通知消息传输给可信通知应用,可信通知应用控制TUI界面显示该通知消息。可见,本发明实施例不仅能够保证TEE环境下的TA显示信息的安全性,还能在TA利用TUI界面显示时,通过可信通知应用在TUI界面显示其他应用接收到的通知消息。
请参阅图4,图4是本发明实施例公开的另一种通知消息处理方法的流程示意图,图4所示的通知消息处理方法中,REE环境下的支付宝CA通过TEE环境下的支付宝TA执行安全支付操作时,REE环境下的短信应用接收到的通知消息为短信验证码信息,可执行以下步骤显示该通知消息。
其中,支付宝CA与支付宝TA可以是两个支付应用,也可以是一个支付应用的两个部分,如果是两个支付应用,则可以分别下载安装;如果是一个支付应用的两个部分,则支付宝TA的安装包预先设置在支付宝CA的安装包里,在安装时支付宝TA可以通过指定路径安装在TEE环境下保证支付操作的安全性。本发明实施例中,TUI界面显示支付宝CA的应用界面时,TUI界面由REE环境接管,当用户针对TUI界面中支付宝CA的转账按键输入操作时,可以执行以下操作:
S201、支付宝CA通过之前描述的TEEC_InitializeContext及TEEC_OpenSession命令建立与TEE环境下支付宝TA之间的会话连接;
该步骤中,支付宝CA通过之前描述的TEEC_InitializeContext及TEEC_OpenSession命令建立与TEE环境下支付宝TA之间的会话连接时,TEEC_InitializeContext命令中的name参数是支付宝TA的标识名,context参数指示支付宝CA建立与支付宝TA之间的上下文连接;TEEC_OpenSession命令中,context参数同样指示支付宝CA与支付宝TA之间的上下文连接,session参数指示支付宝CA建立与支付宝TA之间的会话连接,destination参数为支付宝TA的通用唯一标识码,connectionMethod参数指示支付宝CA建立与支付宝TA的会话连接后如何登陆的方法,例如登陆信息可以是支付宝CA提供的,也可以是用户输入支付宝TA登陆账号和密码;connectionData参数是具体的登陆数据, 若connectionMethod参数指示由用户输入提供登陆信息,则该connectionData参数的值可以为NULL;returnOrigin参数是指支付宝CA建立与支付宝TA的会话连接后的返回值。
S202、支付宝CA通过TEEC_InvokeCommand命令请求支付宝TA启用TUI界面显示安全支付信息;
该步骤中,TEEC_InvokeCommand命令中session参数是指步骤S201中支付宝CA与支付宝TA之间的有效会话连接,CommandID参数是指支付宝TA启用TUI界面时调用命令ID,operation参数是指支付宝TA启用TUI界面时调用命令的有效载荷,包含多个结构体,每个结构体指向不同的命令;returnOrigin为TEEC_InvokeCommand命令的返回值。
本发明实施例中,安全支付信息可以为密码提示字符(如请用户输入支付宝支付密码或者是请用户输入指纹完成支付操作等),还可以是密码输入框,或者是信用卡支付所需要的支付输入信息等,本发明实施例不做限定。
S203、支付宝TA执行之前描述的Operation命令执行TEEC_InvokeCommand命令中operation参数指示调用的命令建立TUI会话连接,以控制TUI界面显示安全支付信息;
本发明实施例中,安全支付信息是由支付宝CA执行TEEC_InvokeCommand命令时,Operation参数携带后发送给支付宝TA的,并且Operation参数指示支付宝TA调用相关命令创建与TUI界面的TUI会话连接,以控制TUI界面显示安全支付信息。
相应地,支付宝TA建立与TUI界面的TUI会话连接,由TEE环境接管TUI界面,控制TUI界面显示安全支付信息时,支付宝TA还会向支付相关的服务器发送获取短信验证码的请求消息,支付相关的服务器生成短信验证码后发送给终端,由终端REE环境下短信应用接收包括该短信验证码的信息。
需要注意的是,该步骤中支付宝TA控制TUI界面显示安全支付信息时,TUI界面由REE环境接管切换到由TEE环境接管,以显示安全支付信息。
S204、REE环境下短信应用接收到针对该安全支付信息的短信验证码信息时,向可信通知应用发送TEEC_check检测命令;
S205、可信通知应用检测TUI界面是否被TEE环境接管;若被TEE环境接 管,执行步骤S206,否则结束本流程。
本发明实施例中,可信通知应用检测TUI界面是否被TEE环境接管可以通过系统设置参数中的屏幕参数确定TEE是否接管TUI界面,或者检测CA与TA之间是否已建立TUI会话连接确定TEE是否接管TUI界面。
S206、可信通知应用通过TEEC_response命令向短信应用发送TUI界面被TEE环境接管的响应消息;
S207、短信应用通过之前描述的TEEC_InitializeContext及TEEC_OpenSession命令建立与可信通知应用之间的会话连接;
该步骤中,短信应用通过之前描述的TEEC_InitializeContext及TEEC_OpenSession命令建立与可信通知应用之间的会话连接时,TEEC_InitializeContext命令中的name参数是可信通知应用的标识名,context参数指示短信应用建立与可信通知应用之间的上下文连接;TEEC_OpenSession命令中,context参数同样指示短信应用与可信通知应用之间的上下文连接,session参数指示短信应用建立与可信通知应用之间的会话连接,destination参数为可信通知应用的通用唯一标识码,connectionMethod参数指示短信应用建立与可信通知应用的会话连接后的登陆信息,该登陆信息可以是短信应用提供的,也可以是用户输入的;connectionData参数是具体的登陆数据,若connectionMethod参数指示由用户输入的,则该connectionData参数的值可以为NULL;returnOrigin参数是指短信应用建立与可信通知应用的会话连接后的返回值。
S208、短信应用通过之前描述的TEEC_InvokeCommand命令请求可信通知应用启用TUI界面显示短信验证码信息;
该步骤中,TEEC_InvokeCommand命令中session参数是指步骤S207中短信应用与可信通知应用之间的有效会话连接,CommandID参数是指可信通知应用启用TUI界面时调用的命令ID,operation参数是指可信通知应用启用TUI界面时调用命令的有效载荷,包含多个结构体,每个结构体指向不同的命令;returnOrigin为TEEC_InvokeCommand命令的返回值。
S209、可信通知应用通过之前描述的Operation命令执行TEEC_InvokeCommand命令中operation参数建立TUI会话连接,以控制TUI界面 显示短信验证码信息;
需要注意的是,该步骤中,TUI界面仍由TEE环境接管,可信通知应用控制TUI界面显示该短信验证码信息。
S210、支付宝TA接收用户输入的短信验证码及支付密码,并向支付宝CA返回用户输入的支付密码,支付宝TA向可信通知应用发送中断TUI界面显示请求;
S211、可信通知应用通过TEEC_CloseSession命令关闭TUI会话连接,中断TUI界面上短信验证码信息的显示;
S212、支付宝TA通过TEEC_CloseSession命令关闭TUI会话连接,中断TUI界面上安全支付信息的显示;
S213、可信通知应用通过TEEC_FinalizeContext结束步骤S207建立的与短信应用之间的会话连接;
S214、支付宝TA通过TEEC_FinalizeContext结束步骤S201建立的与支付宝CA之间的会话连接;
S215、支付宝CA接收支付宝TA返回的支付密码,并向支付服务器发送包括支付密码的支付请求以完成支付操作。
可选的,步骤S210中终端不必通过支付TA向支付CA返回用户输入的支付密码,而通过支付TA向服务器发送支付请求完成支付操作,该支付请求中包括支付密码。
可见,本发明实施例中,REE环境下的支付宝CA接收到转账按键操作时,支付宝CA根据REE环境下CA与TEE环境下TA之间建立会话连接的操作步骤,建立与TEE环境下支付宝TA之间的会话连接,通过该会话连接支付宝TA建立第一TUI会话连接启用TUI界面显示安全支付信息;当REE环境下的短信应用接收到针对该安全支付信息的短信验证码信息且TUI界面被TEE环境接管时,短信应用也可以根据REE环境下CA与TEE环境下TA之间建立会话连接的操作步骤,建立与可信通知应用之间的会话连接,通过该会话连接可信通知应用建立第二TUI会话连接启用TUI界面将短信验证码信息显示在TUI界面上。可见,本发明实施例不仅能够通过TEE环境下的支付宝TA保证支付密码输入的安全性,还能在TEE环境占用TUI界面时通过可信通知应用显示短信验证码。
请参阅图5,图5是本发明实施例公开的另一种通知消息处理方法的流程示意图,图5所示的通知消息处理方法中,REE环境下的支付宝CA通过TEE环境下的支付宝TA执行安全支付操作,REE环境下的微信应用接收到聊天消息、视频请求等微信事件,即通知消息为微信应用的微信事件时,可执行以下步骤显示该微信事件:
S301、微信应用向可信通知应用发送注册请求消息;
该注册请求消息中包括微信应用的应用标识,该应用标识可以为微信应用的唯一通用标识符UIID等。
S302、可信通知应用将微信应用的应用标识添加到注册列表,并返回注册成功的响应消息。
S303至S305的内容与图4所示的发明实施例中的步骤S201至S203的内容相同,这里不再重复。
S306、微信应用接收到微信事件时,向可信通知应用发送TEEC_check检测命令;
S307、可信通知应用检测TUI界面是否被TEE环境接管;若被TEE环境接管,执行步骤S308,否则结束本流程。
S308、可信通知应用通过TEEC_response命令向微信应用发送TUI界面被TEE环境接管的响应消息;
S309、微信应用通过之前描述的TEEC_InitializeContext及TEEC_OpenSession命令建立与可信通知应用之间的会话连接;
该步骤中,TEEC_InitializeContext及TEEC_OpenSession命令中的各参数与图4所示的发明实施例中步骤S207中TEEC_InitializeContext及TEEC_OpenSession命令中的各参数标识的含义类似,即TEEC_InitializeContext命令中的name参数是可信通知应用的标识名,context参数指示微信应用建立与可信通知应用之间的上下文连接;TEEC_OpenSession命令中,context参数同样指示微信应用与可信通知应用之间的上下文连接,session参数指示微信应用建立与可信通知应用之间的会话连接,destination参数为可信通知应用的通用唯一标识码,connectionMethod参数指示微信应用建立与可信通知应用的会话 连接后的登陆信息,该登陆信息可以是微信应用提供的,也可以是用户输入的;connectionData参数是具体的登陆数据,若connectionMethod参数指示由用户输入的,则该connectionData参数的值可以为NULL;returnOrigin参数是指微信应用建立与可信通知应用的会话连接后的返回值。
S310、微信应用通过之前描述的TEEC_InvokeCommand命令请求可信通知应用启用TUI界面显示微信事件;
该步骤中,TEEC_InvokeCommand命令中各参数与与图4所示的发明实施例中步骤S208中各参数标识的含义类似,即session参数是指步骤S309中微信应用与可信通知应用之间的有效会话连接,CommandID参数是指可信通知应用启用TUI界面时调用的命令ID,operation参数是指可信通知应用启用TUI界面时调用命令的有效载荷,包含多个结构体,每个结构体指向不同的命令;returnOrigin为TEEC_InvokeCommand命令的返回值。
S311、可信通知应用通过之前描述的Operation命令执行TEEC_InvokeCommand命令中operation参数,建立TUI会话连接以控制TUI界面显示微信事件;
S312、可信通知应用接收用户的输入操作,判断用户是继续执行支付操作还是处理REE环境下的微信事件的操作,若用户继续执行支付操作,则执行步骤S313至S316;若用户处理REE环境下的微信事件的操作,则执行步骤S317至319.
S313、支付宝TA接收用户输入的短信验证码及支付密码,并向支付宝CA返回用户输入的支付密码,支付宝TA向可信通知应用发送中断TUI界面显示请求;
S314、可信通知应用接收到中断TUI界面显示请求通过TEEC_CloseSession命令关闭TUI会话连接,中断TUI界面上微信事件的显示,并通过TEEC_FinalizeContext命令结束步骤S309建立的与微信应用之间的会话连接;
S315、支付宝TA通过TEEC_CloseSession命令关闭TUI会话连接,中断TUI界面上安全支付信息的显示;并通过TEEC_FinalizeContext结束步骤S303建立的与支付宝CA之间的会话连接;
S316、支付宝CA接收支付宝TA返回的支付密码,并向支付服务器发送包 括支付密码的支付请求以完成支付操作。
S317、可信通知应用向支付宝TA发送中断TUI界面显示请求;
S318、支付宝TA接收到中断TUI界面显示请求后,通过TEEC_CloseSession命令关闭TUI会话连接,中断TUI界面上安全支付信息的显示;并通过TEEC_FinalizeContext结束步骤S303建立的与支付宝CA之间的会话连接;
S319、可信通知应用通过TEEC_CloseSession命令关闭TUI会话连接,中断TUI界面上微信事件的显示,并通过TEEC_FinalizeContext命令结束步骤S309建立的与微信应用之间的会话连接。
本发明实施例中,步骤S301至S302描述的是微信应用向可信通知应用的注册过程;步骤S303至S305描述的是支付宝TA将安全支付信息显示在TUI界面上的过程;步骤S306至S311描述的是可信通知应用将微信事件显示在TUI界面上的过程;S313至S316描述的是用户继续执行支付操作时,支付宝TA将接收到的支付密码返回给支付宝CA,由支付宝CA将其发送给支付服务器完成支付操作,并在TEE环境下结束所有会话的过程;S317至S319描述的是用户处理REE环境下的微信事件时,在TEE环境下结束所有会话的过程。
可见,本发明实施例中,REE环境下的支付宝CA接收到转账按键操作时,支付宝CA根据REE环境下CA与TEE环境下TA之间建立会话连接的操作步骤,建立与TEE环境下支付宝TA之间的会话连接,通过该会话连接支付宝TA建立第一TUI会话连接启用TUI界面显示安全支付信息;当REE环境下的微信应用接收到微信事件且TUI界面被TEE环境接管时,微信应用也可以根据REE环境下CA与TEE环境下TA之间建立会话连接的操作步骤,建立与可信通知应用之间的会话连接,使得可信通知应用建立第二TUI会话连接启用TUI界面将微信事件显示在TUI界面上。可见,本发明实施例不仅能够通过TEE环境下的支付宝TA保证支付密码输入的安全性,还能在TEE环境占用TUI界面时通过可信通知应用显示微信事件。进一步的,可信通知应用可以接收用户的输入操作,判断继续执行支付操作还是返回处理REE环境下的微信事件,便于用户针对微信事件进行选择,改善了用户的操作体验。
请参阅图6,图6是本发明实施例公开的另一种通知消息处理方法的流程示 意图,图6所示的通知消息处理方法中,REE环境下的支付宝CA通过TEE环境下的支付宝TA执行安全支付操作,REE环境下的微信应用接收到聊天消息、视频请求等微信事件以及短信应用接收到短信验证码信息时,可执行以下步骤显示该微信事件及短信验证码信息:
其中,步骤S401至S409与图4所示的步骤S201至S209内容相同,描述控制TUI界面显示短信验证码信息的过程,这里不再详述。
S410、微信应用接收到微信事件时,向可信通知应用发送TEEC_check检测命令;
S411、可信通知应用确定注册列表中是否包括微信应用的应用标识且TUI界面被TEE环境接管,若包括微信应用的应用标识且TUI界面被TEE环境接管,则执行步骤S412,否则结束本流程。
S412、可信通知应用通过TEEC_response命令向微信应用发送TUI界面被TEE环境接管的响应消息。
其中,步骤S412至S415与图5所示的步骤S308至S311的内容相同,描述控制TUI界面显示微信事件的过程,这里不再详述。其中,TUI界面以分页或多个互不重合的区域分别显示安全支付信息、短信验证码信息以及微信事件。
S416、可信通知应用接收用户的输入操作,判断用户是继续执行支付操作还是处理REE环境下的微信事件以及短信验证码信息的操作,若用户继续执行支付操作,则执行步骤S417至S420;若用户处理REE环境下的微信事件的操作,则执行步骤S421至S423.
S417、支付宝TA接收用户输入的短信验证码及支付密码,并向支付宝CA返回用户输入的支付密码,支付宝TA向可信通知应用发送中断TUI界面显示请求;
S418、可信通知应用接收到中断TUI界面显示请求通过TEEC_CloseSession命令关闭TUI会话连接,中断TUI界面上微信事件以及短信验证码信息的显示,并通过TEEC_FinalizeContext命令分别结束与微信应用以及短信应用之间的会话连接;
S419、支付宝TA通过TEEC_CloseSession命令关闭TUI会话连接,中断TUI界面上安全支付信息的显示;并通过TEEC_FinalizeContext结束与支付宝CA之 间的会话连接;
S420、支付宝CA接收支付宝TA返回的支付密码,并向支付服务器发送包括支付密码的支付请求以完成支付操作。
S421、可信通知应用向支付宝TA发送中断TUI界面显示请求;
S422、支付宝TA接收到中断TUI界面显示请求后,通过TEEC_CloseSession命令关闭TUI会话连接,中断TUI界面上安全支付信息的显示;并通过TEEC_FinalizeContext结束与支付宝CA之间的会话连接;
S423、可信通知应用通过TEEC_CloseSession命令关闭TUI会话连接,中断TUI界面上微信事件以及短信验证码信息的显示,并通过TEEC_FinalizeContext命令分别结束与微信应用以及短信应用之间的会话连接。
需要说明的是,步骤S416中,支付宝TA结束与支付宝CA之间的会话连接后,返回REE环境,支付宝CA执行步骤S417完成支付操作;步骤S420中,可信通知应用结束与微信应用以及短信应用之间的会话连接后,返回REE环境,微信应用可以处理微信事件或者短信应用可以处理短信验证码信息。
本发明实施例中,步骤S401至S405描述的是支付宝TA将安全支付信息显示在TUI界面上的过程;步骤S406至S409描述的是可信通知应用将短信验证码信息显示在TUI界面上的过程;S410至S415描述的可信通知应用将微信事件显示在TUI界面上的过程;S416至S420描述的是用户继续执行支付操作时,支付宝TA将接收到的支付密码返回给支付宝CA,由支付宝CA将其发送给支付服务器完成支付操作,并在TEE环境下结束所有会话的过程;S421至S423描述的是用户处理REE环境下的微信事件或者短信验证码信息时,在TEE环境下结束所有会话的过程。
需要注意的是,图4和图6所示的发明实施例中,短信应用接收的短信验证码信息,可以在TUI界面显示后,自动填充到TUI界面显示安全支付信息中的验证码输入框中,不需要手动输入,进一步简化用户的操作步骤;支付宝TA将用户输入的支付密码返回给支付宝CA的过程中可以加密后返回,该加密返回过程为现有技术,这里不再详述;可选地,支付宝TA可以不必将支付密码返回给支付宝CA,而直接加密后发送给支付相关的服务器认证,完成支付操作。
可见,本发明实施例中,REE环境下的支付宝CA接收到转账按键操作时,支付宝CA根据REE环境下CA与TEE环境下TA之间建立会话连接的操作步骤,建立与TEE环境下支付宝TA之间的会话连接,通过该会话连接支付宝TA建立第一TUI会话连接启用TUI界面显示安全支付信息;当REE环境下支付宝CA接收到短信验证码信息以及微信应用接收到微信事件且TUI界面被TEE环境接管时,短信应用和微信应用可以分别根据REE环境下CA与TEE环境下TA之间建立会话连接的操作步骤,分别建立与可信通知应用之间的会话连接,使得可信通知应用分别建立TUI会话连接启用TUI界面将短信验证码信息及微信事件显示在TUI界面上。可见,本发明实施例不仅能够通过TEE环境下的支付宝TA保证支付密码输入的安全性,还能在TEE环境占用TUI界面时通过可信通知应用显示短信应用的短信验证码信息以及微信应用的微信事件。进一步的,可信通知应用可以接收用户的输入操作,判断继续执行支付操作还是返回处理REE环境下的短信验证码信息或微信事件,便于用户针对TUI界面显示的内容进行选择,改善了用户的操作体验。
请参阅图7,图7是本发明实施例公开的一种通知消息处理装置的结构示意图,该通知消息处理装置可以执行图2至图6所示的任一实施例所描述的步骤,相关方法实施例中的说明也适用于本装置实施例,在此不再重复。该通知消息处理装置应用于具有两个相互独立运行的富执行环境REE和可信执行环境TEE的终端中,该通知消息处理装置至少可以包括通信模块610、检测模块620以及控制模块630,其中:
通信模块610可以包括公共处理器511与可信处理器512,用于在REE下客户端应用CA接收到通知消息时,通过CA向TEE下可信通知应用发送检测命令;其中,可信通知应用为TEE认证通过的用于处理通知消息的可信应用;
检测模块620可以包括可信处理器512,用于通过可信通知应用检测TEE是否接管终端的可信用户界面TUI;
通信模块610,还用于利用公共处理器511在TEE接管终端的TUI界面时,向可信通知应用传输CA接收到的通知消息;
控制模块630可以包括可信处理器512,用于通过可信通知应用控制TUI界 面显示该通知消息。
本发明实施例中,控制模块630还用于在可信通知应用检测TEE是否接管终端的可信用户界面TUI之前,通过TEE下可信应用TA控制TUI界面的第二区域显示TA的信息;控制模块630具体用于通过可信通知应用建立与终端的TUI界面的第一TUI会话连接,以控制TUI界面的第一区域显示CA接收到的通知消息;其中,第一区域与第二区域不重合,或者第一区域在所述第二区域中。本发明实施例中,图7所示的通知消息处理装置还可以包括接收模块640,接收模块640可以包括麦克风、摄像头或触控屏等输入接口,用于在控制模块630通过可信通知应用控制TUI界面显示通知消息之后,通过可信通知应用接收用户针对通知消息的输入操作;
相应地,控制模块630还可以包括公共处理器511,用于响应该输入操作,通过可信通知应用控制CA接管终端的TUI界面,此时由于CA运行在REE环境下,因此,相当于由REE环境接管终端的TUI界面以显示CA的应用界面。
本发明实施例中,图7所示的通知消息处理装置还可以包括确定模块650,该确定模块650可以包括可信处理器511,用于在检测模块620通过可信通知应用检测TEE是否接管终端的可信用户界面TUI之前,通过可信通知应用确定注册列表中存在CA的应用标识,该注册列表中包括允许通过可信通知应用在TUI界面上显示通知消息的客户端应用的应用标识。
本发明实施例中,通信模块610还用于在确定模块650通过可信通知应用确定注册列表中存在CA的应用标识之前,通过该CA向可信通知应用发送注册请求消息,注册请求消息中包括该CA的应用标识;
相应地,图7所示的通知消息处理装置还可以包括添加模块660,添加模块660可以包括可信处理器512,用于通过可信通知应用将应用标识添加到注册列表中。
作为一种可选的实施方式,检测模块620具体用于通过可信通知应用检测TA是否与TUI界面已建立第二TUI会话连接;若TA与TUI界面已建立第二TUI会话连接,则可以通过可信通知应用确定该TEE接管终端的TUI界面。
作为另一种可选的实施方式,检测模块620具体用于通过可信通知应用根据系统设置参数中终端的显示屏参数确定TEE是否接管终端的TUI界面。
可见,本发明实施例中,通信模块可以在REE下客户端应用CA接收到通知消息时,通过该CA向TEE下可信通知应用发送检测命令,使得检测模块通过可信通知应用检测TEE是否接管终端的可信用户界面TUI;进而,通信模块可以在TEE接管终端的TUI界面时,向可信通知应用传输CA接收到的通知消息;使得控制模块通过可信通知应用控制TUI界面显示该CA接收到的通知消息。进一步的,本发明实施例中的通知消息处理装置还可以包括输入模块,可以根据输入模块接收到的用户针对通知消息的输入操作,使得控制模块控制CA接管TUI界面,即使TUI界面被REE环境接管以显示CA的应用界面;本发明实施例中的通知消息处理装置还可以包括确定模块、添加模块,使得检测模块在通过可信通知应用检测TEE是否接管终端的TUI界面之前,由确定模块确定注册列表中是否存在该CA的应用标识,或者由添加模块将CA的应用标识添加到注册列表中,使得通知消息处理装置所处理的通知消息来源于可信通知应用认证通过的CA,进一步的保证TEE下数据或应用的安全性。
请参阅图1,图1是本发明实施例公开的终端的一种结构示意图,如图1所示,该终端可以包括:公共处理器511、可信处理器512、公共加密加速器521、可信加密加速器522、公共缓存531、可信缓存532、公共内存541、可信内存542、公共外设551、可信外设552、公共一次性可编程区域561、可信一次性可编程区域562、外部易失性存储器570以及外部非易失性存储器580,其中,终端的存储器包括的外部易失性存储器570以及外部非易失性存储器580中均包括受保护的区域,用于存储可信执行环境TEE对应的软件代码,其中的非受保护的区域,用于存储富执行环境REE对应的软件代码;终端的公共外设及可信外设均可以包括显示屏,用于显示用户界面,和接收用户的输入操作;终端的处理器包括的公共处理器511可以运行所述REE对应的软件代码,可信处理器512可以运行TEE对应的软件代码,以执行如下步骤:
当所述REE下客户端应用CA接收到通知消息时,所述CA向所述TEE下可信通知应用发送检测命令;所述可信通知应用为所述TEE认证通过的用于处理通知消息的可信应用;
所述可信通知应用检测所述TEE是否接管所述终端的可信用户界面TUI;
若所述TEE接管所述终端的TUI界面,则所述CA向所述可信通知应用传输所述CA接收到的所述通知消息;
所述可信通知应用控制所述TUI界面在显示屏上显示所述通知消息。
本发明实施例中,处理器包括的公共处理器511运行所述REE对应的软件代码,可信处理器512运行TEE对应的软件代码,以执行如下步骤:
所述可信通知应用检测所述TEE是否接管所述终端的可信用户界面TUI之前,所述TEE下可信应用TA控制所述TUI界面的第二区域显示所述TA的信息;
其中,可信处理器512运行TEE对应的软件代码,具体用于执行如下步骤:
所述可信通知应用建立与所述终端的TUI界面的第一TUI会话连接,以控制所述TUI界面的第一区域显示所述通知消息;所述第一区域与所述第二区域不重合,或者所述第一区域在所述第二区域中。
本发明实施例中,处理器包括的公共处理器511运行所述REE对应的软件代码,可信处理器512运行TEE对应的软件代码,以执行如下步骤:
所述可信通知应用控制所述TUI界面显示所述通知消息之后,所述可信通知应用通过显示屏接收用户针对所述通知消息的输入操作;
响应于所述输入操作,所述可信通知应用控制所述CA接管所述终端的TUI界面。
本发明实施例中,处理器包括的可信处理器512运行TEE对应的软件代码,以执行如下步骤:
所述可信通知应用检测所述TEE是否接管所述终端的可信用户界面TUI之前,确定注册列表中存在所述CA的应用标识,所述注册列表中包括允许通过所述可信通知应用在所述TUI界面上显示通知消息的客户端应用的应用标识。
本发明实施例中,处理器包括的公共处理器511运行所述REE对应的软件代码,可信处理器512运行TEE对应的软件代码,以执行如下步骤:
在所述可信通知应用确定注册列表中存在所述CA的应用标识之前,所述CA向所述可信通知应用发送注册请求消息,所述注册请求消息中包括所述CA的应用标识;
所述可信通知应用将所述应用标识添加到注册列表中。
作为一种可选的实施方式,处理器包括的可信处理器512运行TEE对应的 软件代码,以执行如下步骤:
所述可信通知应用检测所述TA是否与所述TUI界面已建立第二TUI会话连接;若所述TA与所述TUI界面已建立第二TUI会话连接,则确定所述TEE接管所述终端的TUI界面。
作为另一种可选的实施方式,处理器包括的可信处理器512运行TEE对应的软件代码,以执行如下步骤:
所述可信通知应用根据系统设置参数中所述终端的显示屏参数确定所述TEE是否接管所述终端的TUI界面。
可见,本发明实施例中,存储器存储富执行环境REE对应的软件代码和可信执行环境TEE对应的软件代码,处理器用于运行REE对应的软件代码和TEE对应的软件代码,当REE下客户端应用CA接收到通知消息时,CA向TEE下可信通知应用发送检测命令;可信通知应用为所述TEE认证通过的用于处理通知消息的可信应用;可信通知应用检测TEE是否接管终端的可信用户界面TUI;若TEE接管终端的TUI界面,则CA向可信通知应用传输CA接收到的通知消息;可信通知应用控制所述TUI界面在显示屏上显示该通知消息。本发明实施例不仅能够保证TEE环境下的TA显示信息的安全性,还能通过可信通知应用在TUI界面显示其他应用接收到的通知消息。
一个实施例中,本发明实施例进一步公开一种计算机存储介质,该计算机存储介质存储有计算机程序,当计算机存储介质中的计算机程序被读取到计算机时,能够使得计算机完成本发明实施例公开的通知消息处理方法的全部步骤。
需要说明的是,对于前述的各个方法实施例,为了简单描述,故将其都表述为一系列的动作组合,但是本领域技术人员应该知悉,本发明并不受所描述的动作顺序的限制,因为依据本发明,某一些步骤可以采用其他顺序或者同时进行。其次,本领域技术人员也应该知悉,说明书中所描述的实施例均属于优选实施例,所涉及的动作和模块并不一定是本发明所必须的。
本领域普通技术人员可以理解上述实施例的各种方法中的全部或部分步骤是可以通过程序来指令相关的硬件来完成,该程序可以存储于一计算机可读存储介质中,存储介质可以包括:闪存盘、只读存储器(Read-Only Memory, ROM)、随机存取器(Random Access Memory,RAM)、磁盘或光盘等。
以上对本发明实施例所提供的通知消息处理方法、装置及终端进行了详细介绍,本文中应用了具体个例对本发明的原理及实施方式进行了阐述,以上实施例的说明只是用于帮助理解本发明的方法及其核心思想;同时,对于本领域的一般技术人员,依据本发明的思想,在具体实施方式及应用范围上均会有改变之处,综上所述,本说明书内容不应理解为对本发明的限制。

Claims (21)

  1. 一种通知消息处理方法,其特征在于,应用于具有富执行环境REE和可信执行环境TEE的终端中,所述REE与所述TEE为相互独立运行于所述终端中的两个执行环境,所述方法包括:
    当所述REE下客户端应用CA接收到通知消息时,所述CA向所述TEE下可信通知应用发送检测命令;所述可信通知应用为所述TEE认证通过的用于处理通知消息的可信应用;
    所述可信通知应用检测所述TEE是否接管所述终端的可信用户界面TUI;
    若所述TEE接管所述终端的TUI界面,则所述CA向所述可信通知应用传输所述CA接收到的所述通知消息;
    所述可信通知应用控制所述TUI界面显示所述通知消息。
  2. 根据权利要求1所述的方法,其特征在于,
    所述可信通知应用检测所述TEE是否接管所述终端的可信用户界面TUI之前,所述方法还包括:
    所述TEE下可信应用TA控制所述TUI界面的第二区域显示所述TA的信息;所述可信通知应用控制所述TUI界面显示所述通知消息,包括:
    所述可信通知应用建立与所述终端的TUI界面的第一TUI会话连接,以控制所述TUI界面的第一区域显示所述通知消息;所述第一区域与所述第二区域不重合,或者所述第一区域在所述第二区域中。
  3. 根据权利要求1或2所述的方法,其特征在于,所述可信通知应用控制所述TUI界面显示所述通知消息之后,所述方法还包括:
    所述可信通知应用接收用户针对所述通知消息的输入操作;
    响应于所述输入操作,所述可信通知应用控制所述CA接管所述终端的TUI界面。
  4. 根据权利要求1至3任一项所述的方法,其特征在于,所述可信通知应用检测所述TEE是否接管所述终端的可信用户界面TUI之前,所述方法还包括:
    所述可信通知应用确定注册列表中存在所述CA的应用标识,所述注册列表中包括允许通过所述可信通知应用在所述TUI界面上显示通知消息的客户端应用的应用标识。
  5. 根据权利要求4所述的方法,其特征在于,所述可信通知应用确定注册列表中存在所述CA的应用标识之前,所述方法还包括:
    所述CA向所述可信通知应用发送注册请求消息,所述注册请求消息中包括所述CA的应用标识;
    所述可信通知应用将所述应用标识添加到注册列表中。
  6. 根据权利要求1至5任一项所述的方法,其特征在于,所述可信通知应用检测所述TEE是否接管所述终端的TUI界面,包括:
    所述可信通知应用检测所述TA是否与所述TUI界面已建立第二TUI会话连接;
    若所述TA与所述TUI界面已建立第二TUI会话连接,则所述可信通知应用确定所述TEE接管所述终端的TUI界面。
  7. 根据权利要求1至5任一项所述的方法,其特征在于,所述可信通知应用检测所述TEE是否接管所述终端的TUI界面,包括:
    所述可信通知应用根据系统设置参数中所述终端的显示屏参数确定所述TEE是否接管所述终端的TUI界面。
  8. 一种通知消息处理装置,其特征在于,应用于具有富执行环境REE和可信执行环境TEE的终端中,所述REE与所述TEE为相互独立运行于所述终端中的两个执行环境,所述装置包括:
    通信模块,用于在所述REE下客户端应用CA接收到通知消息时,通过所述CA向所述TEE下可信通知应用发送检测命令;所述可信通知应用为所述TEE认证通过的用于处理通知消息的可信应用;
    检测模块,用于通过所述可信通知应用检测所述TEE是否接管所述终端的可信用户界面TUI;
    所述通信模块,还用于在所述TEE接管所述终端的TUI界面时,向所述可信通知应用传输所述CA接收到的所述通知消息;
    控制模块,用于通过所述可信通知应用控制所述TUI界面显示所述通知消息。
  9. 根据权利要求8所述的装置,其特征在于,所述控制模块还用于在所述可信通知应用检测所述TEE是否接管所述终端的可信用户界面TUI之前,通过 所述TEE下可信应用TA控制所述TUI界面的第二区域显示所述TA的信息;所述控制模块具体用于通过所述可信通知应用建立与所述终端的TUI界面的第一TUI会话连接,以控制所述TUI界面的第一区域显示所述通知消息;所述第一区域与所述第二区域不重合,或者所述第一区域在所述第二区域中。
  10. 根据权利要求8或9所述的装置,其特征在于,所述装置还包括:
    接收模块,用于在所述可信通知应用控制所述TUI界面显示所述通知消息之后,通过所述可信通知应用接收用户针对所述通知消息的输入操作;
    所述控制模块,还用于响应于所述输入操作,通过所述可信通知应用控制所述CA接管所述终端的TUI界面。
  11. 根据权利要求8至10任一项所述的装置,其特征在于,所述装置还包括:
    确定模块,用于在所述可信通知应用检测所述TEE是否接管所述终端的可信用户界面TUI之前,通过所述可信通知应用确定注册列表中存在所述CA的应用标识,所述注册列表中包括允许通过所述可信通知应用在所述TUI界面上显示通知消息的客户端应用的应用标识。
  12. 根据权利要求11所述的装置,其特征在于,所述通信模块还用于在所述可信通知应用确定注册列表中存在所述CA的应用标识之前,通过所述CA向所述可信通知应用发送注册请求消息,所述注册请求消息中包括所述CA的应用标识;
    所述装置还包括:
    添加模块,用于通过所述可信通知应用将所述应用标识添加到注册列表中。
  13. 根据权利要求8至12任一项所述的装置,其特征在于,所述检测模块具体用于通过所述可信通知应用检测所述TA是否与所述TUI界面已建立第二TUI会话连接;若所述TA与所述TUI界面已建立第二TUI会话连接,则所述可信通知应用确定所述TEE接管所述终端的TUI界面。
  14. 根据权利要求8至12任一项所述的装置,其特征在于,所述检测模块具体用于通过所述可信通知应用根据系统设置参数中所述终端的显示屏参数确定所述TEE是否接管所述终端的TUI界面。
  15. 一种终端,其特征在于,包括:
    存储器,用于存储富执行环境REE对应的软件代码和可信执行环境TEE对应的软件代码,所述REE与所述TEE为相互独立运行于所述终端中的两个执行环境;
    显示屏,用于显示用户界面,和接收用户的输入操作;
    所述终端还包括处理器,所述处理器用于运行所述REE对应的软件代码和TEE对应的软件代码以执行如下步骤:
    当所述REE下客户端应用CA接收到通知消息时,所述CA向所述TEE下可信通知应用发送检测命令;所述可信通知应用为所述TEE认证通过的用于处理通知消息的可信应用;
    所述可信通知应用检测所述TEE是否接管所述终端的可信用户界面TUI;
    若所述TEE接管所述终端的TUI界面,则所述CA向所述可信通知应用传输所述CA接收到的所述通知消息;
    所述可信通知应用控制所述TUI界面显示所述通知消息。
  16. 根据权利要求15所述的终端,其特征在于,所述处理器还用于运行所述REE对应的软件代码和所述TEE对应的软件代码以执行如下步骤:
    所述可信通知应用检测所述TEE是否接管所述终端的可信用户界面TUI之前,所述TEE下可信应用TA控制所述TUI界面的第二区域显示所述TA的信息;
    所述处理器具体用于运行所述REE对应的软件代码和所述TEE对应的软件代码以执行如下步骤:
    所述可信通知应用建立与所述终端的TUI界面的第一TUI会话连接,以控制所述TUI界面的第一区域显示所述通知消息;所述第一区域与所述第二区域不重合,或者所述第一区域在所述第二区域中。
  17. 根据权利要求15或16所述的终端,其特征在于,所述处理器还用于运行所述REE对应的软件代码和所述TEE对应的软件代码以执行如下步骤:所述可信通知应用控制所述TUI界面显示所述通知消息之后,所述可信通知应用接收用户针对所述通知消息的输入操作;
    响应于所述输入操作,所述可信通知应用控制所述CA接管所述终端的TUI界面。
  18. 根据权利要求15至17任一项所述的终端,其特征在于,所述处理器还用于运行所述REE对应的软件代码和所述TEE对应的软件代码以执行如下步骤:
    所述可信通知应用检测所述TEE是否接管所述终端的可信用户界面TUI之前,确定注册列表中存在所述CA的应用标识,所述注册列表中包括允许通过所述可信通知应用在所述TUI界面上显示通知消息的客户端应用的应用标识。
  19. 根据权利要求18所述的终端,其特征在于,所述处理器还用于运行所述REE对应的软件代码和所述TEE对应的软件代码以执行如下步骤:
    在所述可信通知应用确定注册列表中存在所述CA的应用标识之前,所述CA向所述可信通知应用发送注册请求消息,所述注册请求消息中包括所述CA的应用标识;
    所述可信通知应用将所述应用标识添加到注册列表中。
  20. 根据权利要求15至19任一项所述的终端,其特征在于,所述处理器具体用于运行所述REE对应的软件代码和所述TEE对应的软件代码以执行如下步骤:
    所述可信通知应用检测所述TA是否与所述TUI界面已建立第二TUI会话连接;若所述TA与所述TUI界面已建立第二TUI会话连接,则确定所述TEE接管所述终端的TUI界面。
  21. 根据权利要求15至19任一项所述的终端,其特征在于,所述处理器具体用于运行所述REE对应的软件代码和所述TEE对应的软件代码以执行如下步骤:
    所述可信通知应用根据系统设置参数中所述终端的显示屏参数确定所述TEE是否接管所述终端的TUI界面。
PCT/CN2016/076798 2016-03-18 2016-03-18 一种通知消息处理方法、装置及终端 WO2017156784A1 (zh)

Priority Applications (2)

Application Number Priority Date Filing Date Title
PCT/CN2016/076798 WO2017156784A1 (zh) 2016-03-18 2016-03-18 一种通知消息处理方法、装置及终端
CN201680049422.5A CN107924449B (zh) 2016-03-18 2016-03-18 一种通知消息处理方法、装置及终端

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/CN2016/076798 WO2017156784A1 (zh) 2016-03-18 2016-03-18 一种通知消息处理方法、装置及终端

Publications (1)

Publication Number Publication Date
WO2017156784A1 true WO2017156784A1 (zh) 2017-09-21

Family

ID=59851160

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2016/076798 WO2017156784A1 (zh) 2016-03-18 2016-03-18 一种通知消息处理方法、装置及终端

Country Status (2)

Country Link
CN (1) CN107924449B (zh)
WO (1) WO2017156784A1 (zh)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108924421A (zh) * 2018-07-16 2018-11-30 Oppo广东移动通信有限公司 图像处理方法、装置、计算机可读存储介质和电子设备
CN109766152A (zh) * 2018-11-01 2019-05-17 华为终端有限公司 一种交互方法及装置
CN109815662A (zh) * 2018-12-06 2019-05-28 北京握奇智能科技有限公司 一种tee环境下的手势密码身份认证方法及系统
EP3621294A4 (en) * 2018-07-16 2020-09-30 Guangdong Oppo Mobile Telecommunications Corp., Ltd. METHOD AND DEVICE FOR IMAGE PROCESSING, COMPUTER-READABLE STORAGE MEDIUM AND ELECTRONIC DEVICE

Families Citing this family (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109214215B (zh) * 2018-06-19 2021-10-26 中国银联股份有限公司 基于tee和ree的分离式切换方法及其系统
CN111046383B (zh) * 2018-10-12 2023-10-13 华为技术有限公司 终端攻击防御方法、装置、终端及云服务器
WO2020088323A1 (zh) * 2018-11-01 2020-05-07 华为技术有限公司 一种能力开放方法及装置
CN111383015B (zh) * 2018-12-29 2023-11-03 华为技术有限公司 交易安全处理方法、装置及终端设备
CN112711452B (zh) * 2019-10-24 2023-11-03 华为技术有限公司 一种图像显示方法与电子设备
CN114785554B (zh) * 2022-03-24 2023-05-05 福建师范大学 一种可信执行的混合信任多方计算系统

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20130263215A1 (en) * 2012-03-27 2013-10-03 Telefonaktiebolaget L M Ericsson (Publ) Display Authentication
CN103793815A (zh) * 2014-01-23 2014-05-14 武汉天喻信息产业股份有限公司 适用于银行卡和行业卡的移动智能终端收单系统及方法
CN104809379A (zh) * 2015-05-13 2015-07-29 上海瓶钵信息科技有限公司 基于屏幕分层管理的系统执行状态验证方法
CN105260663A (zh) * 2015-09-15 2016-01-20 中国科学院信息工程研究所 一种基于TrustZone技术的安全存储服务系统及方法

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103745155A (zh) * 2014-01-03 2014-04-23 东信和平科技股份有限公司 一种可信Key及其安全操作方法
US9331988B2 (en) * 2014-03-20 2016-05-03 Oracle International Corporation System and method for provisioning secrets to an application (TA) on a device
CN104125216B (zh) * 2014-06-30 2017-12-15 华为技术有限公司 一种提升可信执行环境安全性的方法、系统及终端

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20130263215A1 (en) * 2012-03-27 2013-10-03 Telefonaktiebolaget L M Ericsson (Publ) Display Authentication
CN103793815A (zh) * 2014-01-23 2014-05-14 武汉天喻信息产业股份有限公司 适用于银行卡和行业卡的移动智能终端收单系统及方法
CN104809379A (zh) * 2015-05-13 2015-07-29 上海瓶钵信息科技有限公司 基于屏幕分层管理的系统执行状态验证方法
CN105260663A (zh) * 2015-09-15 2016-01-20 中国科学院信息工程研究所 一种基于TrustZone技术的安全存储服务系统及方法

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108924421A (zh) * 2018-07-16 2018-11-30 Oppo广东移动通信有限公司 图像处理方法、装置、计算机可读存储介质和电子设备
EP3621294A4 (en) * 2018-07-16 2020-09-30 Guangdong Oppo Mobile Telecommunications Corp., Ltd. METHOD AND DEVICE FOR IMAGE PROCESSING, COMPUTER-READABLE STORAGE MEDIUM AND ELECTRONIC DEVICE
CN109766152A (zh) * 2018-11-01 2019-05-17 华为终端有限公司 一种交互方法及装置
CN109766152B (zh) * 2018-11-01 2022-07-12 华为终端有限公司 一种交互方法及装置
US11709929B2 (en) 2018-11-01 2023-07-25 Huawei Technologies Co., Ltd. Interaction method and apparatus
CN109815662A (zh) * 2018-12-06 2019-05-28 北京握奇智能科技有限公司 一种tee环境下的手势密码身份认证方法及系统

Also Published As

Publication number Publication date
CN107924449B (zh) 2020-03-10
CN107924449A (zh) 2018-04-17

Similar Documents

Publication Publication Date Title
WO2017156784A1 (zh) 一种通知消息处理方法、装置及终端
US10614212B1 (en) Secure software containers
CN108595970B (zh) 处理组件的配置方法、装置、终端及存储介质
US9104840B1 (en) Trusted security zone watermark
WO2018228199A1 (zh) 一种授权方法以及相关设备
US20140173692A1 (en) Bring your own device system using a mobile accessory device
CN110083465B (zh) 一种寄宿应用间的数据传递方法
EP3370449B1 (en) Method and device for configuring security indication information
WO2013182005A1 (zh) 一种用于拦截应用程序对服务的调用的方法和装置
WO2018103559A1 (zh) 授权登录方法及装置
WO2013182006A1 (zh) 一种用于拦截应用程序对服务的调用的方法和装置
WO2016069595A1 (en) Method and system for exchanging content between applications
EP3817322A1 (en) Method for upgrading service application range of electronic identity card, and terminal device
CN111523136B (zh) 应用程序的权限管理方法、装置、设备及存储介质
WO2015109668A1 (zh) 应用程序管理方法、装置、终端及计算机存储介质
US9886595B2 (en) Priority-based application execution method and apparatus of data processing device
EP3764258B1 (en) Constructing common trusted application for a plurality of applications
WO2018076685A1 (zh) 一种信息交互的方法及设备
WO2020088321A1 (zh) 一种交互方法及装置
US20230229760A1 (en) Mobile device with secure private memory
US20220005046A1 (en) Payment method using biometric authentication and electronic device therefor
KR20170142672A (ko) 신뢰실행환경 기반의 컴퓨팅 장치
EP3179751B1 (en) Information sending method and apparatus, terminal device, and system
CN112286632B (zh) 云平台、云平台管理方法、装置、电子设备及储存介质
KR101223981B1 (ko) 안전한 애플리케이션 실행을 위한 가상화 장치, 서버 및 방법

Legal Events

Date Code Title Description
NENP Non-entry into the national phase

Ref country code: DE

121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 16893949

Country of ref document: EP

Kind code of ref document: A1

122 Ep: pct application non-entry in european phase

Ref document number: 16893949

Country of ref document: EP

Kind code of ref document: A1