Commit ff9bb463 authored by Maxime Besson's avatar Maxime Besson

Make notification system take pdata url into account (#1893)

parent 2bce713f
Pipeline #6727 failed with stage
in 12 minutes
......@@ -133,7 +133,10 @@ sub checkNotifDuringAuth {
# Cipher id
$req->id( $self->p->HANDLER->tsv->{cipher}->encrypt( $req->id ) );
$self->p->rebuildCookies($req);
if ( not $req->data->{_url} and $req->env->{PATH_INFO} ne '/' ) {
if ( not $req->pdata->{_url}
and not $req->data->{_url}
and $req->env->{PATH_INFO} ne '/' )
{
$req->data->{_url} =
encode_base64( $self->conf->{portal} . $req->env->{PATH_INFO},
'' );
......
This diff is collapsed.
......@@ -118,11 +118,11 @@ SKIP: {
$file =~ s/json$/done/;
ok( -e $file, 'Notification was deleted' );
$pdata = 'lemonldappdata=' . expectCookie( $res, 'lemonldappdata' );
expectRedirection( $res, 'http://auth.idp.com/saml/singleSignOn' );
expectRedirection( $res, 'http://auth.idp.com/saml' );
ok(
$res = $issuer->_get(
'/saml/singleSignOn',
'/saml',
cookie => "lemonldap=$idpId; $pdata",
accept => 'text/html',
),
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment