FreeRTOS-Kernel/FreeRTOS/Test/CBMC/proofs/ProcessDHCPReplies/Makefile.json
AniruddhaKanhere 4db195c916
Adding FreeRTOS+TCP CBMC proofs to FreeRTOS/FreeRTOS (#56)
ParseDNSReply is to be added in the next PR.
2020-04-21 15:40:08 -07:00

43 lines
1.3 KiB
JSON

# The proof depends on one parameter:
# BUFFER_SIZE is the size of the buffer being parsed
# The buffer size must be bounded because we must bound the number of
# iterations loops iterating over the buffer.
{
"ENTRY": "ProcessDHCPReplies",
################################################################
# Buffer size
# Reasonable sizes are BUFFER_SIZE > 241 = sizeof(DHCHMessage_t))
# Sizes smaller than this causes CBMC to fail in simplify_byte_extract
"BUFFER_SIZE": 300,
################################################################
# Buffer header: sizeof(DHCHMessage_t) = 241
"BUFFER_HEADER": 241,
################################################################
# Buffer payload
"BUFFER_PAYLOAD": "__eval 1 if {BUFFER_SIZE} <= {BUFFER_HEADER} else {BUFFER_SIZE} - {BUFFER_HEADER} + 2",
################################################################
"CBMCFLAGS": [
"--unwind 1",
"--unwindset memcmp.0:7,prvProcessDHCPReplies.0:{BUFFER_PAYLOAD}"
],
"OBJS":
[
"$(ENTRY)_harness.goto",
"$(FREERTOS)/../FreeRTOS-Plus/Source/FreeRTOS-Plus-TCP/FreeRTOS_DHCP.goto",
"$(FREERTOS)/../FreeRTOS-Plus/Source/FreeRTOS-Plus-TCP/portable/BufferManagement/BufferAllocation_2.goto",
"$(FREERTOS)/Source/event_groups.goto",
"$(FREERTOS)/Source/list.goto"
],
"DEF":
[
"BUFFER_SIZE={BUFFER_SIZE}"
]
}