Using the A71CH/SE050 with multiple applications using the OpenSSL Engine

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

Using the A71CH/SE050 with multiple applications using the OpenSSL Engine

1,617件の閲覧回数
t_buening
Contributor I

Hello,

right now we have the problem that only one application at a time can use the Secure Element. We are using the Legacy OpenSSL Engine for the A71CH that comes with the newest version of the Plug&Trust Middleware (02.14.00). Everything is fine when I just run 'openssl rand -hex 10':

pastedImage_1.png

But when I start two different processes in the background like this: 'openssl rand -hex 10 & openssl rand -hex 10 &' then the connection fails:

pastedImage_2.png

The Terminal freezes and I have to get out using 'Ctrl + C'.

I have looked at the code and discovered that there is a function 'CryptoIpc_mutexInit in the simw-top/hostlib/hostLib/embSeEngine/src/ax_cryptoIpc.c file (Ipc probably stands for inter process communication?). So it seems to me that there is already code which solves this problem, right?

pastedImage_1.png

My current understanding is that the function will immediately return zero since the TGT_A71CH symbol gets defined in the cmake_options.cmake file by default. Therefore I removed the definition of TGT_A71CH in the cmake_options.cmake file and re-compiled the engine but nothing changed. So my question is the following: How can we use this code? Is it even complete (there are some TODO comments in the ax_cryptoIpc.c file)? Our expectation would be that we can start two processes which are using the Engine one of them gets the Mutex Lock and the second process waits for the first process to finish. After that the second process will get the Mutex and can do its work.

Regards

Tobias

ラベル(2)
1 返信

1,499件の閲覧回数
Kan_Li
NXP TechSupport
NXP TechSupport

Hi Tobias,

Yes, currently the implemented locking works only for thread-parallel execution.The process-parallel execution of the secure element interface is not supported yet.  We are working on a solution for this in the Plug&Trust MW. I will let you know when it is available.

Sorry for the inconvenience that has caused.

Have a great day,
Kan


-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!
- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------

 

0 件の賞賛
返信