out.trustKeys = Joiner.on(",").join(trustKeys);
}
Authenticator authenticator = in.getAuthenticator();
if (authenticator instanceof DirectAuthenticator) {
DirectAuthenticator directAuthenticator = (DirectAuthenticator) authenticator;
DirectAuthenticationToken token = directAuthenticator.getAuthenticationToken();
out.secret = Secret.build(Hex.toHex(FathomdbCrypto.serialize(token.getSecret())));
out.token = token.getToken();
} else {
throw new UnsupportedOperationException();
}
return out;
}