use of org.kse.gui.error.DError in project keystore-explorer by kaikramer.
the class DNameConstraints method okPressed.
private void okPressed() {
List<GeneralSubtree> permittedSubtrees = jgsPermittedSubtrees.getGeneralSubtrees().getGeneralSubtrees();
List<GeneralSubtree> excludedSubtrees = jgsExcludedSubtrees.getGeneralSubtrees().getGeneralSubtrees();
GeneralSubtree[] permittedSubtreesArray = permittedSubtrees.toArray(new GeneralSubtree[permittedSubtrees.size()]);
GeneralSubtree[] excludedSubtreesArray = excludedSubtrees.toArray(new GeneralSubtree[excludedSubtrees.size()]);
NameConstraints nameConstraints = new NameConstraints(permittedSubtreesArray, excludedSubtreesArray);
try {
value = nameConstraints.getEncoded(ASN1Encoding.DER);
} catch (IOException ex) {
DError dError = new DError(this, ex);
dError.setLocationRelativeTo(this);
dError.setVisible(true);
return;
}
closeDialog();
}
use of org.kse.gui.error.DError in project keystore-explorer by kaikramer.
the class DNetscapeCaRevocationUrl method okPressed.
private void okPressed() {
String netscapeCaRevocationUrlStr = jtfNetscapeCaRevocationUrl.getText().trim();
if (netscapeCaRevocationUrlStr.length() == 0) {
JOptionPane.showMessageDialog(this, res.getString("DNetscapeCaRevocationUrl.ValueReq.message"), getTitle(), JOptionPane.WARNING_MESSAGE);
return;
}
DERIA5String netscapeCaRevocationUrl = new DERIA5String(netscapeCaRevocationUrlStr);
try {
value = netscapeCaRevocationUrl.getEncoded(ASN1Encoding.DER);
} catch (IOException ex) {
DError dError = new DError(this, ex);
dError.setLocationRelativeTo(this);
dError.setVisible(true);
return;
}
closeDialog();
}
Aggregations