[
https://issues.apache.org/jira/browse/KNOX-868?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15872396#comment-15872396
]
Mohammad Kamrul Islam commented on KNOX-868:
--------------------------------------------
There are two ways that we can consider this:
1. We can test if the 'java.library.path' is indeed passed to gateway service
as configured. Is there any unit test to verify this? Because we have a few
such properties already in 'gateway.sh'.
2. For complete testing, we need to write some C library compatible with JNI.
Then we need to build it during compilation -- because this is machine
dependent (hard to reuse some compiled so files). Then copy the so file into
ext/native/ directory. After that, we need to write some custom java validator
that calls the JNI
I think documenting the option #2 will be really helpful. If you prefer I can
upload a dev doc of how to use native library in validator or authentication.
Please let me know.
> Allow native library auto included through java.library.path property
> ----------------------------------------------------------------------
>
> Key: KNOX-868
> URL: https://issues.apache.org/jira/browse/KNOX-868
> Project: Apache Knox
> Issue Type: Improvement
> Reporter: Mohammad Kamrul Islam
> Assignee: Mohammad Kamrul Islam
> Fix For: 0.12.0
>
> Attachments: KNOX-868.1.patch
>
>
> Currently user can add custom jars by copying it into $GATEWAY_HOME/ext
> directory. However, there is no easy way to include native library (.so).
> The use case is: a lot of authentication mechanism libraries are implemented
> using C/C++ library. And user may want to integrate it with Knox.
> One of the option could be: user can add .so files into
> $GATEWAY_HOME/ext/native directory. At the same time, gateway service can
> include that directory through java.library.path property during start up.
> We can potentially use launcher.cfg to support it.
> Any other alternative approach?
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)