Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Binskim templates and script support #13851

Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
62 changes: 0 additions & 62 deletions Arcade.sln
Original file line number Diff line number Diff line change
Expand Up @@ -145,16 +145,6 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.DotNet.Build.Task
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.DotNet.ApiCompat.Core", "src\Microsoft.DotNet.ApiCompat\src\Microsoft.DotNet.ApiCompat.Core\Microsoft.DotNet.ApiCompat.Core.csproj", "{90FA5F6B-5C96-44EF-BB83-4AFF62A1CF8B}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Microsoft.DotNet.GenAPIv2", "Microsoft.DotNet.GenAPIv2", "{898AA2C6-9A76-4C0F-9DC3-518CDAA99087}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.DotNet.GenAPI.Shared", "src\Microsoft.DotNet.GenAPI\Shared\Microsoft.DotNet.GenAPI.Shared.csproj", "{4710F39B-B555-4B9B-AD4C-FBC777C87A1C}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.DotNet.GenAPI.Tool", "src\Microsoft.DotNet.GenAPI\Tool\Microsoft.DotNet.GenAPI.Tool.csproj", "{5CF1A5F1-31FE-46F0-9F45-971BD6B508D0}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.DotNet.GenAPI.Tasks", "src\Microsoft.DotNet.GenAPI\Tasks\Microsoft.DotNet.GenAPI.Tasks.csproj", "{79AD710B-57F4-41CA-AC2F-42625B8978FD}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.DotNet.GenAPI.Tests", "src\Microsoft.DotNet.GenAPI\Tests\Microsoft.DotNet.GenAPI.Tests.csproj", "{EBC3531D-97AF-494D-B2F8-2EAB47A9D58F}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Expand Down Expand Up @@ -929,54 +919,6 @@ Global
{90FA5F6B-5C96-44EF-BB83-4AFF62A1CF8B}.Release|x64.Build.0 = Release|Any CPU
{90FA5F6B-5C96-44EF-BB83-4AFF62A1CF8B}.Release|x86.ActiveCfg = Release|Any CPU
{90FA5F6B-5C96-44EF-BB83-4AFF62A1CF8B}.Release|x86.Build.0 = Release|Any CPU
{4710F39B-B555-4B9B-AD4C-FBC777C87A1C}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{4710F39B-B555-4B9B-AD4C-FBC777C87A1C}.Debug|Any CPU.Build.0 = Debug|Any CPU
{4710F39B-B555-4B9B-AD4C-FBC777C87A1C}.Debug|x64.ActiveCfg = Debug|Any CPU
{4710F39B-B555-4B9B-AD4C-FBC777C87A1C}.Debug|x64.Build.0 = Debug|Any CPU
{4710F39B-B555-4B9B-AD4C-FBC777C87A1C}.Debug|x86.ActiveCfg = Debug|Any CPU
{4710F39B-B555-4B9B-AD4C-FBC777C87A1C}.Debug|x86.Build.0 = Debug|Any CPU
{4710F39B-B555-4B9B-AD4C-FBC777C87A1C}.Release|Any CPU.ActiveCfg = Release|Any CPU
{4710F39B-B555-4B9B-AD4C-FBC777C87A1C}.Release|Any CPU.Build.0 = Release|Any CPU
{4710F39B-B555-4B9B-AD4C-FBC777C87A1C}.Release|x64.ActiveCfg = Release|Any CPU
{4710F39B-B555-4B9B-AD4C-FBC777C87A1C}.Release|x64.Build.0 = Release|Any CPU
{4710F39B-B555-4B9B-AD4C-FBC777C87A1C}.Release|x86.ActiveCfg = Release|Any CPU
{4710F39B-B555-4B9B-AD4C-FBC777C87A1C}.Release|x86.Build.0 = Release|Any CPU
{5CF1A5F1-31FE-46F0-9F45-971BD6B508D0}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{5CF1A5F1-31FE-46F0-9F45-971BD6B508D0}.Debug|Any CPU.Build.0 = Debug|Any CPU
{5CF1A5F1-31FE-46F0-9F45-971BD6B508D0}.Debug|x64.ActiveCfg = Debug|Any CPU
{5CF1A5F1-31FE-46F0-9F45-971BD6B508D0}.Debug|x64.Build.0 = Debug|Any CPU
{5CF1A5F1-31FE-46F0-9F45-971BD6B508D0}.Debug|x86.ActiveCfg = Debug|Any CPU
{5CF1A5F1-31FE-46F0-9F45-971BD6B508D0}.Debug|x86.Build.0 = Debug|Any CPU
{5CF1A5F1-31FE-46F0-9F45-971BD6B508D0}.Release|Any CPU.ActiveCfg = Release|Any CPU
{5CF1A5F1-31FE-46F0-9F45-971BD6B508D0}.Release|Any CPU.Build.0 = Release|Any CPU
{5CF1A5F1-31FE-46F0-9F45-971BD6B508D0}.Release|x64.ActiveCfg = Release|Any CPU
{5CF1A5F1-31FE-46F0-9F45-971BD6B508D0}.Release|x64.Build.0 = Release|Any CPU
{5CF1A5F1-31FE-46F0-9F45-971BD6B508D0}.Release|x86.ActiveCfg = Release|Any CPU
{5CF1A5F1-31FE-46F0-9F45-971BD6B508D0}.Release|x86.Build.0 = Release|Any CPU
{79AD710B-57F4-41CA-AC2F-42625B8978FD}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{79AD710B-57F4-41CA-AC2F-42625B8978FD}.Debug|Any CPU.Build.0 = Debug|Any CPU
{79AD710B-57F4-41CA-AC2F-42625B8978FD}.Debug|x64.ActiveCfg = Debug|Any CPU
{79AD710B-57F4-41CA-AC2F-42625B8978FD}.Debug|x64.Build.0 = Debug|Any CPU
{79AD710B-57F4-41CA-AC2F-42625B8978FD}.Debug|x86.ActiveCfg = Debug|Any CPU
{79AD710B-57F4-41CA-AC2F-42625B8978FD}.Debug|x86.Build.0 = Debug|Any CPU
{79AD710B-57F4-41CA-AC2F-42625B8978FD}.Release|Any CPU.ActiveCfg = Release|Any CPU
{79AD710B-57F4-41CA-AC2F-42625B8978FD}.Release|Any CPU.Build.0 = Release|Any CPU
{79AD710B-57F4-41CA-AC2F-42625B8978FD}.Release|x64.ActiveCfg = Release|Any CPU
{79AD710B-57F4-41CA-AC2F-42625B8978FD}.Release|x64.Build.0 = Release|Any CPU
{79AD710B-57F4-41CA-AC2F-42625B8978FD}.Release|x86.ActiveCfg = Release|Any CPU
{79AD710B-57F4-41CA-AC2F-42625B8978FD}.Release|x86.Build.0 = Release|Any CPU
{EBC3531D-97AF-494D-B2F8-2EAB47A9D58F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{EBC3531D-97AF-494D-B2F8-2EAB47A9D58F}.Debug|Any CPU.Build.0 = Debug|Any CPU
{EBC3531D-97AF-494D-B2F8-2EAB47A9D58F}.Debug|x64.ActiveCfg = Debug|Any CPU
{EBC3531D-97AF-494D-B2F8-2EAB47A9D58F}.Debug|x64.Build.0 = Debug|Any CPU
{EBC3531D-97AF-494D-B2F8-2EAB47A9D58F}.Debug|x86.ActiveCfg = Debug|Any CPU
{EBC3531D-97AF-494D-B2F8-2EAB47A9D58F}.Debug|x86.Build.0 = Debug|Any CPU
{EBC3531D-97AF-494D-B2F8-2EAB47A9D58F}.Release|Any CPU.ActiveCfg = Release|Any CPU
{EBC3531D-97AF-494D-B2F8-2EAB47A9D58F}.Release|Any CPU.Build.0 = Release|Any CPU
{EBC3531D-97AF-494D-B2F8-2EAB47A9D58F}.Release|x64.ActiveCfg = Release|Any CPU
{EBC3531D-97AF-494D-B2F8-2EAB47A9D58F}.Release|x64.Build.0 = Release|Any CPU
{EBC3531D-97AF-494D-B2F8-2EAB47A9D58F}.Release|x86.ActiveCfg = Release|Any CPU
{EBC3531D-97AF-494D-B2F8-2EAB47A9D58F}.Release|x86.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
Expand Down Expand Up @@ -1015,10 +957,6 @@ Global
{0B5D3C20-EB58-4A82-A3AA-2E626A17B35D} = {C53DD924-C212-49EA-9BC4-1827421361EF}
{FB4168D5-6EA6-4777-AD4F-95758C177FE8} = {C53DD924-C212-49EA-9BC4-1827421361EF}
{90FA5F6B-5C96-44EF-BB83-4AFF62A1CF8B} = {E41E23C4-5CB0-4C61-9E05-EEFFEC4B356D}
{4710F39B-B555-4B9B-AD4C-FBC777C87A1C} = {898AA2C6-9A76-4C0F-9DC3-518CDAA99087}
{5CF1A5F1-31FE-46F0-9F45-971BD6B508D0} = {898AA2C6-9A76-4C0F-9DC3-518CDAA99087}
{79AD710B-57F4-41CA-AC2F-42625B8978FD} = {898AA2C6-9A76-4C0F-9DC3-518CDAA99087}
{EBC3531D-97AF-494D-B2F8-2EAB47A9D58F} = {898AA2C6-9A76-4C0F-9DC3-518CDAA99087}
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {32B9C883-432E-4FC8-A1BF-090EB033DD5B}
Expand Down
9 changes: 8 additions & 1 deletion eng/common/sdl/configure-sdl-tool.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,9 @@ Param(
# Optional: Additional params to add to any tool using PoliCheck.
[string[]] $PoliCheckAdditionalRunConfigParams,
# Optional: Additional params to add to any tool using CodeQL/Semmle.
[string[]] $CodeQLAdditionalRunConfigParams
[string[]] $CodeQLAdditionalRunConfigParams,
# Optional: Additional params to add to any tool using Binskim.
[string[]] $BinskimLAdditionalRunConfigParams
)

$ErrorActionPreference = 'Stop'
Expand Down Expand Up @@ -85,6 +87,11 @@ try {
$tool.Args += "`"SourceCodeDirectory < $TargetDirectory`""
}
$tool.Args += $CodeQLAdditionalRunConfigParams
} elseif ($tool.Name -eq 'binskim') {
if ($targetDirectory) {
$tool.Args += "`"Target < $TargetDirectory`""
}
$tool.Args += $BinskimLAdditionalRunConfigParams
}

