Sufficient permissions missing if this code was ever to run with SecurityManager.
Cleanest approach appears to be use of InnocuousThread to create the cleaner/poller threads. Test case coverage extended to cover the SecurityManager scenario. Reviewer request: @valeriepeng ------------- Commit messages: - 8269034: AccessControlException for SunPKCS11 daemon threads Changes: https://git.openjdk.java.net/jdk/pull/4555/files Webrev: https://webrevs.openjdk.java.net/?repo=jdk&pr=4555&range=00 Issue: https://bugs.openjdk.java.net/browse/JDK-8269034 Stats: 112 lines in 5 files changed: 73 ins; 17 del; 22 mod Patch: https://git.openjdk.java.net/jdk/pull/4555.diff Fetch: git fetch https://git.openjdk.java.net/jdk pull/4555/head:pull/4555 PR: https://git.openjdk.java.net/jdk/pull/4555