Help - Search - Members - Calendar
Full Version: Hijackthis and Adaware
UBCD4Win Forums > Main Forum: UBCD4Windows - Support > General Questions
Duperdogme
I use the UBCD4Win in both environments, as a bootcd and also as a tools cd within the OS that is on the machine. With the runscanner addin, to allow use from the UBCD boot it makes it difficult to to use programs like HiJackthis and Adaware when in the actual system OS. I have created the following modified .cmd files to address this issue. I know SteelTrepid is looking at incorporating different menus based on the environment you are in for a future release, but perhaps these might help on the background part. Of course for these to work you may have to modify your .xml file to make the programs visible in both environments. Basically it just looks to see if Runscanner exists on the %systemdrive% and then loads the app accordingly.
Kind critiques are welcome..
wink.gif

DuperdogMe

PS Wasn't sure where to post this on the forum. Hope this was acceptable.

hijackthis.cmd
QUOTE
@echo off
echo hijackScan.CMD: Starting...
setlocal
if "%temp%" == "" goto _err
if exist "%systemdrive%\Programs\RunScanner\RunScanner.exe" goto _run2
if exist "%temp%\HijackThis\" goto _run1
mkdir "%temp\HijackThis\"
echo Hijackscan.CMD: Copying "%~dp0*.*" to "%temp%\HijackThis
xcopy /s "%~dp0*.*" "%temp%\HijackThis\"

:_run1
start %temp%\HijackThis\HijackThis.exe
goto _end

:_run2
if exist "%temp%\HijackThis\" goto _run1
mkdir "%temp\HijackThis\"
echo Hijackscan.CMD: Copying "%~dp0*.*" to "%temp%\HijackThis
xcopy /s "%~dp0*.*" "%temp%\HijackThis\"
start /wait regsvr32 /s /i shell32.dll
start /wait regsvr32 /s mlang.dll
start /wait regsvr32 /s /i browseui.dll
start /wait regsvr32 /s msxml.dll
start /wait regsvr32 /s /i mshtml.dll
start /wait regsvr32 /s /i shdocvw.dll

:_run
start %SystemDrive%\Programs\Runscanner\RunScanner.exe /t 0 %temp%\HijackThis\HijackThis.exe
goto _end

:_err
echo.
echo HijackSCAN.CMD: No temp variable set...
echo hijackSCAN.CMD: Try adding a ramdrive...
echo.
pause.
:_end
endlocal


adaware.cmd
QUOTE
@echo off
rem -------------------------------------------------------------------------
rem revised by duperdogme
rem -------------------------------------------------------------------------
echo ADAWARE.CMD: Starting...
setlocal
if "%temp%" == "" goto _err
if exist "%systemdrive%\Programs\RunScanner\RunScanner.exe" goto _run2
if exist "%temp%\adaware\ad-aware.exe" goto _run1
mkdir "%temp%\adaware"
echo ADAWARE.CMD: Copying "%~dp0ad-aware.exe" to "%temp%\adaware\"
copy "%~dp0ad-aware.exe" "%temp%\adaware\ad-aware.exe"
echo ADAWARE.CMD: Copying "%~dp0defs.ref" to "%temp%\adaware\"
copy "%~dp0defs.ref" "%temp%\adaware\defs.ref"

:_run1
start %temp%\adawarese\ad-aware.exe
goto _end

:_run2
if exist "%temp%\adaware\ad-aware.exe" goto _run
mkdir "%temp%\adaware"
xcopy /s "%~dp0*.chm" "%temp%\adaware\"
xcopy /s "%~dp0*.wav" "%temp%\adaware\"
xcopy /s "%~dp0*.exe" "%temp%\adaware\"
xcopy /s "%~dp0*.cmd" "%temp%\adaware\"
xcopy /s "%~dp0*.ref" "%temp%\adaware\"
rem The following regsvr32 lines can be removed if you are using an explorer plugin

start /wait regsvr32 /s /i shell32.dll
start /wait regsvr32 /s mlang.dll
start /wait regsvr32 /s /i browseui.dll
start /wait regsvr32 /s msxml.dll
start /wait regsvr32 /s /i mshtml.dll
start /wait regsvr32 /s /i shdocvw.dll

:_run
start %SystemDrive%\Programs\RunScanner\RunScanner.exe %temp%\adaware\ad-aware.exe
goto _end
:_err
echo.
echo ADAWARE.CMD: No temp variable set...
echo ADAWARE.CMD: Try adding a ramdrive...
echo.
pause.
:_end
endlocal
SteelTrepid
Thanks for the suggestion or your "workaround." I'm actually trying a different approach. Haven't had much time to work on it or test it but I'm sure I will get it working. It will take a lot of work and testing, so the next version will probably be quite a bit of time away.
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2006 Invision Power Services, Inc.