It boils down to a case of eval(cafile) essentially. I'd argue that this is dangerous, but one could argue that the cafile can be trusted to not run arbitrary code. I'd add the version checks.