Jump to content


This is a ready-only archive of the InstallSite Forum. You cannot post any new content here. / Dies ist ein Archiv des InstallSite Forums. Hier können keine neuen Beiträge veröffentlicht werden.
Photo

how 2 make ISbasic msi inherit deployer's


3 replies to this topic

k3nn

k3nn
  • Members
  • 9 posts

Posted 11 August 2005 - 14:28

i made an installer that is only installable with admin account. how did this came about? i don't know, i wish to create an installer that is "friendly" with non-admin account, what are the requirements to do this?

I have used the HKLM regkeys to install certain keys my app need, and delete files if it sees any part of it's old self.

Currently I deploy the installer through the network and install itself via an agent with system privilege. The thing is: when the current user is non-admin my installer inherits that account, instead of the agent's account; this will never let my installer finish. But if the current user is admin, all goes well.

I have 2 options:

1) make the installer non-admin installable. how?
2) let the installer inhherit the agent's privilege. how?

which of the 2 will be easier? thanks.

Zweitze

Zweitze
  • Full Members
  • 522 posts

Posted 11 August 2005 - 19:38

If you want your install to work with minimal priviliges, make sure that it only writes to the profile of the active user (containing Desktop, My Documents etc.), and registry keys to HKEY_CURRENT_USER hive. However, in environments with roaming profiles your install may not survive the next logoff/logon.

If that's not possible, you should use install with elevated rights. This is a policy, typically granted by the administrator. He has to set this policy (called "AlwaysInstallElevated") for the user AND the computer where the software is installed. See http://msdn.microsof...allelevated.asp


k3nn

k3nn
  • Members
  • 9 posts

Posted 12 August 2005 - 03:41

thanks for the reply sir.

If i let the agent set AlwaysInstallElevated to 1 for both the keys, I would assume the installer would be fine now. I'll test this and see what happens.

hmm, the agent reports it can't set the HK current user's AlwaysInstallElevated key. The installer still can't continue even if the HK local machine's AlwaysInstallElevated is set. The user currently logged in is a non-admin.

I suppose the problem now is how to temporarily grant installer rights to non-admins? changing to non-admin version of the basic msi is a no go. the app needs to modify HKLM not HKCU, as it will lose info on...you're right: the next login...

Edited by k3nn, 12 August 2005 - 07:12.


k3nn

k3nn
  • Members
  • 9 posts

Posted 19 August 2005 - 11:51

I've been able to modify the agent to inherit its privilege (system account) and execute the installer to install on a machine with a non-admin user currently logged in. But it didn't push through; looking at the install log I found it couldn't install the isscript.msi (installscript engine).

I search for the keyword error "GetInstallDriver, Can not find InstallDriver in ROT table, Return Code" and found Christopher Painter's solution here:

_http://community.installshield.com/showthread.php?t=119334&page=2&pp=5

Basically the script engine uses the interactive user's profile to install itself instead of the the launcher user (which can be a process). Since the user is a non-admin, it couldn't install it. Chris says to modify the ISScript.msi to:

1) open isscript.msi in InstallShield's DirectEditor, then navigate to registry table, remove the Registry601 entry (which is a RunAs InteractiveUser).

2) navigate to the RemoveRegistry table and add Registry601 entry, so that if there was already a key like that in the current registry it will get deleted.

3) save it. then replace the one that installshield 10.5 uses located in Program files\Installshield 10.5\Redist\Language Independent\i386. Note Isscript.msi is actually ISScript1050.msi here. But in the Legacy folder they are ISscriptx.dll where x is the version (ISScript8.msi for version 8 of Installshield). I had them all modified.

---------

I noticed that there were 1 row dropped and 1 row added, but the modified isscript.msi had about 300kb difference between the original and the modified ones. This is seen when using ORCA tool.

Then (still using ORCA) there's problems installing them on other systems except XP SP2 and 2K SP4.

I've since used Installshield DirectEditor to edit those changes. And am testing them now on other systems: win2003 server & winxp 64-bit...I'll check back here on problems or whatever results...