# Create variable pointing to the args array directly so we can use splat syntax later.
Expand Down
4 changes: 3 additions & 1 deletion eng/common/sdl/execute-all-sdl-tools.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ Param(
[string[]] $CrScanAdditionalRunConfigParams, # Optional: Additional Params to custom build a CredScan run config in the format @("xyz:abc","sdf:1")
[string[]] $PoliCheckAdditionalRunConfigParams, # Optional: Additional Params to custom build a Policheck run config in the format @("xyz:abc","sdf:1")
[string[]] $CodeQLAdditionalRunConfigParams, # Optional: Additional Params to custom build a Semmle/CodeQL run config in the format @("xyz < abc","sdf < 1")
[string[]] $BinskimLAdditionalRunConfigParams, # Optional: Additional Params to custom build a Binskim run config in the format @("xyz < abc","sdf < 1")
[bool] $BreakOnFailure=$False # Optional: Fail the build if there were errors during the run
)

Expand Down Expand Up @@ -107,7 +108,8 @@ try {
-GuardianLoggerLevel $GuardianLoggerLevel `
-CrScanAdditionalRunConfigParams $CrScanAdditionalRunConfigParams `
-PoliCheckAdditionalRunConfigParams $PoliCheckAdditionalRunConfigParams `
-CodeQLAdditionalRunConfigParams $CodeQLAdditionalRunConfigParams
-CodeQLAdditionalRunConfigParams $CodeQLAdditionalRunConfigParams `
-BinskimLAdditionalRunConfigParams $BinskimLAdditionalRunConfigParams
if ($BreakOnFailure) {
Exit-IfNZEC "Sdl"
}
Expand Down
2 changes: 1 addition & 1 deletion eng/common/templates/steps/execute-sdl.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ steps:

- ${{ if ne(parameters.overrideParameters, '') }}:
- powershell: ${{ parameters.executeAllSdlToolsScript }} ${{ parameters.overrideParameters }}
displayName: Execute SDL
displayName: Execute SDL (Overridden)
continueOnError: ${{ parameters.sdlContinueOnError }}
condition: ${{ parameters.condition }}

Expand Down
62 changes: 0 additions & 62 deletions src/Microsoft.DotNet.GenAPI/Shared/AssemblySymbolDisplayFormat.cs

This file was deleted.

Loading