PHP Class SimpleSAML_Metadata_MetaDataStorageHandler, simplesamlphp

Afficher le fichier Open project: simplesamlphp/simplesamlphp Class Usage Examples

Méthodes publiques

Méthode Description
getGenerated ( string $property, string $set ) : string This function is used to generate some metadata elements automatically.
getList ( string $set = 'saml20-idp-remote' ) : array This function lists all known metadata in the given set. It is returned as an associative array where the key is the entity id.
getMetaData ( string $index, string $set ) : array This function looks up the metadata for the given entity id in the given set. It will throw an exception if it is unable to locate the metadata.
getMetaDataConfig ( string $entityId, string $set ) : SimpleSAML_Configuration Retrieve the metadata as a configuration object.
getMetaDataConfigForSha1 ( string $sha1, string $set ) : null | SimpleSAML_Configuration Search for an entity's metadata, given the SHA1 digest of its entity ID.
getMetaDataCurrent ( string $set ) : array This function retrieves metadata for the current entity based on the hostname/path the request was directed to. It will throw an exception if it is unable to locate the metadata.
getMetaDataCurrentEntityID ( string $set, string $type = 'entityid' ) : string This function locates the current entity id based on the hostname/path combination the user accessed.
getMetadataHandler ( ) : SimpleSAML_Metadata_MetaDataStorageHandler This function retrieves the current instance of the metadata handler.
getPreferredEntityIdFromCIDRhint ( string $set, string $ip ) : string This method will call getPreferredEntityIdFromCIDRhint() on all of the sources.

Méthodes protégées

Méthode Description
__construct ( ) This constructor initializes this metadata storage handler. It will load and parse the configuration, and initialize the metadata source list.

Method Details

__construct() protected méthode

This constructor initializes this metadata storage handler. It will load and parse the configuration, and initialize the metadata source list.
protected __construct ( )

getGenerated() public méthode

This function is used to generate some metadata elements automatically.
public getGenerated ( string $property, string $set ) : string
$property string The metadata property which should be auto-generated.
$set string The set we the property comes from.
Résultat string The auto-generated metadata property.

getList() public méthode

This function lists all known metadata in the given set. It is returned as an associative array where the key is the entity id.
public getList ( string $set = 'saml20-idp-remote' ) : array
$set string The set we want to list metadata from.
Résultat array An associative array with the metadata from from the given set.

getMetaData() public méthode

This function looks up the metadata for the given entity id in the given set. It will throw an exception if it is unable to locate the metadata.
public getMetaData ( string $index, string $set ) : array
$index string The entity id we are looking up. This parameter may be NULL, in which case we look up the current entity id based on the current hostname/path.
$set string The set of metadata we are looking up the entity id in.
Résultat array The metadata array describing the specified entity.

getMetaDataConfig() public méthode

This function will throw an exception if it is unable to locate the metadata.
public getMetaDataConfig ( string $entityId, string $set ) : SimpleSAML_Configuration
$entityId string The entity ID we are looking up.
$set string The metadata set we are searching.
Résultat SimpleSAML_Configuration The configuration object representing the metadata.

getMetaDataConfigForSha1() public méthode

Search for an entity's metadata, given the SHA1 digest of its entity ID.
public getMetaDataConfigForSha1 ( string $sha1, string $set ) : null | SimpleSAML_Configuration
$sha1 string The SHA1 digest of the entity ID.
$set string The metadata set we are searching.
Résultat null | SimpleSAML_Configuration The metadata corresponding to the entity, or null if the entity cannot be found.

getMetaDataCurrent() public méthode

This function retrieves metadata for the current entity based on the hostname/path the request was directed to. It will throw an exception if it is unable to locate the metadata.
public getMetaDataCurrent ( string $set ) : array
$set string The set we want metadata from.
Résultat array An associative array with the metadata.

getMetaDataCurrentEntityID() public méthode

It will throw an exception if it is unable to locate the entity id.
public getMetaDataCurrentEntityID ( string $set, string $type = 'entityid' ) : string
$set string The set we look for the entity id in.
$type string Do you want to return the metaindex or the entityID. [entityid|metaindex]
Résultat string The entity id which is associated with the current hostname/path combination.

getMetadataHandler() public static méthode

The metadata handler will be instantiated if this is the first call to this function.
public static getMetadataHandler ( ) : SimpleSAML_Metadata_MetaDataStorageHandler
Résultat SimpleSAML_Metadata_MetaDataStorageHandler The current metadata handler instance.

getPreferredEntityIdFromCIDRhint() public méthode

This method will call getPreferredEntityIdFromCIDRhint() on all of the sources.
public getPreferredEntityIdFromCIDRhint ( string $set, string $ip ) : string
$set string Which set of metadata we are looking it up in.
$ip string IP address
Résultat string The entity id of a entity which have a CIDR hint where the provided IP address match.