summaryrefslogtreecommitdiff
path: root/FreeRTOS-Plus/Test/CBMC/proofs/ReadNameField/Makefile.json
diff options
context:
space:
mode:
Diffstat (limited to 'FreeRTOS-Plus/Test/CBMC/proofs/ReadNameField/Makefile.json')
-rw-r--r--FreeRTOS-Plus/Test/CBMC/proofs/ReadNameField/Makefile.json54
1 files changed, 54 insertions, 0 deletions
diff --git a/FreeRTOS-Plus/Test/CBMC/proofs/ReadNameField/Makefile.json b/FreeRTOS-Plus/Test/CBMC/proofs/ReadNameField/Makefile.json
new file mode 100644
index 000000000..05f3d4208
--- /dev/null
+++ b/FreeRTOS-Plus/Test/CBMC/proofs/ReadNameField/Makefile.json
@@ -0,0 +1,54 @@
+{
+ "ENTRY": "ReadNameField",
+
+################################################################
+#Enable DNS callbacks or else ReadNameField is not defined
+ "callbacks": "1",
+
+################################################################
+# This is the network buffer size. Set to any positive value.
+ "NETWORK_BUFFER_SIZE" : "10",
+
+################################################################
+# This is the size of the buffer into which the name is copied.
+# Set to any positive value.
+# In the source, NAME_SIZE=254 and NETWORK_BUFFER_SIZE >> NAME_SIZE
+# In the proof, NAME_SIZE >= 4 required for good coverage.
+ "NAME_SIZE": "6",
+
+################################################################
+# Loop prvReadNameField.0:
+# should be min of buffer size and name size
+# but loop must be unwound at least once, so max of this and 1+1
+ "READLOOP0": "prvReadNameField.0",
+ "READLOOP0_UNWIND": "__eval max(2, min({NETWORK_BUFFER_SIZE}, {NAME_SIZE}+1))",
+
+################################################################
+# Loop prvReadNameField.1:
+# should be min of buffer size and name size
+# but loop must be unwound at least twice, so max of this and 2+1
+ "READLOOP1": "prvReadNameField.1",
+ "READLOOP1_UNWIND": "__eval max(3, min({NETWORK_BUFFER_SIZE}, {NAME_SIZE}))",
+
+################################################################
+
+ "CBMCFLAGS":
+ [
+ "--unwind 1",
+ "--unwindset {READLOOP0}:{READLOOP0_UNWIND},{READLOOP1}:{READLOOP1_UNWIND}"
+ ],
+
+ "OBJS":
+ [
+ "$(ENTRY)_harness.goto",
+ "$(FREERTOS)/../FreeRTOS-Plus/Source/FreeRTOS-Plus-TCP/FreeRTOS_DNS.goto"
+ ],
+
+ "DEF":
+ [
+ "NETWORK_BUFFER_SIZE={NETWORK_BUFFER_SIZE}",
+ "NAME_SIZE={NAME_SIZE}",
+ "ipconfigDNS_USE_CALLBACKS={callbacks}",
+ "ipconfigDNS_CACHE_NAME_LENGTH=254"
+ ]
+}