[JBoss JIRA] (JGRP-1893) ENCRYPT: Thread safety issues during key changes
by Tero Leppikangas (JIRA)
[ https://issues.jboss.org/browse/JGRP-1893?page=com.atlassian.jira.plugin.... ]
Tero Leppikangas commented on JGRP-1893:
----------------------------------------
Although the thread safety issue is quite obvious, it is extremely rare and it only comes to play when using ENCRYPT with changing ciphers.The ENCRYPT has far more serious issues related to the cipher change mechanism so we currently removed ENCRYPT from our stack.
For me it is ok to resolve this issue with won't fix.
> ENCRYPT: Thread safety issues during key changes
> ------------------------------------------------
>
> Key: JGRP-1893
> URL: https://issues.jboss.org/browse/JGRP-1893
> Project: JGroups
> Issue Type: Bug
> Reporter: Tero Leppikangas
> Assignee: Bela Ban
> Fix For: 3.6.2
>
>
> For symmetric encryption, ENCRYPT has members with shared state: secret key, version and ciphers. In order for to provide consistent state between different threads accessing these members, they should be synchronized.
> I have implemented one solution by wrapping the state in separate object which can be found here:
> https://github.com/tepitebson/JGroups/tree/ENCRYPT_Thread_safety
> I also have replaced the WeakHashMap holding the previous keys with Cache in google's guava library so my solution probably is not suitable for an official solution.
--
This message was sent by Atlassian JIRA
(v6.3.8#6338)
10 years, 1 month
[JBoss JIRA] (JGRP-1897) ENCRYPT might drop messages during key change
by Tero Leppikangas (JIRA)
[ https://issues.jboss.org/browse/JGRP-1897?page=com.atlassian.jira.plugin.... ]
Tero Leppikangas commented on JGRP-1897:
----------------------------------------
When starting to queue up messages when receiving a message with unknown cipher cannot work in situations where the joining node receives multicast messages encrypted (with previous key) after it already has acquired the new cipher, so the queuing solution is invalid.
Currently we decided to drop ENCRYPT from our stack and to figure out a way to encrypt data at some later point since using ENCRYPT with changing symmetric ciphers above AUTH is not working.
For me it is ok to resolve this with won't fix.
> ENCRYPT might drop messages during key change
> ---------------------------------------------
>
> Key: JGRP-1897
> URL: https://issues.jboss.org/browse/JGRP-1897
> Project: JGroups
> Issue Type: Bug
> Reporter: Tero Leppikangas
> Assignee: Bela Ban
> Fix For: 3.6.2
>
>
> ENCRYPT might drop some (unicast) messages encrypted with unknown key if the delivery of new view is delayed.
> This problem was noticed while doing some stress testing on the fix for JGRP-1893.
> When view changes, coordinator multicasts the new view after which is starts using new symmetric keys. If some node receives a message sent with the new key before the new view is received, the received message will be dropped since it cannot be decrypted.
> We thought of possible solutions to be.
> 1. Sender specific queue holding the messages received.
> 2. Starting to queue up messages until new view has been received
> I have implemented the second option which is quite straightforward, but it could lead into problems when receiving message with unknown key that is not related to coming view change.
> I wonder if there is another way to overcome this problem?
--
This message was sent by Atlassian JIRA
(v6.3.8#6338)
10 years, 1 month
[JBoss JIRA] (JBJCA-1239) codegenerator fails to create ra.xml for maven-rar-plugin
by Jeff Zhang (JIRA)
[ https://issues.jboss.org/browse/JBJCA-1239?page=com.atlassian.jira.plugin... ]
Jeff Zhang commented on JBJCA-1239:
-----------------------------------
@Steve, when cli shows:
Use annotations (Y/Yes/N/No) [Y]:
If you choose Y(es), generated code will use annotation and no ra.xml file.
But if you use N(o), the ra.xml will be generated.
I have verified and both are work well.
Could you try again? (Remeber to change <version.org.jboss.ironjacamar> to published version. like: 1.2.0.Final)
Thanks!
> codegenerator fails to create ra.xml for maven-rar-plugin
> ---------------------------------------------------------
>
> Key: JBJCA-1239
> URL: https://issues.jboss.org/browse/JBJCA-1239
> Project: IronJacamar
> Issue Type: Bug
> Components: Code Generator
> Affects Versions: 1.2.0.Final
> Reporter: Steve Gorman
> Assignee: Jeff Zhang
> Labels: maven
> Fix For: 1.2.1.Final
>
>
> After generating a maven project the ra.xml file is not part of the generated code but is referenced in the pom.xml
--
This message was sent by Atlassian JIRA
(v6.3.8#6338)
10 years, 1 month
[JBoss JIRA] (WFLY-4155) WatchService error when deploying an app to a remote file system
by Martin Malina (JIRA)
Martin Malina created WFLY-4155:
-----------------------------------
Summary: WatchService error when deploying an app to a remote file system
Key: WFLY-4155
URL: https://issues.jboss.org/browse/WFLY-4155
Project: WildFly
Issue Type: Bug
Components: IO, Web (Undertow)
Affects Versions: 8.1.0.Final
Reporter: Martin Malina
Assignee: Stuart Douglas
I'm getting this output when I deploy a simple web project to WildFly 8.1:
{code}
12:28:59,160 INFO [org.jboss.as.server.deployment.scanner] (DeploymentScanner-threads - 1) JBAS015003: Found dynproj.war in deployment directory. To trigger deployment create a file called dynproj.war.dodeploy
12:28:59,211 INFO [org.jboss.as.server.deployment] (MSC service thread 1-2) JBAS015876: Starting deployment of "dynproj.war" (runtime-name: "dynproj.war")
12:29:00,402 ERROR [io.undertow] (MSC service thread 1-1) UT005024: Could not register resource change listener for caching resource manager, automatic invalidation of cached resource will not work: java.lang.RuntimeException: java.io.IOException: Incorrect function.
at org.xnio.nio.WatchServiceFileSystemWatcher.watchPath(WatchServiceFileSystemWatcher.java:179)
at io.undertow.server.handlers.resource.FileResourceManager.registerResourceChangeListener(FileResourceManager.java:115) [undertow-core-1.0.15.Final.jar:1.0.15.Final]
at org.wildfly.extension.undertow.deployment.ServletResourceManager.registerResourceChangeListener(ServletResourceManager.java:80)
at io.undertow.server.handlers.resource.CachingResourceManager.<init>(CachingResourceManager.java:64) [undertow-core-1.0.15.Final.jar:1.0.15.Final]
at org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService.createServletConfig(UndertowDeploymentInfoService.java:505)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService.start(UndertowDeploymentInfoService.java:245)
at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1948)
at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1881)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [rt.jar:1.7.0_51]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [rt.jar:1.7.0_51]
at java.lang.Thread.run(Thread.java:744) [rt.jar:1.7.0_51]
Caused by: java.io.IOException: Incorrect function.
at sun.nio.fs.WindowsWatchService$Poller.implRegister(WindowsWatchService.java:405) [rt.jar:1.7.0_51]
at sun.nio.fs.AbstractPoller.processRequests(AbstractPoller.java:260) [rt.jar:1.7.0_51]
at sun.nio.fs.WindowsWatchService$Poller.run(WindowsWatchService.java:531) [rt.jar:1.7.0_51]
... 1 more
12:29:00,680 INFO [org.wildfly.extension.undertow] (MSC service thread 1-1) JBAS017534: Registered web context: /dynproj
12:29:00,750 INFO [org.jboss.as.server] (DeploymentScanner-threads - 2) JBAS018559: Deployed "dynproj.war" (runtime-name : "dynproj.war")
12:29:26,096 INFO [org.wildfly.extension.undertow] (MSC service thread 1-2) JBAS017535: Unregistered web context: /dynproj
12:29:26,157 INFO [org.hibernate.validator.internal.util.Version] (MSC service thread 1-1) HV000001: Hibernate Validator 5.1.0.Final
12:29:26,308 INFO [org.jboss.as.server.deployment] (MSC service thread 1-2) JBAS015877: Stopped deployment dynproj.war (runtime-name: dynproj.war) in 231ms
12:29:26,378 INFO [org.jboss.as.server] (DeploymentScanner-threads - 1) JBAS018558: Undeployed "dynproj.war" (runtime-name: "dynproj.war")
12:30:06,475 INFO [org.jboss.as.server.deployment.scanner] (DeploymentScanner-threads - 2) JBAS015003: Found dynproj.war in deployment directory. To trigger deployment create a file called dynproj.war.dodeploy
12:30:06,496 INFO [org.jboss.as.server.deployment] (MSC service thread 1-2) JBAS015876: Starting deployment of "dynproj.war" (runtime-name: "dynproj.war")
12:30:06,697 ERROR [io.undertow] (MSC service thread 1-2) UT005024: Could not register resource change listener for caching resource manager, automatic invalidation of cached resource will not work: java.lang.RuntimeException: java.io.IOException: Incorrect function.
at org.xnio.nio.WatchServiceFileSystemWatcher.watchPath(WatchServiceFileSystemWatcher.java:179)
at io.undertow.server.handlers.resource.FileResourceManager.registerResourceChangeListener(FileResourceManager.java:115) [undertow-core-1.0.15.Final.jar:1.0.15.Final]
at org.wildfly.extension.undertow.deployment.ServletResourceManager.registerResourceChangeListener(ServletResourceManager.java:80)
at io.undertow.server.handlers.resource.CachingResourceManager.<init>(CachingResourceManager.java:64) [undertow-core-1.0.15.Final.jar:1.0.15.Final]
at org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService.createServletConfig(UndertowDeploymentInfoService.java:505)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService.start(UndertowDeploymentInfoService.java:245)
at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1948)
at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1881)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [rt.jar:1.7.0_51]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [rt.jar:1.7.0_51]
at java.lang.Thread.run(Thread.java:744) [rt.jar:1.7.0_51]
Caused by: java.io.IOException: Incorrect function.
at sun.nio.fs.WindowsWatchService$Poller.implRegister(WindowsWatchService.java:405) [rt.jar:1.7.0_51]
at sun.nio.fs.AbstractPoller.processRequests(AbstractPoller.java:260) [rt.jar:1.7.0_51]
at sun.nio.fs.WindowsWatchService$Poller.run(WindowsWatchService.java:531) [rt.jar:1.7.0_51]
... 1 more
12:30:06,727 INFO [org.wildfly.extension.undertow] (MSC service thread 1-2) JBAS017534: Registered web context: /dynproj
12:30:06,767 INFO [org.jboss.as.server] (DeploymentScanner-threads - 1) JBAS018559: Deployed "dynproj.war" (runtime-name : "dynproj.war")
{code}
My setup is this:
OS X is my host OS, I'm running Windows 7 in virtualbox and have a shared folder from the host OS mounted in Windows. On this share, I have WildFly 8.1. I ran Eclipse Luna SR1 with JBoss Tools 4.2.1.CR1 installed, but it seems that this issue is not related to Eclipse. The main problem seems to be the remote FS. Dominik found this:
https://docs.oracle.com/javase/7/docs/api/java/nio/file/WatchService.html
{quote}
If a watched file is not located on a local storage device then it is implementation specific if changes to the file can be detected. In particular, it is not required that changes to files carried out on remote systems be detected.
{quote}
So in fact this behavior may be kind of expected. But maybe instead of throwing errors, the server might want to have a more graceful behavior?
Also, feel free to let me know if you need more details or if you want me to try different versions of WF or other server, but chances are this will happen in other versions as well.
--
This message was sent by Atlassian JIRA
(v6.3.8#6338)
10 years, 1 month