Skip to content

Commit

Permalink
minor profile fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
jrivard committed Jan 8, 2016
1 parent 8b80edc commit f3112c1
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 8 deletions.
7 changes: 7 additions & 0 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -368,6 +368,13 @@
<artifactId>jcl-core</artifactId>
<version>2.7</version>
</dependency>

<dependency>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-bundle-jaxrs</artifactId>
<version>2.7.7</version>
</dependency>

</dependencies>

<repositories>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@ protected void processAction(final PwmRequest pwmRequest)
return;

case enterCode:
handleEnterCodeRequest(pwmRequest, updateProfileBean, updateAttributesProfile);
handleEnterCodeRequest(pwmRequest, updateProfileBean);
break;
}
}
Expand Down Expand Up @@ -598,9 +598,7 @@ public void initializeToken(
pwmSession.getSessionStateBean().getLocale());

try {
TokenService.TokenSender.sendSmsToken(pwmApplication, null, macroMachine,
toNum, message, tokenKey);
System.out.println(tokenKey);
TokenService.TokenSender.sendSmsToken(pwmApplication, null, macroMachine, toNum, message, tokenKey);
} catch (Exception e) {
throw new PwmUnrecoverableException(new ErrorInformation(PwmError.ERROR_UNKNOWN));
}
Expand All @@ -613,7 +611,9 @@ public void initializeToken(

case EMAIL: {
final EmailItemBean configuredEmailSetting = config.readSettingAsEmail(
PwmSetting.EMAIL_NEWUSER_VERIFICATION, pwmSession.getSessionStateBean().getLocale());
PwmSetting.EMAIL_UPDATEPROFILE_VERIFICATION,
pwmRequest.getLocale()
);
final String emailAddressAttribute = pwmRequest.getConfig().readSettingAsString(PwmSetting.EMAIL_USER_MAIL_ATTRIBUTE);
final String toAddress = updateProfileBean.getFormData().get(emailAddressAttribute);

Expand Down Expand Up @@ -659,8 +659,7 @@ public void initializeToken(

private void handleEnterCodeRequest(
final PwmRequest pwmRequest,
final UpdateProfileBean updateProfileBean,
final UpdateAttributesProfile updateAttributesProfile
final UpdateProfileBean updateProfileBean
)
throws PwmUnrecoverableException, IOException, ServletException, ChaiUnavailableException
{
Expand Down
2 changes: 2 additions & 0 deletions src/main/java/password/pwm/util/LoginCookieManager.java
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,8 @@ public void writeLoginCookieToResponse(final PwmRequest pwmRequest) {
final ErrorInformation errorInformation = new ErrorInformation(PwmError.ERROR_UNKNOWN,errorMsg);
LOGGER.error(pwmRequest, errorInformation);
}

System.out.println(JsonUtil.serialize(pwmRequest.getPwmSession().getLoginInfoBean()));
}

public void readLoginInfoCookie(final PwmRequest pwmRequest) throws PwmUnrecoverableException {
Expand Down
2 changes: 1 addition & 1 deletion src/main/resources/password/pwm/AppProperty.properties
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ http.cookie.authRecord.age=604800
http.cookie.maxReadLength=10240
http.cookie.captchaSkip.name=captcha-key
http.cookie.captchaSkip.age=86400
http.cookie.login.name=LC
http.cookie.login.name=SESSION
http.parameter.forward=forwardURL
http.parameter.logout=logoutURL
http.parameter.theme=theme
Expand Down

0 comments on commit f3112c1

Please sign in to comment.