Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
reg-app
Regapp
Commits
bf69aacd
Commit
bf69aacd
authored
Sep 03, 2015
by
michael.simon
Browse files
inital registry password check in ecp controller
parent
693e8faa
Changes
1
Hide whitespace changes
Inline
Side-by-side
bwreg-webapp/src/main/java/edu/kit/scc/webreg/rest/EcpController.java
View file @
bf69aacd
...
...
@@ -95,6 +95,7 @@ import edu.kit.scc.webreg.service.ServiceService;
import
edu.kit.scc.webreg.service.UserService
;
import
edu.kit.scc.webreg.service.UserUpdateService
;
import
edu.kit.scc.webreg.service.impl.AttributeMapHelper
;
import
edu.kit.scc.webreg.service.reg.PasswordUtil
;
import
edu.kit.scc.webreg.service.saml.AttributeQueryHelper
;
import
edu.kit.scc.webreg.service.saml.MetadataHelper
;
import
edu.kit.scc.webreg.service.saml.Saml2AssertionService
;
...
...
@@ -150,6 +151,9 @@ public class EcpController {
@Inject
private
AttributeMapHelper
attrHelper
;
@Inject
private
PasswordUtil
passwordUtil
;
@Inject
private
TextPropertyDao
textPropertyDao
;
...
...
@@ -277,6 +281,12 @@ public class EcpController {
private
Map
<
String
,
String
>
ecp
(
UserEntity
user
,
ServiceEntity
service
,
RegistryEntity
registry
,
String
password
,
HttpServletRequest
request
)
throws
RestInterfaceException
{
if
(
registry
.
getRegistryValues
().
containsKey
(
"userPassword"
))
{
logger
.
debug
(
"userPassword is set on registry. Comparing with given password"
);
Boolean
match
=
passwordUtil
.
comparePassword
(
password
,
registry
.
getRegistryValues
().
get
(
"userPassword"
));
logger
.
debug
(
"Passwords match: {}"
,
match
);
}
logger
.
debug
(
"Attempting ECP Authentication for {} and service {} (regId {})"
,
user
.
getEppn
(),
service
.
getShortName
(),
registry
.
getId
());
String
[]
splits
=
user
.
getEppn
().
split
(
"@"
);
...
...
Write
Preview
Supports
Markdown
0%
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!
Cancel
Please
register
or
sign in
to comment