Methods Summary |
---|
private com.sun.enterprise.config.serverbeans.validation.Result | performSetChecks(com.sun.enterprise.config.serverbeans.validation.Result result, com.sun.enterprise.config.ConfigContextEvent cce)
_logger.log(Level.CONFIG, "SsltTest performing set check");
_logger.log(Level.FINER, "SsltTest set - parent's class is \""+cce.getClassObject().getClass().getName()+"\"");
_logger.log(Level.FINER, "SsltTest set - ssl objects ssl2enabled attribute is set: \""+((Ssl) cce.getObject()).isSsl2Enabled()+"\"");
if (cce.getClassObject() instanceof IiopListener
&& ((Ssl) cce.getObject()).isSsl2Enabled()){
_logger.log(Level.FINER, "SsltTest set check - parent is an iiop-listener, and ssl2enabled attribute is being set to true");
ssl2NotAllowed(result);
}
return result;
|
private com.sun.enterprise.config.serverbeans.validation.Result | performUpdateChecks(com.sun.enterprise.config.serverbeans.validation.Result result, com.sun.enterprise.config.ConfigContextEvent cce)
final ConfigBean co = (ConfigBean) cce.getClassObject();
final String parentsDtdName = ((ConfigBean) co.parent()).dtdName();
_logger.log(Level.FINEST, "SslTest update - parent's DTD name is \""+parentsDtdName+"\"");
_logger.log(Level.FINEST, "SslTest update - attribute name is \""+cce.getName()+"\"");
_logger.log(Level.FINEST, "SslTest update - attribute value is \""+cce.getObject()+"\"");
if (parentsDtdName.equals(ServerTags.IIOP_LISTENER)
&& cce.getName().equals(ServerTags.SSL2_ENABLED)
&& ((String) cce.getObject()).equalsIgnoreCase("true")){
_logger.log(Level.FINER, "SslTest update check - parent is an iiop-listener, and ssl2enabled attribute is being set to true");
ssl2NotAllowed(result);
}
return result;
|
private void | ssl2NotAllowed(com.sun.enterprise.config.serverbeans.validation.Result result)
_logger.log(Level.CONFIG, "SslTest - an invalid attempt to enable ssl2 has been found. Returning an error");
result.failed(smh.getLocalString(getClass().getName()+".ssl2NotAllowed",
"ssl2 cannot be enabled for an iiop-listener"));
|
public com.sun.enterprise.config.serverbeans.validation.Result | validate(com.sun.enterprise.config.ConfigContextEvent cce)
_logger.log(Level.CONFIG, "SslTest validation");
final Result result = super.validate(cce); // Before doing custom validation do basic validation
final String choice = cce.getChoice();
if(choice.equals(StaticTest.UPDATE)) {
return performUpdateChecks(result, cce);
} else if (choice.equals(StaticTest.SET)) {
return performSetChecks(result,cce);
}
return result;
|