I wan to use libpam4j in a production system therefore I started to play with it. I created my first program to test basic funcionality of libpam4j:
public class App
{
public static void main( String[] args) throws Exception
{
UnixUser u = new PAM("login").authenticate(args[0], args[1]);
System.out.println("Groups : " + u.getGroups());
}
}
After ~10 execution the program surprisingly terminated with segfault. The segfault occured in the finalizer thread of JVM after the list of groups was printed to standard output.
I wan to use libpam4j in a production system therefore I started to play with it. I created my first program to test basic funcionality of libpam4j:
After ~10 execution the program surprisingly terminated with segfault. The segfault occured in the finalizer thread of JVM after the list of groups was printed to standard output.
The error file can be found here.
Relevant section:
So it seems the problem occured during Memory object dispose, used in the UnixUser class.
The program was executed with maven and:
Let me know if I have bad version issue.
Unfortunately after 50 execution the program crashed again in the finalizer JVM thread. The second error file is here.
The stack is different but the context is the same (during PAM.dispose()):
Now, the test phase is aborted because it is not a stable component.
Did you encounter same issues during development?
I hope this helps : I found a JVM crash issue at JNA (https://github.com/twall/jna/issues/24)
If you need furhter details do not hesitate to write me.