File tree 2 files changed +13
-7
lines changed
2 files changed +13
-7
lines changed Original file line number Diff line number Diff line change 113
113
</PropertyGroup >
114
114
</Target >
115
115
<Target Name =" SignAssemblies" AfterTargets =" PostBuildEvent" Condition =" '$(Configuration)'=='Publish'" >
116
- <Exec Command =" call " $(ProjectDir)..\..\signfile.bat" " $(TargetPath)" " />
116
+ <Exec Command =" call " $(ProjectDir)..\..\signfile.bat" " $(TargetPath)" "
117
+ IgnoreStandardErrorWarningFormat =" true" />
117
118
</Target >
118
119
</Project >
Original file line number Diff line number Diff line change @@ -14,13 +14,18 @@ set SignToolDir=C:\Program Files (x86)\Windows Kits\10\bin\10.0.22621.0\x64\
14
14
set SignTool = %SignToolDir% signtool.exe
15
15
16
16
echo Preparing to sign %Target%
17
- echo " %SignTool% " sign /f " %CodesignFile% " /fd sha256 /tr " %TimestampUrl% " /td sha256 /p " %CodesignPass% " %Target% || exit /b 1
18
- echo Waiting for 20 seconds before issuing command (avoid timeserver rejection)
17
+ echo " %SignTool% " sign /f " %CodesignFile% " /fd sha256 /tr " %TimestampUrl% " /td sha256 /p PASSWORD %Target
19
18
20
19
rem Timestamp server requires 15 seconds or more between signing requests
21
20
rem When publishing need to limit parallel build tasks to 1 in Tools| Options| Projects and Solutions| Build and Run
22
- ping -n 20 127.0.0.1 > NUL
21
+ set attempts = 10
22
+ :DoWhile
23
+ echo %attempts% attempts remaining
24
+ echo Waiting for 30 seconds before issuing command (avoid timeserver rejection)
25
+ ping -n 30 127.0.0.1 > NUL
26
+ " %SignTool% " sign /f " %CodesignFile% " /fd sha256 /tr " %TimestampUrl% " /td sha256 /p " %CodesignPass% " %Target% && goto EndDoWhile
27
+ set /a attempts = %attempts% - 1
28
+ if %attempts% gtr 0 goto DoWhile
29
+ :EndDoWhile
23
30
24
- " %SignTool% " sign /f " %CodesignFile% " /fd sha256 /tr " %TimestampUrl% " /td sha256 /p " %CodesignPass% " %Target% || exit /b 1
25
-
26
- " %SignTool% " verify /pa /tw %Target% || exit /b 1
31
+ " %SignTool% " verify /pa /tw %Target%
You can’t perform that action at this time.
0 commit comments