Posts

Permissions to registry using setacl

Recently I was trying giving permission to one of the registry hives with Subinacl, but it was not working despite all efforts and checking all the syntax and a lot of troubeshooting. Then I came across another permission granting utility known as SetACL. It worked like a charm. So you can try using this utility is Subinacl fails. You can download SetACL from  http://helgeklein.com/download/ Here is an example to run SetACL to give registry permissions. "SetACL.exe" -on "hkcr\Interface" -ot reg -actn setowner -ownr "n:Administrators" "SetACL.exe" -on "hkcr\Interface" -ot reg -actn ace -ace "n:Users;p:full" Object name (-on) : This is the path to the object SetACL should operate on (file/directory/registry key/network share/service/printer). Object type (-ot) : What kind of object does the object name refer to: file or directory (file), registry key (reg), service (srv), printer (prn), network share (shr)? Action (-actn) : What...

Install MSP file with MSI

While handling with MSP of applications, sometimes a question comes in mind that can an MSP be installed along with MSI? The answer is yes, but with a few conditions involved. The conditions are explained later in the post with some description. First I will give you the command line to install MSP along with MSI: msiexec /i {Path to MSI}\Installer.MSI PATCH={Path to MSP}\Patch.MSP /qb If there is a transform as well to add you can include it in the command line as well. msiexec /i {Path to MSI}\Installer.MSI TRANSFORMS={Path to Transform}\Transform.MST PATCH={Path to MSP}\Patch.MSP /qb The only thing which you have to take care in the command line is that you will have to give a complete path to MSP. Relative paths do not work in this case. This will apply the patch as in the updated files will be installed from the patch rather than from the MSI. This process is greatly useful when there are a lot of patches to be applied to an MSI. There might be cases that the MSI is alrea...

Error installing MSI from USB/DVD

Image
I faced an issue installing Flash player from USB drive though it was installing fine when installed from local or network drive. I found out the issue and resolution and want to document here for all of you. While installing the package, I got this error in the log files:   MSI (s) (44:C4) [14:06:35:318]: Source is incorrect. Volume label should be   but is SMSBOOT. MSI (s) (44:C4) [14:06:46:956]: Source is incorrect. Volume label should be   but is SMSBOOT.   While analysing this, I realized that the disk label for my USB is SMSBOOT and this could be anything else for you on your USB or DVD. I had added a file in my MSI through MST and it had created an entry in the Media table. This entry looked like this and this is the default entry which you get with the tool.     Behind the scene it was looking for a Blank labelled disk where this media is located but could not find it and it gave an error “Insert Disk”. I removed the label from my USB drive and kept...

Subinacl to give permissions to registry/Files

Subinacl is a useful utility to give permissions to registries. Here is a simple example how to give permissions to registry. subinacl.exe /subkeyreg HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Optika /grant=administrators=f /grant=system=f /grant=users=f /setowner=administrators >> %temp%\subinacl_output.txt /keyreg HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Optika /grant=administrators=f /grant=system=f /grant=users=f /setowner=administrators >> %temp%\subinacl_output.txt Subinacl can be downloaded from net. More detailed Usage as per your requirements. This contains lots of features. You can write your comments on what you used and if it worked. Help others by posting your real time examples. Usage :      SubInAcl [/option...] /object_type object_name [[/action[=parameter]...] /options    :     /outputlog=FileName                 /errorlog=FileName ...

VBScript to Find and Replace

I have been using this script for some time now. I took inputs from some sites to create this VBScript. I have modified it to my needs. I want to share this and keep it gfor my reference for future use as well. I am searching for a text and replacing it with the User input of mail id. '----------------------------------------------------- 'Use the below function if you want it to run from commandline and take input from users. 'If WScript.Arguments.Count <> 2 then '  WScript.Echo "usage: Find_And_replace.vbs filename word_to_find replace_with " '  WScript.Quit 'end If MailID=InputBox("Please enter your E-Mail ID") sFind="abcxyz.com" Set oshell=CreateObject("Wscript.shell") prog=oshell.ExpandEnvironmentStrings("%ProgramFiles(x86)%") TargetFile= prog & "\App\config.ini" TempFile= prog & "\App\config1.ini" FindAndReplace TargetFile, sFind, MailID WScript.Echo "Operation Complet...

Internal Consistency Evaluators

Image
This is some material on ICE which I got some time back from AngelD and wanted to post here for my and everyone's reference. ICE02 CASE 1: File: 'Red_File' cannot be the key file for Component: 'Blue'. The file belongs to Component: 'Red' Fix: Search for the component name in all the other tables in the following order: • If the component name is found in the Files Table, then set the keypath for the Component to be the name of the first column in the file table. • If the component name is found in the Registry Table then set the keypath for the Component to be the name of the first column in the Registry table, and add 4 to the Attributes column. • If the component name is not found in either table, leave the keypath blank CASE 2: ' Red_Key' cannot be the key registry key for Component: 'Blue'. The RegKey belongs to Component: 'Red' Fix: Search for the component name in all the other tables in the following order: • If the component ...

Creating a Device driver based package in Installshield

Image
It is very easy and simle to create a device driver based application from Installshield. I am using Installshield 2012. You need to make sure that the driver is a signed driver. If the driver is not signed, then you need to sign the driver first. It is good to have your driver signed, but you can install and unsigned driver as well. Check an option later. Go to Installshield Wizard in Installation Designer and click on Project button on top an then Device Driver wizard. Click Next -> Select the path to your .inf file on your machine. Choose the system architecture. I am choosing x64 as I am packaging for 64 bit machines. Click Next-> Next-> Select the options as per your requirement. I have chosen the above ones. Click Next-> Click Next-> You will get the summary and then click on Finish. It will add the settings in your component of INF file. Hope this helps you create device driver easily with Installshield.