Image parser context definition.

Public Attributes#

uint8_t

Buffer contents.

uint8_t

Amount of bytes present in buffer.

uint8_t

Current reading offset into the buffer (circular)

uint8_t

Parser flags.

bool

Parser is currently inside an encrypted tag.

bool

Parser has received and verified signature.

uint8_t

Parser has received bootloader upgrade tag.

State of the GBL parser state machine.

void *

AES-CCM decryption (= AES-CTR) context.

void *

SHA256 hashing context.

size_t

Total length of the tag currently being parsed.

size_t

Current offset into tag being parsed.

size_t

Total length of current encrypted data block.

size_t

Offset into current encrypted data block.

uint32_t

Current address the image needs to be written to.

uint32_t

Current offset of metadata/bootloader being handled (starts at 0)

uint8_t

Withheld application data.

uint8_t

Withheld bootloader upgrade data during app parsing.

uint8_t

Withheld bootloader upgrade data during bootloader parsing.

uint32_t

Running CRC-32 over the incoming GBL file.

uint32_t

Context for custom tag.

uint8_t

Current tag order.

uint8_t

Reserved flags.

Public Attribute Documentation#

internalBuffer#

uint8_t ParserContext_t::internalBuffer[64]

Buffer contents.


Definition at line 218 of file platform/bootloader/parser/gbl/btl_gbl_parser.h

bytesInInternalBuffer#

uint8_t ParserContext_t::bytesInInternalBuffer

Amount of bytes present in buffer.


Definition at line 220 of file platform/bootloader/parser/gbl/btl_gbl_parser.h

internalBufferOffset#

uint8_t ParserContext_t::internalBufferOffset

Current reading offset into the buffer (circular)


Definition at line 222 of file platform/bootloader/parser/gbl/btl_gbl_parser.h

flags#

uint8_t ParserContext_t::flags

Parser flags.


Definition at line 224 of file platform/bootloader/parser/gbl/btl_gbl_parser.h

inEncryptedContainer#

bool ParserContext_t::inEncryptedContainer

Parser is currently inside an encrypted tag.


Definition at line 226 of file platform/bootloader/parser/gbl/btl_gbl_parser.h

gotSignature#

bool ParserContext_t::gotSignature

Parser has received and verified signature.


Definition at line 228 of file platform/bootloader/parser/gbl/btl_gbl_parser.h

receivedFlags#

uint8_t ParserContext_t::receivedFlags

Parser has received bootloader upgrade tag.


Definition at line 230 of file platform/bootloader/parser/gbl/btl_gbl_parser.h

internalState#

GblParserState_t ParserContext_t::internalState

State of the GBL parser state machine.


Definition at line 232 of file platform/bootloader/parser/gbl/btl_gbl_parser.h

aesContext#

void* ParserContext_t::aesContext

AES-CCM decryption (= AES-CTR) context.


Definition at line 234 of file platform/bootloader/parser/gbl/btl_gbl_parser.h

shaContext#

void* ParserContext_t::shaContext

SHA256 hashing context.


Definition at line 236 of file platform/bootloader/parser/gbl/btl_gbl_parser.h

lengthOfTag#

size_t ParserContext_t::lengthOfTag

Total length of the tag currently being parsed.


Definition at line 238 of file platform/bootloader/parser/gbl/btl_gbl_parser.h

offsetInTag#

size_t ParserContext_t::offsetInTag

Current offset into tag being parsed.


Definition at line 240 of file platform/bootloader/parser/gbl/btl_gbl_parser.h

lengthOfEncryptedTag#

size_t ParserContext_t::lengthOfEncryptedTag

Total length of current encrypted data block.


Definition at line 242 of file platform/bootloader/parser/gbl/btl_gbl_parser.h

offsetInEncryptedTag#

size_t ParserContext_t::offsetInEncryptedTag

Offset into current encrypted data block.


Definition at line 244 of file platform/bootloader/parser/gbl/btl_gbl_parser.h

programmingAddress#

uint32_t ParserContext_t::programmingAddress

Current address the image needs to be written to.


Definition at line 246 of file platform/bootloader/parser/gbl/btl_gbl_parser.h

tagAddress#

uint32_t ParserContext_t::tagAddress

Current offset of metadata/bootloader being handled (starts at 0)


Definition at line 248 of file platform/bootloader/parser/gbl/btl_gbl_parser.h

withheldApplicationVectors#

uint8_t ParserContext_t::withheldApplicationVectors[24]

Withheld application data.


Definition at line 250 of file platform/bootloader/parser/gbl/btl_gbl_parser.h

withheldUpgradeVectors#

uint8_t ParserContext_t::withheldUpgradeVectors[4]

Withheld bootloader upgrade data during app parsing.


Definition at line 252 of file platform/bootloader/parser/gbl/btl_gbl_parser.h

withheldBootloaderVectors#

uint8_t ParserContext_t::withheldBootloaderVectors[4]

Withheld bootloader upgrade data during bootloader parsing.


Definition at line 254 of file platform/bootloader/parser/gbl/btl_gbl_parser.h

fileCrc#

uint32_t ParserContext_t::fileCrc

Running CRC-32 over the incoming GBL file.


Definition at line 256 of file platform/bootloader/parser/gbl/btl_gbl_parser.h

customTagId#

uint32_t ParserContext_t::customTagId

Context for custom tag.


Definition at line 258 of file platform/bootloader/parser/gbl/btl_gbl_parser.h

currentTagOrder#

uint8_t ParserContext_t::currentTagOrder

Current tag order.


Definition at line 292 of file platform/bootloader/parser/gbl/btl_gbl_parser.h

reservedFlags#

uint8_t ParserContext_t::reservedFlags[3]

Reserved flags.


Definition at line 294 of file platform/bootloader/parser/gbl/btl_gbl_parser.h