Content length header 1019

Re-adding JNDI token filtering tests (#730) and adding a test for verify content length headers are correctly sent (#1019).