}
}
public static Encrypter getPublicKeyEncrypter(KeyData keyData) throws KeyczarException {
if (keyData.hasKeyczar()) {
RsaPublicKey key;
try {
key = KeyczarUtils.readRsaPublicKey(keyData.getKeyczar());
} catch (KeyczarException e) {
throw new IllegalStateException("Error reading public key", e);
}