add method to set cert path directly