Specific query string method to be compatible with buggy ADFS URL encoding (#677)
This commit is contained in:
parent
270254d007
commit
23627081c8
@ -435,7 +435,7 @@ sub checkMessage {
|
|||||||
if ( $self->param('SAMLResponse') ) {
|
if ( $self->param('SAMLResponse') ) {
|
||||||
|
|
||||||
# Response in query string
|
# Response in query string
|
||||||
$response = $self->query_string();
|
$response = $self->getQueryString();
|
||||||
$self->lmLog( "HTTP-REDIRECT: SAML Response $response",
|
$self->lmLog( "HTTP-REDIRECT: SAML Response $response",
|
||||||
'debug' );
|
'debug' );
|
||||||
|
|
||||||
@ -444,7 +444,7 @@ sub checkMessage {
|
|||||||
if ( $self->param('SAMLRequest') ) {
|
if ( $self->param('SAMLRequest') ) {
|
||||||
|
|
||||||
# Request in query string
|
# Request in query string
|
||||||
$request = $self->query_string();
|
$request = $self->getQueryString();
|
||||||
$self->lmLog( "HTTP-REDIRECT: SAML Request $request", 'debug' );
|
$self->lmLog( "HTTP-REDIRECT: SAML Request $request", 'debug' );
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -452,7 +452,7 @@ sub checkMessage {
|
|||||||
if ( $self->param('SAMLart') ) {
|
if ( $self->param('SAMLart') ) {
|
||||||
|
|
||||||
# Artifact in query string
|
# Artifact in query string
|
||||||
$artifact = $self->query_string();
|
$artifact = $self->getQueryString();
|
||||||
$self->lmLog( "HTTP-REDIRECT: SAML Artifact $artifact",
|
$self->lmLog( "HTTP-REDIRECT: SAML Artifact $artifact",
|
||||||
'debug' );
|
'debug' );
|
||||||
|
|
||||||
@ -2989,6 +2989,26 @@ sub sendSLOErrorResponse {
|
|||||||
return $self->sendLogoutResponseToServiceProvider( $logout, $method );
|
return $self->sendLogoutResponseToServiceProvider( $logout, $method );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
## @method string getQueryString()
|
||||||
|
# Return query string with or without CGI query_string() method
|
||||||
|
# @return query string
|
||||||
|
sub getQueryString {
|
||||||
|
my ($self) = splice @_;
|
||||||
|
|
||||||
|
my $query_string;
|
||||||
|
|
||||||
|
if ( $self->{samlUseQueryStringSpecific} ) {
|
||||||
|
my @pairs = split( /&/, $ENV{'QUERY_STRING'} );
|
||||||
|
$query_string = join( ';', @pairs );
|
||||||
|
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$query_string = $self->query_string();
|
||||||
|
}
|
||||||
|
|
||||||
|
return $query_string;
|
||||||
|
}
|
||||||
|
|
||||||
1;
|
1;
|
||||||
|
|
||||||
__END__
|
__END__
|
||||||
@ -3346,6 +3366,10 @@ Find and delete SAML sessions bounded to a primary session
|
|||||||
|
|
||||||
Send an SLO error response
|
Send an SLO error response
|
||||||
|
|
||||||
|
=head2 getQueryString
|
||||||
|
|
||||||
|
Get query string with or without CGI query_string() method
|
||||||
|
|
||||||
=head1 SEE ALSO
|
=head1 SEE ALSO
|
||||||
|
|
||||||
L<Lemonldap::NG::Portal::AuthSAML>, L<Lemonldap::NG::Portal::UserDBSAML>
|
L<Lemonldap::NG::Portal::AuthSAML>, L<Lemonldap::NG::Portal::UserDBSAML>
|
||||||
|
Loading…
Reference in New Issue
Block a user