try
{
String pkgName = "org.jboss.identity.federation.core.config";
InputStream stream = configurationFile.openStream();
JAXBElement<STSType> element = (JAXBElement<STSType>) JAXBUtil.getUnmarshaller(pkgName).unmarshal(stream);
STSType stsConfig = element.getValue();
STSConfiguration configuration = new JBossSTSConfiguration(stsConfig);
if(logger.isInfoEnabled())
logger.info("jboss-sts.xml configuration file loaded");
return configuration;
}