throw new DeploymentException("Invalid login configuration:\n" + errors + "\nDescriptor: " + loginConfig.toString());
}
//find the login modules
Set<String> loginModuleNames = new HashSet<String>();
boolean atStart = true;
while ((atStart && xmlCursor.toFirstChild()) || (!atStart && xmlCursor.toNextSibling())) {
atStart = false;
XmlObject child = xmlCursor.getObject();
GerAbstractLoginModuleType abstractLoginModule = (GerAbstractLoginModuleType) child;
String controlFlag = abstractLoginModule.getControlFlag().toString();
boolean wrapPrincipals = (abstractLoginModule.isSetWrapPrincipals() && abstractLoginModule.getWrapPrincipals());