Minor adjustments to cert pinning code