Patent ID: 8775824

Claim:
A data processing apparatus comprising: a data processor for processing data in a secure and a non-secure mode, said data processor processing data in said secure mode having access to secure data that is not accessible to said data processor in said non-secure mode, and processing data in said secure mode being performed under control of a secure operating system and processing data in said non-secure mode being performed under control of a non-secure operating system; and a further processing device for performing a task in response to a request from said data processor, said task comprising processing data at least some of which is secure data; wherein said further processing device is responsive to receipt of a signal to suspend said task to determine whether said signal indicates a deferred process state switch and if not to suspend said task and initiate: processing of said secure data using a secure key; and storage of said processed secure data to a non-secure data store; and if said signal to suspend said task comprises a deferred process state switch, to suspend said task and not perform said processing of said secure data and said storage of said processed secure data until a signal to commence a new task on said further processing device is received; and said further processing device is responsive to receipt of a signal to resume said suspended task to initiate retrieval of said processed secure data from said non-secure data store, restoration of said processed secure data using said secure key, and resumption of said suspended task unless said suspended task was suspended due to said deferred process state switch and no signal to commence said new task has occurred, in which event said further processing device is responsive to receipt of said signal to resume said suspended task to resume said suspended task without performing said retrieval and restoration of said processed secure data, wherein said secure key is securely stored such that it is not accessible to other processes operating in said non-secure mode, and wherein said processing of said secure data comprises generation of a secure signature from said data and encryption of said secure signature using said secure key, and said restoration of said processed secure data comprises decryption of said encrypted secure signature, generation of said secure signature from said retrieved data, and comparison of said generated secure signature with said decrypted secure signature; and in response to said generated secure signature not matching said decrypted secure signature, said further processing device is configured to issue a signal to said data processor to indicate that said data has been tampered with; and in response to said generated secure signature matching said decrypted secure signature, said further processing device is configured to resume said task using said retrieved data.