[
https://issues.apache.org/jira/browse/KNOX-1881?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Kevin Risden updated KNOX-1881:
-------------------------------
Resolution: Fixed
Status: Resolved (was: Patch Available)
> DefaultKeystoreService should use Java NIO API locking as well
> --------------------------------------------------------------
>
> Key: KNOX-1881
> URL: https://issues.apache.org/jira/browse/KNOX-1881
> Project: Apache Knox
> Issue Type: Improvement
> Components: KnoxCLI, Server
> Reporter: Robert Levas
> Assignee: Kevin Risden
> Priority: Critical
> Fix For: 1.3.0
>
> Time Spent: 10m
> Remaining Estimate: 0h
>
> The file locking mechanism in
> {{org.apache.knox.gateway.services.security.impl.DefaultKeystoreService}}
> today relies on read/write locks to prevent multiple threads from editing a
> single keystore. Java NIO API file locking adds the protection for
> reading/writing from multiple JVMs. Since DefaultKeystoreService is used in
> both gateway and knoxcli, we need to protect against this type of access
> happening at once.
> https://docs.oracle.com/javase/8/docs/api/java/nio/channels/FileLock.html
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)