Commit 3c47fcb5 authored by Geoff Simmons's avatar Geoff Simmons

Test more decryption corner cases.

parent 0f45dfeb
......@@ -80,6 +80,14 @@ server s1 {
-hdr "Content-Length: 21"
sendhex "23 50 6c c6 d1 6d b6 5b f7 bb f3 a8 f7 8c 67 9b"
sendhex "00 00 10 00 00"
# No Content-Encoding header, VFP decrypt bypassed.
rxreq
txresp -body {foo bar baz quux}
# Content-Encoding header is not aes128gcm, VFP decrypt bypassed.
rxreq
txresp -gzipbody {foo bar baz quux}
} -start
logexpect l1 -v v1 -d 0 -g vxid -q "VfpAcct" {
......@@ -88,6 +96,14 @@ logexpect l1 -v v1 -d 0 -g vxid -q "VfpAcct" {
expect 0 = Debug {^ece_decrypt: record size 4096$}
expect * = VfpAcct {^ece_decrypt \d+ 0$}
expect * = End
expect 0 * Begin bereq
expect * = VfpAcct {^ece_decrypt 0 0$}
expect * = End
expect 0 * Begin bereq
expect * = VfpAcct {^ece_decrypt 0 0$}
expect * = End
} -start
client c1 {
......@@ -96,6 +112,17 @@ client c1 {
expect resp.status == 200
expect resp.http.Content-Encoding == <undef>
expect resp.bodylen == 0
txreq
rxresp
expect resp.status == 200
expect resp.http.Content-Encoding == <undef>
expect resp.body == {foo bar baz quux}
txreq
rxresp
expect resp.status == 200
expect resp.http.Content-Encoding == gzip
} -run
logexpect l1 -wait
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment