fixes to meet our hardening tests

that is nice and simplifies the template