From e291ba407480f4fb04036382b3dfef50dcb6579a Mon Sep 17 00:00:00 2001
From: Ludovic Poitou <ludovic.poitou@forgerock.com>
Date: Tue, 17 May 2016 10:16:59 +0000
Subject: [PATCH] Fix OPENDJ-3000 - Password Expiration notification calculation has integer overflow problem. Thanks Andy Wang for pointing to the issue and the fix.
---
opendj-server-legacy/src/main/java/org/opends/server/types/AccountStatusNotification.java | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/opendj-server-legacy/src/main/java/org/opends/server/types/AccountStatusNotification.java b/opendj-server-legacy/src/main/java/org/opends/server/types/AccountStatusNotification.java
index 29fb0b3..9b1e7e6 100644
--- a/opendj-server-legacy/src/main/java/org/opends/server/types/AccountStatusNotification.java
+++ b/opendj-server-legacy/src/main/java/org/opends/server/types/AccountStatusNotification.java
@@ -249,7 +249,7 @@
String string = secondsToTimeString(timeToExpiration).toString();
props.put(TIME_UNTIL_EXPIRATION, newArrayList(string));
- long expTime = System.currentTimeMillis() + (1000 * timeToExpiration);
+ long expTime = System.currentTimeMillis() + (1000L * timeToExpiration);
props.put(PASSWORD_EXPIRATION_TIME, newArrayList(new Date(expTime).toString()));
}
--
Gitblit v1.10.0