use of org.xipki.ca.server.mgmt.api.CaMgmtException in project xipki by xipki.
the class CaProfileAddCmd method execute0.
@Override
protected Object execute0() throws Exception {
for (String profileName : profileNames) {
String msg = StringUtil.concat("certificate profile ", profileName, " to CA ", caName);
try {
caManager.addCertprofileToCa(profileName, caName);
println("associated " + msg);
} catch (CaMgmtException ex) {
throw new CmdFailure("could not associate " + msg + ", error: " + ex.getMessage(), ex);
}
}
return null;
}
use of org.xipki.ca.server.mgmt.api.CaMgmtException in project xipki by xipki.
the class CaRemoveCmd method execute0.
@Override
protected Object execute0() throws Exception {
String msg = "CA " + name;
try {
caManager.removeCa(name);
println("removed " + msg);
return null;
} catch (CaMgmtException ex) {
throw new CmdFailure("could not remove " + msg + ", error: " + ex.getMessage(), ex);
}
}
use of org.xipki.ca.server.mgmt.api.CaMgmtException in project xipki by xipki.
the class EnvAddCmd method execute0.
@Override
protected Object execute0() throws Exception {
String msg = "environment parameter " + name;
try {
caManager.addEnvParam(name, value);
println("added " + msg);
return null;
} catch (CaMgmtException ex) {
throw new CmdFailure("could not add " + msg + ", error: " + ex.getMessage(), ex);
}
}
use of org.xipki.ca.server.mgmt.api.CaMgmtException in project xipki by xipki.
the class EnvRemoveCmd method execute0.
@Override
protected Object execute0() throws Exception {
String msg = "environment parameter " + name;
try {
caManager.removeEnvParam(name);
println("removed " + msg);
return null;
} catch (CaMgmtException ex) {
throw new CmdFailure("could not remove " + msg + ", error: " + ex.getMessage(), ex);
}
}
use of org.xipki.ca.server.mgmt.api.CaMgmtException in project xipki by xipki.
the class ExportConfCmd method execute0.
@Override
protected Object execute0() throws Exception {
String msg = "configuration to file " + confFile;
try {
caManager.exportConf(confFile, caNames);
println("exported " + msg);
return null;
} catch (CaMgmtException ex) {
throw new CmdFailure("could not export " + msg + ", error: " + ex.getMessage(), ex);
}
}
Aggregations