use of org.xipki.ca.server.mgmt.api.PublisherEntry in project xipki by xipki.
the class PublisherAddCmd method execute0.
@Override
protected Object execute0() throws Exception {
if (conf == null && confFile != null) {
conf = new String(IoUtil.read(confFile));
}
PublisherEntry entry = new PublisherEntry(new NameId(null, name), type, conf);
String msg = "publisher " + name;
try {
caManager.addPublisher(entry);
println("added " + msg);
return null;
} catch (CaMgmtException ex) {
throw new CmdFailure("could not add " + msg + ", error: " + ex.getMessage(), ex);
}
}
Aggregations