• Announcements

    • xper

      MSFN Sponsorship and AdBlockers!   07/10/2016

      Dear members, MSFN is made available via subscriptions, donations and advertising revenue. The use of ad-blocking software hurts the site. Please disable ad-blocking software or set an exception for MSFN. Alternatively, become a site sponsor and ads will be disabled automatically and by subscribing you get other sponsor benefits.
mcslemon

Winrar command line injection

1 post in this topic

Hi,

I'm following a recommended way of repackaging Sophos for deployment through tools like Zenworks and SCCM which uses WinRAR as its method of compression and setup.

Within the SFX comment file, you launch setup.exe with some default command line switches e.g. Setup=SAVSCFXP\setup.exe -mng yes -ni -s -crt R -updp c:\temp\savinst\SAVSCFXPXML\ -G "\sophos\Group"

The -G bit I added as I want the installer to put the machine into the right group once Sophos installed. Problem I'm having is that we have about 15-20 groups, so 15-20 installers; this means ensuring that each RAR/SFX file is pointing to the right group.

Is there a method in WinRAR that allows you to pass a command line variable to the setup string in the comment file? For example:

c:\temp\savinst.exe NEXTGROUP

Having NEXTGROUP pass through to here:

Setup=SAVSCFXP\setup.exe -mng yes -ni -s -crt R -updp c:\temp\savinst\SAVSCFXPXML\ -G "\sophos\" & %VAR%

ending up as:

Setup=SAVSCFXP\setup.exe -mng yes -ni -s -crt R -updp c:\temp\savinst\SAVSCFXPXML\ -G "\sophos\NEXTGROUP"

Thanks for any thoughts.

0

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.