/******************************************************************************* * Copyright 2017 Graz University of Technology * EAAF-Core Components has been developed in a cooperation between EGIZ, * A-SIT+, A-SIT, and Graz University of Technology. * * Licensed under the EUPL, Version 1.2 or - as soon they will be approved by * the European Commission - subsequent versions of the EUPL (the "Licence"); * You may not use this work except in compliance with the Licence. * You may obtain a copy of the Licence at: * https://joinup.ec.europa.eu/news/understanding-eupl-v12 * * Unless required by applicable law or agreed to in writing, software * distributed under the Licence is distributed on an "AS IS" basis, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the Licence for the specific language governing permissions and * limitations under the Licence. * * This product combines work with different licenses. See the "NOTICE" text * file for details on the various modules and licenses. * The "NOTICE" text file is part of the distribution. Any derivative works * that you distribute must include a readable copy of the "NOTICE" text file. *******************************************************************************/ /******************************************************************************* *******************************************************************************/ /******************************************************************************* *******************************************************************************/ /** * Licensed under the EUPL, Version 1.1 or - as soon they will be approved by * the European Commission - subsequent versions of the EUPL (the "Licence"); * You may not use this work except in compliance with the Licence. * You may obtain a copy of the Licence at: * http://www.osor.eu/eupl/ * * Unless required by applicable law or agreed to in writing, software * distributed under the Licence is distributed on an "AS IS" basis, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the Licence for the specific language governing permissions and * limitations under the Licence. * * This product combines work with different licenses. See the "NOTICE" text * file for details on the various modules and licenses. * The "NOTICE" text file is part of the distribution. Any derivative works * that you distribute must include a readable copy of the "NOTICE" text file. */ package at.gv.egiz.eaaf.core.api.idp; import java.util.Date; import at.gv.egiz.eaaf.core.api.idp.auth.data.IIdentityLink; /** * @author tlenz * */ public interface IAuthData { /** * BaseId transfer policy * * @return true if baseID transfer to service provider is allowed, otherwise false */ boolean isBaseIDTransferRestrication(); /** * Identifier of the IDP that authenicates the user * * @return */ String getAuthenticationIssuer(); /** * Timestamp of the authentication process * * @return */ Date getAuthenticationIssueInstant(); /** * Get string formated timestamp of the authentication process * * @return */ String getAuthenticationIssueInstantString(); /** * Familyname of the user * * @return */ String getFamilyName(); /** * Givenname of the user * * @return */ String getGivenName(); /** * Date of birth of the user * * @return date of birth or null no data of birth is available */ Date getDateOfBirth(); /** * String formated date of birth of the user with pattern yyyy-MM-dd * * * @return date of birth or '2999-12-31' if no data of birth is available */ String getFormatedDateOfBirth(); /** * Get bPK of the user * * @return */ String getBPK(); /** * Get sector for user's bPK * * * @return Sector identifier with prefix */ String getBPKType(); /** * Get baseId of this user * * @return */ String getIdentificationValue(); /** * Get type identifier of the baseId * By default, this type is urn:publicid:gv.at:baseid * * @return */ String getIdentificationType(); /** * Get the identityLink for the authenticated user * * @return IDL, or NULL if no IDL is available */ IIdentityLink getIdentityLink(); /** * Return LoA for this user authentication * * @return eIDAS LoA URI */ public String getEIDASQAALevel(); /** * Indicates that the user is a foreigner * * @return true if the user is foreigner, otherwise false */ boolean isForeigner(); /** * Code of the citizen country of the authenticated user * * @return */ String getCiticenCountryCode(); /** * Indicate that the authentication was done by using an active single sign-on session * * @return true if it an SSO session was used, otherwise false */ boolean isSsoSession(); /** * Date, up to which the SSO that was used for authentication is valid to * * @return */ Date getSsoSessionValidTo(); /** * SessionIndex, if it was an reauthentication on a service provider by using the same SSO session * * @return */ String getSessionIndex(); /** * SAML2 NameID for the user * * @return */ String getNameID(); /** * Format of the SAML2 NameID * * @return */ String getNameIDFormat(); /** * Get generic information for this authenticated user * * @param key Identifier for the generic data * @param clazz Type of the generic data * @return return the generic data of specific type, otherwise null */ public T getGenericData(String key, final Class clazz); }