Finite State Machine for Security

A generic FSM has been added to DDS Security Core component to realize authentication handshake process.
The list of the states and the transitions are given in the creation and the FSM is started with a start call.
Passing arguments to transition funstions is possible.
Timeout transitions are possible.

Signed-off-by: Kurtulus Oksuztepe <kurtulus.oksuztepe@adlinktech.com>
This commit is contained in:
Kurtulus Oksuztepe 2019-12-06 16:17:36 +01:00 committed by eboasson
parent 9481a75e9d
commit 0b1804e039
9 changed files with 1814 additions and 2 deletions

View file

@ -140,11 +140,20 @@ ddsrt_nonnull((1,2,3,4));
/**
* @brief Retrieve integer representation of the given thread id.
*
* @returns The integer representation of the given thread.
* @returns The integer representation of the current thread.
*/
DDS_EXPORT ddsrt_tid_t
ddsrt_gettid(void);
/**
* @brief Retrieve integer representation of the given thread id.
*
* @returns The integer representation of the given thread.
*/
DDS_EXPORT ddsrt_tid_t
ddsrt_gettid_for_thread( ddsrt_thread_t thread);
/**
* @brief Return thread ID of the calling thread.
*

View file

@ -83,6 +83,13 @@ ddsrt_gettid(void)
return status.xTaskNumber;
}
DDS_EXPORT ddsrt_tid_t
ddsrt_gettid_for_thread( ddsrt_thread_t thread)
{
return (ddsrt_tid_t)thread.task;
}
ddsrt_thread_t
ddsrt_thread_self(void)
{

View file

@ -346,6 +346,14 @@ ddsrt_gettid(void)
return tid;
}
ddsrt_tid_t
ddsrt_gettid_for_thread( ddsrt_thread_t thread)
{
return (ddsrt_tid_t) thread.v;
}
ddsrt_thread_t
ddsrt_thread_self(void)
{

View file

@ -173,6 +173,14 @@ ddsrt_gettid(void)
return GetCurrentThreadId();
}
ddsrt_tid_t
ddsrt_gettid_for_thread( ddsrt_thread_t thread)
{
return (ddsrt_tid_t) thread.tid;
}
ddsrt_thread_t
ddsrt_thread_self(
void)