Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
S
simplesamlphp
Manage
Activity
Members
Labels
Plan
Jira
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Analyze
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
This is an archived project. Repository and other project resources are read-only.
Show more breadcrumbs
Perun
Perun ProxyIdP
v1
simplesamlphp
Commits
aff4602b
Commit
aff4602b
authored
5 years ago
by
Tim van Dijen
Browse files
Options
Downloads
Patches
Plain Diff
Fix incorrect use of saml2 API
parent
a03d39df
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
lib/SimpleSAML/Session.php
+6
-7
6 additions, 7 deletions
lib/SimpleSAML/Session.php
with
6 additions
and
7 deletions
lib/SimpleSAML/Session.php
+
6
−
7
View file @
aff4602b
...
@@ -241,7 +241,7 @@ class Session implements \Serializable, Utils\ClearableState
...
@@ -241,7 +241,7 @@ class Session implements \Serializable, Utils\ClearableState
foreach
(
$values
as
$idx
=>
$value
)
{
foreach
(
$values
as
$idx
=>
$value
)
{
// this should be originally a DOMNodeList
// this should be originally a DOMNodeList
/* @var \SAML2\XML\saml\AttributeValue $value */
/* @var \SAML2\XML\saml\AttributeValue $value */
$this
->
authData
[
$authority
][
'Attributes'
][
$attribute
][
$idx
]
=
$value
->
e
lement
->
childNodes
;
$this
->
authData
[
$authority
][
'Attributes'
][
$attribute
][
$idx
]
=
$value
->
getE
lement
()
->
childNodes
;
}
}
}
}
}
}
...
@@ -263,6 +263,7 @@ class Session implements \Serializable, Utils\ClearableState
...
@@ -263,6 +263,7 @@ class Session implements \Serializable, Utils\ClearableState
// check if we have stored a session stored with the session handler
// check if we have stored a session stored with the session handler
try
{
try
{
/** @var \SimpleSAML\Session|null $session Help Scrutinizer with the correct type */
$session
=
self
::
getSession
();
$session
=
self
::
getSession
();
}
catch
(
\Exception
$e
)
{
}
catch
(
\Exception
$e
)
{
/*
/*
...
@@ -326,8 +327,8 @@ class Session implements \Serializable, Utils\ClearableState
...
@@ -326,8 +327,8 @@ class Session implements \Serializable, Utils\ClearableState
*
*
* @param string|null $sessionId The session we should get, or null to get the current session.
* @param string|null $sessionId The session we should get, or null to get the current session.
*
*
* @return Session|null The session that is stored in the session handler,
or null if the session wasn't
* @return
\SimpleSAML\
Session|null The session that is stored in the session handler,
* found.
*
or null if the session wasn't
found.
*/
*/
public
static
function
getSession
(
string
$sessionId
=
null
):
?Session
public
static
function
getSession
(
string
$sessionId
=
null
):
?Session
{
{
...
@@ -394,8 +395,8 @@ class Session implements \Serializable, Utils\ClearableState
...
@@ -394,8 +395,8 @@ class Session implements \Serializable, Utils\ClearableState
*
*
* Warning: never set self::$instance yourself, call this method instead.
* Warning: never set self::$instance yourself, call this method instead.
*
*
* @param Session $session The session to load.
* @param
\SimpleSAML\
Session $session The session to load.
* @return Session The session we just loaded, just for convenience.
* @return
\SimpleSAML\
Session The session we just loaded, just for convenience.
*/
*/
private
static
function
load
(
Session
$session
):
Session
private
static
function
load
(
Session
$session
):
Session
{
{
...
@@ -579,8 +580,6 @@ class Session implements \Serializable, Utils\ClearableState
...
@@ -579,8 +580,6 @@ class Session implements \Serializable, Utils\ClearableState
*/
*/
public
function
setRememberMeExpire
(
int
$expire
=
null
):
void
public
function
setRememberMeExpire
(
int
$expire
=
null
):
void
{
{
Assert
::
nullOrInteger
(
$expire
);
if
(
$expire
===
null
)
{
if
(
$expire
===
null
)
{
$expire
=
time
()
+
self
::
$config
->
getInteger
(
'session.rememberme.lifetime'
,
14
*
86400
);
$expire
=
time
()
+
self
::
$config
->
getInteger
(
'session.rememberme.lifetime'
,
14
*
86400
);
}
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment