Skip to content

Commit

Permalink
Merge pull request #5030 from MattGill98/FISH-867
Browse files Browse the repository at this point in the history
FISH-867 Fix Servlet TCK Failures (Revert of FISH-779 and FISH-766)
  • Loading branch information
Cuba Stanley authored Dec 4, 2020
2 parents 9157152 + f073b93 commit ef0ae11
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -878,7 +878,7 @@ private boolean authenticate(String username, char[] password, X509Certificate[]
try {
if (certs != null) {
// Certificate credential used to authenticate
WebAndEjbToJaasBridge.doX500Login(createSubjectWithCerts(certs), realmName, moduleID);
WebAndEjbToJaasBridge.doX500Login(createSubjectWithCerts(certs), moduleID);
} else if (digestParams != null) {
// Digest credential used to authenticate
WebAndEjbToJaasBridge.login(new DigestCredentials(realmName, username, digestParams));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.util.ArrayList;
import java.util.Iterator;
import java.util.concurrent.atomic.AtomicInteger;
import java.util.logging.Level;
import java.util.logging.Logger;
Expand Down Expand Up @@ -471,11 +472,17 @@ private void processExpires() {
// SSO entries. However, this should be addressed separately.

try {
this.cache.forEach((ssoId, sso) -> {
if (sso.isEmpty() && sso.getLastAccessTime() < tooOld) {
removals.add(ssoId);
synchronized (cache) {

Iterator<String> it = cache.keySet().iterator();
while (it.hasNext()) {
String key = it.next();
SingleSignOnEntry sso = (SingleSignOnEntry) cache.get(key);
if (sso.isEmpty() && sso.getLastAccessTime() < tooOld) {
removals.add(key);
}
}
});
}

int removalCount = removals.size();
// S1AS8 6155481 START
Expand Down

0 comments on commit ef0ae11

Please sign in to comment.