This website uses cookies. By clicking Accept, you consent to the use of cookies. Click Here to learn more about how we use cookies.
Turn on suggestions
Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.
- Revenera Community
- :
- InstallAnywhere
- :
- InstallAnywhere Forum
- :
- verifying windows credentials via C DLL
Subscribe
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Subscribe
- Mute
- Printer Friendly Page
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Jun 14, 2010
03:49 PM
verifying windows credentials via C DLL
Hi folks,
In a previous installer, we have code that calls a Windows DLL to verify user credentials. The LibraryLoader class is utilized to do so.
I can't seem to find an equivalent method for doing this.
Generically I see this as calling a Windows DLL from a custom action.
What would be a solution to this problem, either specifically or generically?
Thanks!
- john
In a previous installer, we have code that calls a Windows DLL to verify user credentials. The LibraryLoader class is utilized to do so.
I can't seem to find an equivalent method for doing this.
Generically I see this as calling a Windows DLL from a custom action.
What would be a solution to this problem, either specifically or generically?
Thanks!
- john
(6) Replies
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Jun 15, 2010
05:49 AM
There used to be an IsUserAdmin plugin, but it's been a while since it has been discontinued and thus removed from the list of downloadable files & utilities. I'm afraid I don't understand though why exactly the previous method you used no longer works. Nevertheless, there is a method in the IA API that allows you to check if the user that has launched the installer is Windows admin or not (it's in an API that has been inherited from InstallShield, actually).
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Jun 29, 2010
12:49 PM
The problem is not if the current user is an admin or not. The problem to solve is validating that any user-supplied account name and password exists and is valid.
In my scenario, the user can choose if a service to be installed is run as LocalSystem or as a named account. We would like to verify that the specified user exists and the password is valid before registering the service with that information.
In my scenario, the user can choose if a service to be installed is run as LocalSystem or as a named account. We would like to verify that the specified user exists and the password is valid before registering the service with that information.
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Jun 29, 2010
11:56 PM
AFAIK, there is no builtin support for that, so you would need custom code, unless there are platform specific functions to do that.
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Aug 02, 2010
01:12 PM
My only issue at the moment is making a Windows DLL be available during the pre-install phase.
I've seen workarounds of:
1) creating a seperate install for it and run it prior to the pre-install step (yuck!)
2) modifying the JVM zip file to include the file (ewwww)
Any better solutions?
Thanks!
- john
I've seen workarounds of:
1) creating a seperate install for it and run it prior to the pre-install step (yuck!)
2) modifying the JVM zip file to include the file (ewwww)
Any better solutions?
Thanks!
- john
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Aug 03, 2010
05:13 PM
There is a plugin called ExtractToFile (available on this page: http://www.flexerasoftware.com/products/installanywhere/files-utilities.htm) which allows access to a file inside the installer.
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Aug 31, 2010
06:27 PM
You can use JNI to call from your IA Custom Code into your C DLL.
Call getResource to load the resource URL:
URL CustomCodePanelProxy.getResource("MyCDLL.dll");
Call saveURLContentToFile to get the DLL out of the installer and onto disk:
File dll = CustomCodePanelProxy.saveURLContentToFile(ourURL);
The load the DLL into memory:
System.load(dll.getAbsolutePath());
Then call your JNI method in your C DLL as if it were a local Java Method.
--Terry
Call getResource to load the resource URL:
URL CustomCodePanelProxy.getResource("MyCDLL.dll");
Call saveURLContentToFile to get the DLL out of the installer and onto disk:
File dll = CustomCodePanelProxy.saveURLContentToFile(ourURL);
The load the DLL into memory:
System.load(dll.getAbsolutePath());
Then call your JNI method in your C DLL as if it were a local Java Method.
--Terry