Authentication and authorization from java app

Nov 15, 2011 at 5:55 PM


I would like to create a authentication module which I could use in stand-alone Java apps. This module should authenticate users based on their username and password by connecting to active directory and if the user is authenticated then to return the info related to file access rights on a Windows network.

I have already retrieved ACL info for each file on disk using java 1.7 new nio package so I want to compare it with the info returned by the auth. module.

How to do that (could you please show some example)?

Also, what are the components from Waffle I have to install on each workstation disk?


Thank you, Milos

Nov 16, 2011 at 10:29 PM

You might want to use JNA directly for this. This is basically a series of wrapped up API calls, LogonUser gives you a token that you will need to impersonate and then Win32 CreateFile or other APIs can give you info that you want. Sorry, I don't have a detailed example - JNA is