Authen::NZRealMe::IdentityProvider - Class representing the NZ RealMe Login SAML IdP


This class is used to represent the SAML IdP (Identity Provider) which implements the RealMe Login service. An object of this class is initialised from the metadata-login-idp.xml in the configuration directory.



Constructor. Should not be called directly. Instead, call the idp method on the service provider object.

The conf_dir parameter must be provided. It specifies the full pathname of the directory containing the IdP metadata file.


Accessor for the type of service ("login" or "assertion") this IdP provides.


Accessor for the conf_dir parameter passed in to the constructor.


Accessor for the ID parameter in the Identity Provider metadata file.

single_signon_location ( binding )

Accessor for the SingleSignOnService parameter in the Service Provider metadata file.

The optional parameter binding is required if multiple SingleSignOnService elements are defined:

artifact => SAML 2.0 HTTP-Artifact binding
redirect => SAML 2.0 HTTP-Redirect binding
post => SAML 2.0 HTTP-POST binding


Accessor for the signing certificate (X509 format) text from the metadata file. If supplied with a service type, it will return the certificate appropriate to that type.


Accessor for the signing certificate (X509 format) text from the metadata file of the login service. This is used when resolving the opaque token from the identity assertion through the iCMS service.


Accessor for the ArtifactResolutionService parameter in the Service Provider metadata file. When calling this method, you must provide an index number (from the artifact).


Takes an XML document signed by the Identity provider and returns true if the signature is valid.


Takes a source ID string from an artifact to be resolved and confirms that it was generated by this Identity Provider. Returns true on successs, dies on error.


See Authen::NZRealMe for documentation index.


Copyright (c) 2010-2022 Enrolment Services, New Zealand Electoral Commission

Written by Grant McLean <>

This program is free software; you can redistribute it and/or modify it under the terms of either: the GNU General Public License as published by the Free Software Foundation; or the Artistic License.

See for more information.