-- order.
{ var = "bulk", name = "Bulk transform",
- type = "enum", allowed = { "v0", "iiv", "naclbox" },
+ type = "enum", allowed = { "v0", "iiv", "naclbox", "aead" },
descr = "Bulk cryptographic transform", default = "v0" },
{ var = "hashsz", name = "Hash length", type = "int", min = 0,
descr = "Hash length (bytes)", default = 20 },
-- Dissect a ciphertext of some particular kind.
local dissect_ct = { }
+function dissect_ct.aead(buf, tree, pos, sz)
+ tree:add(PF["tripe.ciphertext.tag"], buf(pos, C.tagsz)); pos = pos + C.tagsz
+ tree:add(PF["tripe.ciphertext.seq"], buf(pos, 4)); pos = pos + 4
+ tree:add(PF["tripe.ciphertext.body"], buf(pos, sz - pos))
+end
function dissect_ct.naclbox(buf, tree, pos, sz)
tree:add(PF["tripe.ciphertext.tag"], buf(pos, 16)); pos = pos + 16
tree:add(PF["tripe.ciphertext.seq"], buf(pos, 4)); pos = pos + 4
dissect = { dissect_misc_ciphertext } },
[5] = { label = "MISC_GREET", info = "greeting",
dissect = { dissect_misc_payload } },
+ [6] = { label = "MISC_BYE", info = "disconnect notification",
+ dissect = { dissect_misc_ciphertext } },
}
}
}