Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
MaarchCourrier
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
24
Issues
24
List
Board
Labels
Milestones
Redmine
Redmine
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Maarch Labs
MaarchCourrier
Commits
54b92e0a
Commit
54b92e0a
authored
Apr 20, 2020
by
Guillaume Heurtier
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
FEAT #12091 TIME 0:10 fix keycloak connect
parent
d71cab04
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
12 additions
and
1 deletion
+12
-1
log.php
apps/maarch_entreprise/log.php
+1
-0
class_security.php
core/class/class_security.php
+1
-1
CoreConfigModel.php
src/core/models/CoreConfigModel.php
+10
-0
No files found.
apps/maarch_entreprise/log.php
View file @
54b92e0a
...
...
@@ -62,6 +62,7 @@ if (isset($_SESSION['web_cas_url'])) {
}
elseif
(
!
empty
(
$_SESSION
[
'keycloak'
][
'userId'
]))
{
$login
=
$_SESSION
[
'keycloak'
][
'userId'
];
$_REQUEST
[
'pass'
]
=
'maarch'
;
$method
=
'keycloak'
;
}
elseif
(
!
empty
(
$_SESSION
[
'sso'
][
'userId'
]))
{
$login
=
$_SESSION
[
'sso'
][
'userId'
];
$_REQUEST
[
'pass'
]
=
'maarch'
;
...
...
core/class/class_security.php
View file @
54b92e0a
...
...
@@ -124,7 +124,7 @@ class security extends Database
}
$check
=
\SrcCore\models\AuthenticationModel
::
authentication
([
'userId'
=>
$s_login
,
'password'
=>
$pass
]);
if
(
$check
||
(
in_array
(
$method
,
[
'ldap'
,
'shibboleth'
,
'cas'
,
'sso'
])
&&
$standardConnect
==
'false'
))
{
if
(
$check
||
(
in_array
(
$method
,
[
'ldap'
,
'shibboleth'
,
'cas'
,
'sso'
,
'keycloak'
])
&&
$standardConnect
==
'false'
))
{
$user
=
$uc
->
getWithComp
(
$s_login
,
$comp
,
$params
);
}
...
...
src/core/models/CoreConfigModel.php
View file @
54b92e0a
...
...
@@ -329,6 +329,16 @@ class CoreConfigModel
$keycloakConfig
[
'encryptionAlgorithm'
]
=
(
string
)
$loadedXml
->
ENCRYPTION_ALGORITHM
;
$keycloakConfig
[
'encryptionKeyPath'
]
=
(
string
)
$loadedXml
->
ENCRYPTION_KEY_PATH
;
$keycloakConfig
[
'encryptionKey'
]
=
(
string
)
$loadedXml
->
ENCRYPTION_KEY
;
if
(
empty
(
$keycloakConfig
[
'encryptionAlgorithm'
]))
{
$keycloakConfig
[
'encryptionAlgorithm'
]
=
null
;
}
if
(
empty
(
$keycloakConfig
[
'encryptionKeyPath'
]))
{
$keycloakConfig
[
'encryptionKeyPath'
]
=
null
;
}
if
(
empty
(
$keycloakConfig
[
'encryptionKey'
]))
{
$keycloakConfig
[
'encryptionKey'
]
=
null
;
}
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment