fix certdir error issue