modify NewCtxFromFiles to automatically split and add certificate chains