Follow us on Twitter!
Capitalism is an Island of wealth in a sea of poverty
Friday, April 18, 2014
Navigation
Home
HellBoundHackers Main:
HellBoundHackers Find:
HellBoundHackers Information:
Learn
Communicate
Submit
Shop
Challenges
HellBoundHackers Exploit:
HellBoundHackers Programming:
HellBoundHackers Think:
HellBoundHackers Track:
HellBoundHackers Patch:
HellBoundHackers Other:
HellBoundHackers Need Help?
Other
Members Online
Total Online: 22
Guests Online: 18
Members Online: 4

Registered Members: 82823
Newest Member: Andyrayfun
Latest Articles
View Thread

HellBound Hackers | Computer General | Increasing Security

Author

aohell


Member

Your avatar

Posts:
Location:
Joined: 01.01.70
Rank:
Guest
Posted on 02-01-07 16:08
@echo off
::
:: GK_PASS.BAT - OnSuccess Batch File For Gate Keeper
:: Version B08 - 01 Jul 2004
::


:: Set "dell" as the default manufacturing directory
set MFGDIR=dell

:: Determine if the TAL (Titan Abstraction Layer) for "A:" access is installed
set TAL_LOG=C:\%MFGDIR%\fist\talcall.err
if not exist c:\%MFGDIR%\fist\tal.exe goto TAL_Missing

::
:: If detected, append to LOG the fact that an OS dump of some kind occured.
:: Mini dumps are created in C:\windows\Minidump\ and are of the
:: form: minMMDDYY-VV.dmp
:: Kernel/Complete Memory dumps are created as: C:\windows\memory.dmp
::
if not exist C:\windows\memory.dmp if not exist C:\windows\minidump\*.dmp goto No_Dump
set DUMP_LOG=C:\%MFGDIR%\fist\os_dump.log
cmd /c echo ******************** > %DUMP_LOG%
cmd /c echo [GK_PASS.BAT] Warning! OS dump file(s) detected >> %DUMP_LOG%
if exist C:\windows\memory.dmp cmd /c dir C:\windows\memory.dmp >> %DUMP_LOG%
if exist C:\windows\minidump\*.dmp cmd /c dir C:\windows\minidump >> %DUMP_LOG%
cmd /c echo ******************** >> %DUMP_LOG%

set TAL_CMD=AppendFiles
c:\%MFGDIR%\fist\tal.exe %TAL_CMD% LOG %DUMP_LOG%
if errorlevel 1 goto TAL_Fail
:No_Dump


echo "passed" >> c:\%MFGDIR%\passed.bat

:: nobulate the boot status
:: this is for IA32, IA64 is different
start /w C:\%MFGDIR%\FIST\nobnt 0
if errorlevel 1 goto Nob_Fail

:: DOFIST.BAT uses this file as a trigger of FIST running
if exist c:\%MFGDIR%\fist\nobulate.exe del /f /q c:\%MFGDIR%\fist\nobulate.exe

::
:: Create FIST.LOG on the Manufacturing Media to indicate FIST completed
::
set TAL_CMD=Log
c:\%MFGDIR%\fist\tal.exe %TAL_CMD% FIST.LOG "[GK_PASS.BAT] FIST completed."
if errorlevel 1 goto TAL_Fail


:: Handle EBTS on C: partition
if exist c:\%MFGDIR%\fist\ebts.tag cmd /c call c:\%MFGDIR%\fist\doebts.bat

:: remove DlyStart executable and log
if exist c:\%MFGDIR%\DlyStart.Exe Del /f /q c:\%MFGDIR%\DlyStart.Exe
if exist c:\%MFGDIR%\DlyStart.Log Del /f /q c:\%MFGDIR%\DlyStart.Log

call c:\dell\fist\bootchk.bat
call c:\dell\fist\reguned.bat
:: Clear out system event log
cmd /c c:\%MFGDIR%\fist\clearevt.exe

:: Remove Dell WinBOM elements
if exist c:\%MFGDIR%\DellRunK.Exe cmd /c Del c:\%MFGDIR%\DellRunK.Exe
if exist c:\%MFGDIR%\RunServs.Exe cmd /c Del c:\%MFGDIR%\RunServs.Exe
if exist c:\%MFGDIR%\DellRun.cmd cmd /c Del c:\%MFGDIR%\DellRun.cmd
if exist c:\%MFGDIR%\pnpwait.exe cmd /c Del c:\%MFGDIR%\pnpwait.exe
if exist c:\%MFGDIR%\wbiwait.exe cmd /c Del c:\%MFGDIR%\wbiwait.exe

:: Cleaning out Prefetch directory
cmd /c Del /F /Q c:\windows\prefetch\*.*

rem ### This is Dougs Stuff
rem the following line is used as a key for re-enabling the server config screen under
rem w2k/nt5 which is supressed for FIST support but needs to poresented to the customer
rem on the first customer boot. DO NOT DELETE!!!!!!
rem NT5 Server Config Mark

:: Remove \dell\SYSPREP.DUN to indicate that the call to seal the box has been made
if exist c:\%MFGDIR%\sysprep.dun cmd /c del c:\%MFGDIR%\sysprep.dun

