added support for ca https cert chaining