Jump to content

Recommended Posts

  • 2 years later...

Posted

What's the way to INCLUDE nircmdc.exe into WinPE?

My problem is that cmdow.exe pr nircmd.exe CAN'T BE EXECUTED from STARTNET.CMD in a X64 WinPE Boot image !!!!

Seems that's a Group Security Policy LOCK for files differents from HKLM\COMPONENTS\CanonicalData\Components

Please HOW can I add my custom executable & run them in X64 WinPE Boot image?

How can i create & add Components for wim files?

Tnx

Posted (edited)
What's the way to INCLUDE nircmdc.exe into WinPE?

My problem is that cmdow.exe pr nircmd.exe CAN'T BE EXECUTED from STARTNET.CMD in a X64 WinPE Boot image !!!!

Seems that's a Group Security Policy LOCK for files differents from HKLM\COMPONENTS\CanonicalData\Components

Please HOW can I add my custom executable & run them in X64 WinPE Boot image?

How can i create & add Components for wim files?

Tnx

SOLVED!

The WinPE Enviroment is a PURE 64BIT so CMDOW, NIRCMD etc DOESN't WORK!

To solve DEFINITELY the problem use AUTOIT:

Forget STARTNET.CMD, instead create a file "Winpeshl.ini"

____________________________________________________________

[LaunchApp]

AppPath = ShellExecuteWait.exe "Setup.cmd" "" "" "open" "SW_HIDE"

____________________________________________________________

Create a file Setup.cmd

____________________________________________________________

@echo off

for %%a in (C D E F G H I J K L M N O P Q R S T U V W X Y Z) do if exist %%a:\sources\setup.exe set CDROM=%%a:

call %CDROM%\sources\$OEM$\Unattended1.cmd

start /wait /realtime %CDROM%\sources\setup.exe

call %CDROM%\sources\$OEM$\Unattended2.cmd

____________________________________________________________

Unattended1.cmd & Unattended2.cmd scripts taht can be used to load/unload drivers before start Setup!

Compile the script (AutoIt) as 64 BIT

____________________________________________________________

;ShellExecuteWait ( "filename" [, "parameters" [, "workingdir" [, "verb" [, showflag]]]] )

Select

Case $CmdLine[5] = "SW_HIDE"

ShellExecuteWait($CmdLine[1],$CmdLine[2], $CmdLine[3], $CmdLine[4], @SW_HIDE)

Case $CmdLine[5] = "SW_MINIMIZE"

ShellExecuteWait($CmdLine[1],$CmdLine[2], $CmdLine[3], $CmdLine[4], @SW_MINIMIZE)

Case $CmdLine[5] = "SW_MAXIMIZE"

ShellExecuteWait($CmdLine[1],$CmdLine[2], $CmdLine[3], $CmdLine[4], @SW_MAXIMIZE)

Case $CmdLine[5] = "SW_SHOWNORMAL"

ShellExecuteWait($CmdLine[1],$CmdLine[2], $CmdLine[3], $CmdLine[4], @SW_SHOWNORMAL)

EndSelect

____________________________________________________________

put files in mounted WinPE startup image :)

All done .....

Edited by testazzo
  • 5 months later...

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.
×
×
  • Create New...