diff options
2 files changed, 15 insertions, 15 deletions
| diff --git a/id/ConfigWebTool/src/main/java/at/gv/egovernment/moa/id/configuration/data/oa/OAMOAIDPInterfederationConfig.java b/id/ConfigWebTool/src/main/java/at/gv/egovernment/moa/id/configuration/data/oa/OAMOAIDPInterfederationConfig.java index 5db9029bd..9431cc1fd 100644 --- a/id/ConfigWebTool/src/main/java/at/gv/egovernment/moa/id/configuration/data/oa/OAMOAIDPInterfederationConfig.java +++ b/id/ConfigWebTool/src/main/java/at/gv/egovernment/moa/id/configuration/data/oa/OAMOAIDPInterfederationConfig.java @@ -117,10 +117,10 @@ public class OAMOAIDPInterfederationConfig implements IOnlineApplicationData {  			}			  		} -		if (inboundSSO && MiscUtil.isEmpty(queryURL)) { -			log.info("Inbound Single Sign-On requires AttributQueryURL configuration."); -			errors.add(LanguageHelper.getErrorString("validation.interfederation.moaidp.queryurl.empty", request)); -		} +//		if (inboundSSO && MiscUtil.isEmpty(queryURL)) { +//			log.info("Inbound Single Sign-On requires AttributQueryURL configuration."); +//			errors.add(LanguageHelper.getErrorString("validation.interfederation.moaidp.queryurl.empty", request)); +//		}  		return errors;  	} diff --git a/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/auth/builder/AuthenticationDataBuilder.java b/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/auth/builder/AuthenticationDataBuilder.java index ed2cd3ecb..a8a7d0c51 100644 --- a/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/auth/builder/AuthenticationDataBuilder.java +++ b/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/auth/builder/AuthenticationDataBuilder.java @@ -256,21 +256,18 @@ public class AuthenticationDataBuilder implements MOAIDAuthConstants {  			} -			//collect attributes by using BackChannel communication -			String endpoint = idp.getIDPAttributQueryServiceURL();			 -			if (MiscUtil.isEmpty(endpoint)) { -				Logger.error("No AttributeQueryURL for interfederationIDP " + oaParam.getPublicURLPrefix()); -				throw new ConfigurationException("No AttributeQueryURL for interfederationIDP " + oaParam.getPublicURLPrefix(), null); -			} - -			 -			//TODO: check if response include attributes and map this attributes to requested attributes -			//TODO: insert code to parse Attributes from AuthnRespones for USP --> Zustelldienst  			Response intfResp = (Response) req.getInterfederationResponse().getResponse();  			AssertionAttributeExtractor extractor =   					new AssertionAttributeExtractor(intfResp);			 -			if (!extractor.containsAllRequiredAttributes()) {			 +			if (!extractor.containsAllRequiredAttributes()) {				 +				//collect attributes by using BackChannel communication +				String endpoint = idp.getIDPAttributQueryServiceURL();			 +				if (MiscUtil.isEmpty(endpoint)) { +					Logger.error("No AttributeQueryURL for interfederationIDP " + oaParam.getPublicURLPrefix()); +					throw new ConfigurationException("No AttributeQueryURL for interfederationIDP " + oaParam.getPublicURLPrefix(), null); +				} +				  				//build attributQuery request  				AttributeQuery query =   						AttributQueryBuilder.buildAttributQueryRequest(interfIDP.getUserNameID(), endpoint, attributs); @@ -308,6 +305,9 @@ public class AuthenticationDataBuilder implements MOAIDAuthConstants {  				//create assertion attribute extractor from AttributeQuery response  				extractor = new AssertionAttributeExtractor(intfResp); +			} else { +				Logger.info("Interfedation response include all attributes with are required. Skip AttributQuery request step. "); +				  			}  			//parse response information to authData  			buildAuthDataFormInterfederationResponse(authdata, session, extractor, oaParam);			 | 
