Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

60 lines
1.4 KiB

@REM -----------------------------------------------------------------
@REM
@REM tscert.cmd - MadanA
@REM applies signature to terminal server files
@REM
@REM Copyright (c) Microsoft Corporation. All rights reserved.
@REM
@REM -----------------------------------------------------------------
@if defined _CPCMAGIC goto CPCBegin
@perl -x "%~f0" %*
@goto :EOF
#!perl
use strict;
use lib $ENV{RAZZLETOOLPATH} . "\\PostBuildScripts";
use lib $ENV{RAZZLETOOLPATH};
use PbuildEnv;
use ParseArgs;
sub Usage { print<<USAGE; exit(1) }
tscert [-l <language>]
Applies signature to terminal server files
USAGE
parseargs('?' => \&Usage);
# *** TEMPLATE CODE ***
$ENV{"_CPCMAGIC"}++;exit(system($0)>>8);
__END__
@:CPCBegin
@set _CPCMAGIC=
@setlocal ENABLEDELAYEDEXPANSION ENABLEEXTENSIONS
@if not defined DEBUG echo off
@REM *** CMD SCRIPT BELOW ***
set TsFileList=termdd.sys tdpipe.sys
set TSFileList=%TsFileList% tdtcp.sys tsddd.dll rdpdd.dll rdpwd.sys rdpwsx.dll
for %%f in (%TsFileList%) do call :TsSign %_NTPOSTBLD%\%%f
goto end
:TSSign
REM Only sign file if it is not already signed
tscrtvfy.exe %1
if "%errorlevel%" == "0" (
call logmsg.cmd "Image %1 is already signed (Not signing again)"
goto end
)
call ExecuteCmd "tscrtadd.exe %1"
if not "%errorlevel%" == "0" (
set errors=%errorlevel%
)
goto end
:end
seterror.exe "%errors%"& goto :EOF