public synchronized void trust(Certificate cert) {
	clear();
	try {
	    trusted.setCertificateEntry("cert-" + tserial++, cert);
	} catch(KeyStoreException e) {
	    /* The keystore should have been initialized and should
	     * not have the generated alias, so this should not
	     * happen. */
	    throw(new RuntimeException(e));
	}
    }