TrustAnchor ta = new TrustAnchor(
ESTTestUtils.toJavaX509Certificate(
ESTTestUtils.readPemCertificate(
ESTServerUtils.makeRelativeToServerHome("/estCA/cacert.crt")
)
<BUG>), null);
est.setTlsTrustAnchors(Collections.singleton(ta));
</BUG>
PKCS10CertificationRequestBuilder pkcs10Builder = new JcaPKCS10CertificationRequestBuilder(new X500Name("CN=Test"), enrollmentPair.getPublic());
PKCS10CertificationRequest csr = pkcs10Builder.build(

TrustAnchor ta = new TrustAnchor(
ESTTestUtils.toJavaX509Certificate(
ESTTestUtils.readPemCertificate(
ESTServerUtils.makeRelativeToServerHome("/estCA/cacert.crt")
)
), null);
ESTService est = new ESTServiceBuilder("https://localhost:8443/.well-known/est/")
.withClientKeystore(clientKeyStore)
.withClientKeystorePassword(clientKeyStorePass)
.withTlsTrustAnchors(Collections.singleton(ta)).build();
PKCS10CertificationRequestBuilder pkcs10Builder = new JcaPKCS10CertificationRequestBuilder(new X500Name("CN=Test"), enrollmentPair.getPublic());
PKCS10CertificationRequest csr = pkcs10Builder.build(
