Net::SPID::SAML::Out::LogoutRequest
version 0.13
use Net::SPID; # initialize our SPID object my $spid = Net::SPID->new(...); # get an IdP my $idp = $spid->get_idp($spid_session->idp_id); # generate a LogoutRequest my $logoutreq = $idp->logoutrequest( session => $spid_session, ); my $url = $logoutreq->redirect_url;
This class represents an outgoing LogoutRequest. You can use it to generate such a request in case you're initiating a logout procedure on behalf of your user.
This class is not supposed to be instantiated directly. You can craft a LogoutRequest by calling the "logoutrequest" in Net::SPID::SAML::IdP method on a Net::SPID::SAML::IdP object.
This method generates the message in XML format.
my $xml = $logoutreq->xml;
This method returns the full URL of the Identity Provider where user should be redirected in order to initiate their Single Logout. In SAML words, this implements the HTTP-Redirect binding.
my $url = $logoutreq->redirect_url;
This method returns an HTML page with a JavaScript auto-post command that submits the request to the Identity Provider in order to initiate their Single Logout. In SAML words, this implements the HTTP-POST binding.
my $html = $logoutreq->post_form;
Alessandro Ranellucci <aar@cpan.org>
This software is Copyright (c) 2018 by Alessandro Ranellucci.
This is free software, licensed under:
The (three-clause) BSD License
To install Net::SPID, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Net::SPID
CPAN shell
perl -MCPAN -e shell install Net::SPID
For more information on module installation, please visit the detailed CPAN module installation guide.