createJWT (FB)

FUNCTION_BLOCK createJWT EXTENDS CBML.ETrigTo

Function Block to create a JSON Web Tocken (JWT)

InOut:

Scope

Name

Type

Initial

Comment

Inherited from

Input

xExecute

BOOL

Rising edge: Starts defined operation
FALSE: Resets the defined operation after ready condition was reached

ETrigTo

udiTimeOut

UDINT

Max. operating time for executing [µs], 0: No operating time limit

ETrigTo

Output

xDone

BOOL

Ready condition reached

ETrigTo

xBusy

BOOL

Operation is running

ETrigTo

xError

BOOL

Error condition reached

ETrigTo

Input

header

JSON.JSONData

JSON representation of the JWT Header

payload

JSON.JSONData

JSON representation of the JWT Payload

sSecret

STRING(511)

‚‘

Secret for Symetric signing

sUseCaseName

STRING

‚‘

A name to identify this context in the security manager

sCommonName

STRING

‚‘

Certificate Common Name

pbJWT

POINTER TO BYTE

Pointer to JWT output

udiMaxJWTSize

UDINT

Maximum size of JWT output

eAlgorithm

JWTAlgorithm

JWT Algorithm

Output

udiJWTSize

UDINT

Size of JWT output

eError

Error

Output Error