/build/static/layout/Breadcrumb_cap_w.png

Active setup

Hi

I have used activesetup to call a vbscript when the user logs in. When the user logs in the script is running but it is not doing the exact action for which i have implemented the activesetup. Script will write some registries to HKCU\ hive. Script is working fine without any issues. When i manually execute the script, it does work. But when user logs in, it popups messages but does not do the required stuff. Very stupid and strange.

I spent a lot of time, but of no use. any suggestions please.

Regards
Ramesh

0 Comments   [ + ] Show comments

Answers (6)

Posted by: cygan 14 years ago
Fifth Degree Brown Belt
0
if your script works manually then it should work with active setup

stubpath = wscript.exe <path to your vbscript>

did you include your vbscript in the package

is this a vendors msi

can't you use self healing instead
create a top feature (parent) and put all your hkcu keys in this feature
Posted by: ramesh111k 14 years ago
Purple Belt
0
Yes script is working perfectly when I execute it manually.

I have used stubpath = "path of the vbs like " "c:\program files\xxx.vbs"

Yes the xxx.vbs exists in c:\program files\

The requirement was that it should be in vbscript. so no .msi can be used as per the client's requirement.
OOPs. I was scratching my head to find out the reason, finally I am putting the same script in Run registry, which is not a best practise. Please let me know if anyone experienced the same.

One more thing. when user logs in there are some drives which get mapped. Is it because of this . Not sure
Posted by: shweta_kar 14 years ago
Blue Belt
0
Ramesh,

have included wscript.exe in the stubPath value.

e.g wscript.exe "[ProgramFilesFolder]abc.vbs"
or
cscript.exe "[ProgramFilesFolder]abc.vbs"
Posted by: ramesh111k 14 years ago
Purple Belt
0
No I did not. What I have specified is stubpath = "C:\ProgramFiles\xxx.vbs"

I am executing a vbscript in system context and when user logs in I wanted another script to run to write HKCU registries. So I used activesetup.

and as specified above, i was writing a HKLM registry (activesetup) with the value stubpath = "C:\ProgramFiles\xxx.vbs" .

Please suggest is wscript.exe should be specified mandatorily.
Posted by: dj_xest 14 years ago
5th Degree Black Belt
0
Hi ramesh111k,

There are few things you may want to consider when running an active setup especially when it is an executable like your vb script. If you are logging in as a restricted user to run that script via Active Setup, you will not be allowed to execute that. The reason is obvious. The very easy way to populate that HKCU hive is to put your registry in your project, i.e. .WSI, IST or MST if it´s a vendor MSI and populate the Active Setup with a repair.

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Active Setup\Installed Components\{GUID}]
"@"="{Nameofyourapp or something}"
"Version"="{Version-i.e. 1,0}"
"StubPath"="msiexec.exe /fu {GUID} /quiet"

If you are persistent and you have some executables to work on to that user if he has admin rights, try what shweta_kar said. Try to list your Active Setup reg keys here and let´s see what we can find out.
Posted by: turbokitty 14 years ago
6th Degree Black Belt
0
on top of all that, I find active setup to be very unreliable. I'd use a vbscript CA in an MSI that's triggered by an HKCU dummy key.

<edit> I just read the whole thread and apparently an MSI is not an option. Besides, he's deploying HKCU keys with the VB so a CA would be useless.

I think relying on Active Setup for anything is a poor idea.
<edit>
Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.
 
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