Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
maarchRM
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Redmine
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Maarch
maarchRM
Commits
3638aa4d
Verified
Commit
3638aa4d
authored
1 year ago
by
Arnaud Pauget
Committed by
Jerome Boucher
8 months ago
Browse files
Options
Downloads
Patches
Plain Diff
move vhost saml parameters into configuration file
parent
caefbdac
No related branches found
Branches containing commit
No related tags found
Tags containing commit
2 merge requests
!838
Rebase develop
,
!837
V3.0
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
core/Request/AbstractRequest.php
+3
-2
3 additions, 2 deletions
core/Request/AbstractRequest.php
src/bundle/auth/Controller/userAuthentication.php
+1
-1
1 addition, 1 deletion
src/bundle/auth/Controller/userAuthentication.php
with
4 additions
and
3 deletions
core/Request/AbstractRequest.php
+
3
−
2
View file @
3638aa4d
...
@@ -179,7 +179,7 @@ abstract class AbstractRequest
...
@@ -179,7 +179,7 @@ abstract class AbstractRequest
}
}
break
;
break
;
case
LAABS_SAML_AUTH
:
case
LAABS_SAML_AUTH
:
$samlLib
=
\laabs
::
getSAMLlib
()
;
$samlLib
=
\laabs
::
configuration
(
'auth'
)[
'samlLibrariesDir'
]
;
if
(
!
is_file
(
$samlLib
.
'/lib/_autoload.php'
))
{
if
(
!
is_file
(
$samlLib
.
'/lib/_autoload.php'
))
{
throw
new
\Exception
(
"Could not find saml autoload file '
$samlLib
/lib/_autoload.php'"
);
throw
new
\Exception
(
"Could not find saml autoload file '
$samlLib
/lib/_autoload.php'"
);
}
}
...
@@ -188,7 +188,8 @@ abstract class AbstractRequest
...
@@ -188,7 +188,8 @@ abstract class AbstractRequest
$as
->
requireAuth
();
$as
->
requireAuth
();
$attributes
=
$as
->
getAttributes
();
$attributes
=
$as
->
getAttributes
();
$login
=
$attributes
[
'http://schemas.xmlsoap.org/ws/2005/05/identity/claims/name'
][
0
];
$attribute
=
\laabs
::
configuration
(
'auth'
)[
'samlIdentitiClaims'
];
$login
=
$attributes
[
$attribute
][
0
];
if
(
empty
(
$login
))
{
if
(
empty
(
$login
))
{
var_dump
(
'Authentication Failed : login not present in attributes'
);
var_dump
(
'Authentication Failed : login not present in attributes'
);
}
}
...
...
This diff is collapsed.
Click to expand it.
src/bundle/auth/Controller/userAuthentication.php
+
1
−
1
View file @
3638aa4d
...
@@ -362,7 +362,7 @@ class userAuthentication
...
@@ -362,7 +362,7 @@ class userAuthentication
// Redirect to SSO disconnect is saml is enabled
// Redirect to SSO disconnect is saml is enabled
$authModes
=
\laabs
::
getAuthModes
();
$authModes
=
\laabs
::
getAuthModes
();
if
(
in_array
(
"saml"
,
$authModes
))
{
if
(
in_array
(
"saml"
,
$authModes
))
{
$samlLib
=
\laabs
::
getSAMLlib
()
;
$samlLib
=
\laabs
::
configuration
(
'auth'
)[
'samlLibrariesDir'
]
;
if
(
!
is_file
(
$samlLib
.
'/lib/_autoload.php'
))
{
if
(
!
is_file
(
$samlLib
.
'/lib/_autoload.php'
))
{
throw
new
\Exception
(
"Could not find saml autoload file '
$samlLib
/lib/_autoload.php'"
);
throw
new
\Exception
(
"Could not find saml autoload file '
$samlLib
/lib/_autoload.php'"
);
}
}
...
...
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