| e147a447 | 05-Dec-2018 |
Jerome Forissier <jerome.forissier@linaro.org> |
Remove Secure Element API support
There is probably no-one using the Secure Element API. We have never heard anyone asking questions about it, have no way to test it and we believe it is not even wo
Remove Secure Element API support
There is probably no-one using the Secure Element API. We have never heard anyone asking questions about it, have no way to test it and we believe it is not even working right now. Therefore, remove it.
- The reserved syscalls are still present, but return TEE_ERROR_NOT_SUPPORTED - The TEE_SE* functions (GlobalPlatform TEE Secure Element API, GPD_SPE_024) are removed from libutee.a and the header file tee_internal_se_api.h is removed as well
Signed-off-by: Jerome Forissier <jerome.forissier@linaro.org> Acked-by: Joakim Bech <joakim.bech@linaro.org> Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org> Acked-by: Etienne Carriere <etienne.carriere@linaro.org>
show more ...
|
| 56859c53 | 14-Sep-2018 |
Gabor Szekely <szvgabor@gmail.com> |
core: crypto: add TEE_ALG_RSASSA_PKCS1_V1_5
This change integrates the LTC_PKCS_1_V1_5_NA1 into OPTEE as an extension as TEE_ALG_RSASSA_PKCS1_V1_5. This scheme allows to do PKCS#1 v1.5 EMSA without
core: crypto: add TEE_ALG_RSASSA_PKCS1_V1_5
This change integrates the LTC_PKCS_1_V1_5_NA1 into OPTEE as an extension as TEE_ALG_RSASSA_PKCS1_V1_5. This scheme allows to do PKCS#1 v1.5 EMSA without ASN.1 around the hash. It is used for implementing the pkcs#11 CKM_RSA_PKCS mechanism for signing and verifying in SKS.
Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org> Signed-off-by: Gabor Szekely <szvgabor@gmail.com>
show more ...
|
| 6009538c | 24-Oct-2018 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: introduce generic optee_rpc_cmd.h
Replaces the OPTEE_MSG RPC command protocol descriptions in optee_msg.h and optee_msg_supplicant with a generic optee_rpc_cmd.h. Defined names are also refact
core: introduce generic optee_rpc_cmd.h
Replaces the OPTEE_MSG RPC command protocol descriptions in optee_msg.h and optee_msg_supplicant with a generic optee_rpc_cmd.h. Defined names are also refactored to mirror the new structure.
Acked-by: Etienne Carriere <etienne.carriere@linaro.org> Reviewed-by: Jerome Forissier <jerome.forissier@linaro.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
show more ...
|
| 7c350378 | 22-Oct-2018 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: tadb.c: get rid of init_memparam()
Acked-by: Etienne Carriere <etienne.carriere@linaro.org> Reviewed-by: Jerome Forissier <jerome.forissier@linaro.org> Signed-off-by: Jens Wiklander <jens.wikl
core: tadb.c: get rid of init_memparam()
Acked-by: Etienne Carriere <etienne.carriere@linaro.org> Reviewed-by: Jerome Forissier <jerome.forissier@linaro.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
show more ...
|
| f4feeeef | 22-Oct-2018 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: tee_fs_rpc.c get rid of init_memparam()
Acked-by: Etienne Carriere <etienne.carriere@linaro.org> Reviewed-by: Jerome Forissier <jerome.forissier@linaro.org> Signed-off-by: Jens Wiklander <jens
core: tee_fs_rpc.c get rid of init_memparam()
Acked-by: Etienne Carriere <etienne.carriere@linaro.org> Reviewed-by: Jerome Forissier <jerome.forissier@linaro.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
show more ...
|
| 13eb4e3c | 19-Oct-2018 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: use struct thread_param for RPC
Use struct thread_param as an abstraction of the parameters used for RPC.
Acked-by: Etienne Carriere <etienne.carriere@linaro.org> Acked-by: Jerome Forissier <
core: use struct thread_param for RPC
Use struct thread_param as an abstraction of the parameters used for RPC.
Acked-by: Etienne Carriere <etienne.carriere@linaro.org> Acked-by: Jerome Forissier <jerome.forissier@linaro.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
show more ...
|
| cd278f78 | 19-Oct-2018 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: simplify shm cookie handling
Simplifies SHM cookie handling by storing the cookie in the mobj instead of putting the burden on the caller. The cookie parameter is dropped from the thread_rpc_*
core: simplify shm cookie handling
Simplifies SHM cookie handling by storing the cookie in the mobj instead of putting the burden on the caller. The cookie parameter is dropped from the thread_rpc_*_payload() functions. All callers of those functions are also updated and unused cookie members of related structs are removed too.
Acked-by: Jerome Forissier <jerome.forissier@linaro.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
show more ...
|
| daaf4f11 | 12-Oct-2018 |
Daniel McIlvaney <damcilva@microsoft.com> |
core: modify tee_otp_get_hw_unique_key to return TEE_Result
Getting the hardware key can fail on some platforms. Modify the function signature to return an appropriate error code.
Signed-off-by: Da
core: modify tee_otp_get_hw_unique_key to return TEE_Result
Getting the hardware key can fail on some platforms. Modify the function signature to return an appropriate error code.
Signed-off-by: Daniel McIlvaney <damcilva@microsoft.com> Signed-off-by: Jordan Rhee <jordanrh@microsoft.com> Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org>
show more ...
|
| d7a893d3 | 07-Sep-2018 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: fix tee_tadb_ta_create() panic
Fixes a panic triggered in tee_tadb_ta_create(). Before this patch tee_tadb_ta_create() was calling tadb_put() if tee_tadb_open() failed. This is incorrect as th
core: fix tee_tadb_ta_create() panic
Fixes a panic triggered in tee_tadb_ta_create(). Before this patch tee_tadb_ta_create() was calling tadb_put() if tee_tadb_open() failed. This is incorrect as the reference counter hasn't been increased then. This patch fixes that by only calling tadb_put() once tee_tadb_open() has succeeded.
Reviewed-by: Joakim Bech <joakim.bech@linaro.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
show more ...
|
| 3798db34 | 08-Aug-2018 |
Silvano di Ninno <silvano.dininno@nxp.com> |
core: tee: crypt_utl: remove one crypto_init
Crypto_init is called twice in tee_cryp_init.
Signed-off-by: Silvano di Ninno <silvano.dininno@nxp.com> Reviewed-by: Jerome Forissier <jerome.forissier@
core: tee: crypt_utl: remove one crypto_init
Crypto_init is called twice in tee_cryp_init.
Signed-off-by: Silvano di Ninno <silvano.dininno@nxp.com> Reviewed-by: Jerome Forissier <jerome.forissier@linaro.org>
show more ...
|
| afd1381f | 12-Jun-2018 |
Sahil Malhotra <sahil.malhotra@nxp.com> |
core: tee: update objectSize/keySize for ECDSA/ECDH Objects
objectSize/keySize was not getting updated when an ECDSA/ECDH object was imported. Updating the ObjectSize/keySize based on the EC Curve.
core: tee: update objectSize/keySize for ECDSA/ECDH Objects
objectSize/keySize was not getting updated when an ECDSA/ECDH object was imported. Updating the ObjectSize/keySize based on the EC Curve.
Fixes: https://github.com/OP-TEE/optee_os/issues/2386 Signed-off-by: Sahil Malhotra <sahil.malhotra@nxp.com> Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org>
show more ...
|
| ea6cd913 | 14-Jun-2018 |
Jens Wiklander <jens.wiklander@linaro.org> |
Remove get_rng_array()
Removes get_rng_array() in favor of crypto_rng_read() which always uses the configured RNG implementation to draw random.
Reviewed-by: Jerome Forissier <jerome.forissier@lina
Remove get_rng_array()
Removes get_rng_array() in favor of crypto_rng_read() which always uses the configured RNG implementation to draw random.
Reviewed-by: Jerome Forissier <jerome.forissier@linaro.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
show more ...
|
| 6e954a6e | 14-Jun-2018 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: add new RNG implementation
Adds a new cryptographically secure pseudo random number generator known as Fortuna. The implementation is based on the description in [0]. This implementation repla
core: add new RNG implementation
Adds a new cryptographically secure pseudo random number generator known as Fortuna. The implementation is based on the description in [0]. This implementation replaces the implementation in LTC which was used until now.
Gathering of entropy has been refined with crypto_rng_add_event() to better match how entropy is added to Fortuna. A enum crypto_rng_src identifies the source of the event. The source also controls how the event is added. There are two options available, queue it in a circular buffer for later processing or adding it directly to a pool. The former option is suitable when being called from an interrupt handler or some other place where RPC to normal world is forbidden.
plat_prng_add_jitter_entropy_norpc() is removed and plat_prng_add_jitter_entropy() is updated to use this new entropy source scheme.
The configuration of LTC is simplified by this, now PRNG is always drawn via prng_mpa_desc.
plat_rng_init() takes care of initializing the PRNG in order to allow platforms to override or enhance the Fortuna integration.
[0] Link:https://www.schneier.com/academic/paperfiles/fortuna.pdf
Reviewed-by: Jerome Forissier <jerome.forissier@linaro.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
show more ...
|
| 09bce883 | 07-Jun-2018 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: fix syscall_cryp_obj_get_attr() with null buffer
Prior to this patch when syscall_cryp_obj_get_attr() is called with a NULL buffer to query buffer size the function returns TEE_ERROR_ACCESS_DE
core: fix syscall_cryp_obj_get_attr() with null buffer
Prior to this patch when syscall_cryp_obj_get_attr() is called with a NULL buffer to query buffer size the function returns TEE_ERROR_ACCESS_DENIED while TEE_ERROR_SHORT_BUFFER is expected. This patch fixes syscall_cryp_obj_get_attr() to return TEE_ERROR_SHORT_BUFFER if supplied buffer parameter is NULL.
Reviewed-by: Jerome Forissier <jerome.forissier@linaro.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
show more ...
|
| 45e286b0 | 18-May-2018 |
Volodymyr Babchuk <vlad.babchuk@gmail.com> |
tee_ree_fs: avoid race condition between fh usage/closing
It is possible that one core will call ree_fs_close_primitive() while another is calling ree_fs_read_primitive(). This patch prevents this b
tee_ree_fs: avoid race condition between fh usage/closing
It is possible that one core will call ree_fs_close_primitive() while another is calling ree_fs_read_primitive(). This patch prevents this by putting ree_fs_close_primitive under mutex.
Signed-off-by: Volodymyr Babchuk <vlad.babchuk@gmail.com> Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org>
show more ...
|
| 655c204e | 18-May-2018 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: htree: fix meta inclusion in root hash
Prior to this patch was the size of the meta data supplied as the size of the pointer to meta data. With this patch the size is corrected to be the size
core: htree: fix meta inclusion in root hash
Prior to this patch was the size of the meta data supplied as the size of the pointer to meta data. With this patch the size is corrected to be the size of meta data itself.
Reviewed-by: Jerome Forissier <jerome.forissier@linaro.org> Reviewed-by: Joakim Bech <joakim.bech@linaro.org> Fixes: https://github.com/OP-TEE/optee_os/issues/2330 Fixes: 94a72998bc1d ("core: fs_htree: include meta in root hash") Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
show more ...
|
| dc0f4ec2 | 16-May-2018 |
Etienne Carriere <etienne.carriere@st.com> |
Remove license notice from STMicroelectronics files
Since a while the source files license info are defined by SPDX identifiers. We can safely remove the verbose license text from the files that are
Remove license notice from STMicroelectronics files
Since a while the source files license info are defined by SPDX identifiers. We can safely remove the verbose license text from the files that are owned by either only STMicroelectronics or only both Linaro and STMicroelectronics.
Signed-off-by: Etienne Carriere <etienne.carriere@st.com> Signed-off-by: Etienne Carriere <etienne.carriere@linaro.org> Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org>
show more ...
|
| f678d2cd | 14-May-2018 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: fix OOM handling in tee_svc_storage_read_head()
Fixes out of memory handling error in tee_svc_storage_read_head(). Prior to this all errors from fops->read() was reported as TEE_ERROR_CORRUPT_
core: fix OOM handling in tee_svc_storage_read_head()
Fixes out of memory handling error in tee_svc_storage_read_head(). Prior to this all errors from fops->read() was reported as TEE_ERROR_CORRUPT_OBJECT leading to removal of the object even when the real problem was temporary memory shortage. This patch reports TEE_ERROR_OUT_OF_MEMORY from fops->read() correctly while translating all other errors to TEE_ERROR_CORRUPT_OBJECT.
Reviewed-by: Etienne Carriere <etienne.carriere@linaro.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
show more ...
|
| 5c39e05d | 26-Apr-2018 |
Jerome Forissier <jerome.forissier@linaro.org> |
core: syscall_open_ta_session(): make sure user context is set
There is no guarantee that the current user context is preserved after tee_ta_open_session(). Therefore, set it again before copying da
core: syscall_open_ta_session(): make sure user context is set
There is no guarantee that the current user context is preserved after tee_ta_open_session(). Therefore, set it again before copying data to user space.
Signed-off-by: Jerome Forissier <jerome.forissier@linaro.org> Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org> Acked-by: Joakim Bech <joakim.bech@linaro.org>
show more ...
|
| 35964dc9 | 05-Apr-2018 |
Etienne Carriere <etienne.carriere@linaro.org> |
core: minor cleanup related to pseudo TAs
tee_kta_trace.h is unused and useless. Reword "static TA" into "pseudo TA" in comments.
Signed-off-by: Etienne Carriere <etienne.carriere@linaro.org> Revie
core: minor cleanup related to pseudo TAs
tee_kta_trace.h is unused and useless. Reword "static TA" into "pseudo TA" in comments.
Signed-off-by: Etienne Carriere <etienne.carriere@linaro.org> Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org> Acked-by: Jerome Forissier <jerome.forissier@linaro.org>
show more ...
|
| bdc919a5 | 22-Mar-2018 |
Jerome Forissier <jerome.forissier@linaro.org> |
core: crypto: enable 4096-bit RSA keys
RSA key size can be allowed to be as large as CFG_CORE_BIGNUM_MAX_BITS (4096 by default).
Signed-off-by: Jerome Forissier <jerome.forissier@linaro.org> Review
core: crypto: enable 4096-bit RSA keys
RSA key size can be allowed to be as large as CFG_CORE_BIGNUM_MAX_BITS (4096 by default).
Signed-off-by: Jerome Forissier <jerome.forissier@linaro.org> Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org>
show more ...
|
| 0e3f6d6b | 09-Mar-2018 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: REE FS: temporary block allocation
Large memory allocations with malloc() can fail due to a fragmented heap. This is especially a problem when configured with pager as the heap is kept as smal
core: REE FS: temporary block allocation
Large memory allocations with malloc() can fail due to a fragmented heap. This is especially a problem when configured with pager as the heap is kept as small as possible in that configuration for obvious reasons.
This patch allocates the temporary block needed for reading and writing in REE FS tee_pager_alloc() instead when the pager is enabled.
Reviewed-by: Etienne Carriere <etienne.carriere@linaro.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
show more ...
|
| 820042a5 | 09-Mar-2018 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: tee_tadb_ta_read(): reduce tmp buffer
Large memory allocations with malloc() can fail due to a fragmented heap. The easiest way to avoid such failures is obviously to allocate smaller buffers.
core: tee_tadb_ta_read(): reduce tmp buffer
Large memory allocations with malloc() can fail due to a fragmented heap. The easiest way to avoid such failures is obviously to allocate smaller buffers.
Reduces the size of the temporary buffer used in tee_tadb_ta_read() when skipping over bytes in the payload. Instead of max 4k use 256 bytes. Impact on performance should be minimal as not much data are skipped in the payload.
Reviewed-by: Etienne Carriere <etienne.carriere@linaro.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
show more ...
|
| 80bf9131 | 26-Mar-2018 |
Jens Wiklander <jens.wiklander@linaro.org> |
core: syscall_authenc_enc_final() initialize tlen
Fixes problem with possibly leaking uninitialized stack content via tlen.
Fixes: https://github.com/OP-TEE/optee_os/issues/2214 Reviewed-by: Jerome
core: syscall_authenc_enc_final() initialize tlen
Fixes problem with possibly leaking uninitialized stack content via tlen.
Fixes: https://github.com/OP-TEE/optee_os/issues/2214 Reviewed-by: Jerome Forissier <jerome.forissier@linaro.org> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
show more ...
|
| e091b079 | 17-Oct-2017 |
Zeng Tao <prime.zeng@hisilicon.com> |
core: FS: storage: don't allow the object_id to reside in shared memory
According to the GP spec V1.1, the object_id in create/open/rename functions is not allowed to reside in the share memory, thi
core: FS: storage: don't allow the object_id to reside in shared memory
According to the GP spec V1.1, the object_id in create/open/rename functions is not allowed to reside in the share memory, this patch simply removes the TEE_MEMORY_ACCESS_ANY_OWNER flag to limit the object_id to TA private memory space.
Signed-off-by: Zeng Tao <prime.zeng@hisilicon.com> Reviewed-by: Etienne Carriere <etienne.carriere@linaro.org>
show more ...
|