:: Save the WBI Log file to the Manufacturing Media
if not exist c:\%MFGDIR%\fist\wbi.log goto NoWBIlog
set TAL_CMD=AppendFiles
c:\%MFGDIR%\fist\tal.exe %TAL_CMD% LOG c:\%MFGDIR%\fist\wbi.log
if errorlevel 1 goto TAL_Fail
:NoWBIlog

:: Capture the amount of data installed to the OS drive... this is used
:: for the DSR project to calculate how big of a DSR partition is needed to
:: hold a backup image of this install.
c:\%MFGDIR%\fist\diskused.exe > c:\%MFGDIR%\fist\diskused.bat
set TAL_CMD=PutFiles
c:\%MFGDIR%\fist\tal.exe %TAL_CMD% c:\%MFGDIR%\fist\diskused.bat
if errorlevel 1 goto TAL_Fail

::
:: Synchronize MDSRS state server with "A:" contents if TAL is installed
::
set TAL_CMD=SynchronizeServer
c:\%MFGDIR%\fist\tal.exe %TAL_CMD%
if errorlevel 1 goto TAL_Fail

goto Finish


::
:: Error Messages
::

GrinMP_Fail
echo [GK_PASS.BAT] Error! MOUNTDMP /CLEAN call failed. >> C:\%MFGDIR%\fist\gk_pass.err
goto Finish

:Nob_Fail
if "%TAL_LOG%" == "" goto NOT_TAL
echo [GK_PASS.BAT] Error! NOBNT call failed... TAL failure? >> %TAL_LOG%
echo [GK_PASS.BAT] Error! NOBNT call failed... TAL failure? >> C:\%MFGDIR%\fist\gk_pass.err
:: Display a failure screen and stay there as we can't reliably continue
c:\%MFGDIR%\fist\talfail.bat
goto Finish
:NOT_TAL
echo [GK_PASS.BAT] Error! NOBNT call failed. >> C:\%MFGDIR%\fist\gk_pass.err
:: Display a failure screen and stay there as we can't reliably continue
c:\%MFGDIR%\fist\nobfail.bat
goto Finish

:TAL_Fail
set TAL_RC=0
if errorlevel 1 set TAL_RC=1
if errorlevel 2 set TAL_RC=2
if errorlevel 3 set TAL_RC=3 or greater
echo [GK_PASS.BAT] TAL %TAL_CMD% call failed, return code = %TAL_RC% >> %TAL_LOG%
echo [GK_PASS.BAT] TAL %TAL_CMD% call failed, return code = %TAL_RC% >> C:\%MFGDIR%\fist\gk_pass.err
:: Display a failure screen and stay there as we can't reliably continue
c:\%MFGDIR%\fist\talfail.bat
goto Finish

:TAL_Missing
echo [GK_PASS.BAT] TAL.EXE was not found in the fist directory >> %TAL_LOG%
echo [GK_PASS.BAT] TAL.EXE was not found in the fist directory >> C:\%MFGDIR%\fist\gk_pass.err
:: Display a failure screen and stay there as we can't reliably continue
c:\%MFGDIR%\fist\talfail.bat
goto Finish


:Finish

:: ACME hook - Dell "Whitebox" SED hook - DO NOT DELETE THIS LINE

::
:: Verify no .err files were generated during GK_PASS execution
::
if not exist C:\%MFGDIR%\fist\*.err goto Del_FIST

:: Accumulate *.err files to one error file (fist.err)
if not exist C:\%MFGDIR%\FIST\TANDOORI.EXE echo Unable To Find C:\%MFGDIR%\FIST\TANDOORI.EXE
if not exist C:\%MFGDIR%\FIST\TANDOORI.EXE pause
cmd /c c:\%MFGDIR%\fist\tandoori c:\%MFGDIR%\fist\*.err >> c:\fist.err
set TAL_CMD=PutFiles
if exist c:\fist.err c:\%MFGDIR%\fist\tal.exe %TAL_CMD% c:\fist.err
if errorlevel 1 goto TAL_Fail
goto End


Grinel_FIST
:: Before we kill the FIST dir, see if SI_PAUSE.BAT exist there... if so,
:: run it. This is a "pause" hook just prior to reboot back to mfg process.
:: CFI requested this hook to allow an operator to plug the NIC cable back in.
if exist c:\%MFGDIR%\fist\si_pause.bat cmd /c call c:\%MFGDIR%\fist\si_pause.bat

:: Warning, the next comment is a sed insertion point, do not change!!
:: Remove the FIST directory
if exist c:\%MFGDIR%\fist\nul cmd /c rd /s /q c:\%MFGDIR%\fist

:: Creating flag for DOFIST.BAT audit check
cmd /c echo "complete" > c:\%MFGDIR%\complete.fst


:End
Exit




this is batch right? @ echo off? what does it do?


Author

RE: aohell


Member

Your avatar

Posts:
Location:
Joined: 01.01.70
Rank:
Guest
Posted on 02-01-07 18:18
if u cant even confirm it is batch i would surgets u leave it, as u obviously have no knowledge of what it is or what it does


Author

RE: aohell


Member

Your avatar

Posts:
Location:
Joined: 01.01.70
Rank:
Guest
Posted on 02-01-07 19:46
Yes it is a batch, @echo off turns makes it not show what it does, just the output (not sure how to describe it)