Fixing x509 test and making sure it covers all QA requirements