|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [PATCH 3/7] Enable KASAN build support
On 11/11/2025 09:34, Owen Smith wrote: > KASAN (Kernel Address Sanitizer) > (see https://learn.microsoft.com/en-us/windows-hardware/drivers/devtest/kasan) > builds can be enabled when using the WDK 10.0.26100.2161 or later, and can be > used on specially prepared Windows 11 24H2 / Server 2025, or later, OSs. > > KASAN enabled drivers should not generally deployed, as the OS needs to be > enabled, but these drivers can help track down illegal memory accesses and > similar issues. > > Signed-off-by: david ambu <david.preetham@xxxxxxxxx> I tested it to verify that the KASAN section got created, but haven't gotten the time to test further. Acked-by: Tu Dinh <ngoc-tu.dinh@xxxxxxxxxx> > --- > build.ps1 | 6 ++++-- > msbuild.ps1 | 11 ++++++++--- > 2 files changed, 12 insertions(+), 5 deletions(-) > > diff --git a/build.ps1 b/build.ps1 > index 42bbdde..1ec30ee 100644 > --- a/build.ps1 > +++ b/build.ps1 > @@ -9,7 +9,8 @@ param( > [string]$SignMode = "TestSign", > [switch]$CodeQL, > [switch]$Sdv, > - [switch]$CodeAnalysis > + [switch]$CodeAnalysis, > + [switch]$Kasan > ) > > # > @@ -32,7 +33,8 @@ Function Build { > Arch = $Arch; > Type = $Type; > SignMode = $SignMode; > - CodeAnalysis = $CodeAnalysis > + CodeAnalysis = $CodeAnalysis; > + Kasan = $Kasan > } > & ".\msbuild.ps1" @params > if ($LASTEXITCODE -ne 0) { > diff --git a/msbuild.ps1 b/msbuild.ps1 > index 9484a8d..6f0755d 100644 > --- a/msbuild.ps1 > +++ b/msbuild.ps1 > @@ -9,7 +9,8 @@ param( > [Parameter(Mandatory = $true)] > [string]$Type, > [string]$SignMode = "TestSign", > - [switch]$CodeAnalysis > + [switch]$CodeAnalysis, > + [switch]$Kasan > ) > > # > @@ -30,7 +31,8 @@ Function Run-MSBuild { > [string]$Platform, > [string]$Target = "Build", > [string]$Inputs = "", > - [switch]$CodeAnalysis > + [switch]$CodeAnalysis, > + [switch]$Kasan > ) > > $c = "msbuild.exe" > @@ -46,6 +48,9 @@ Function Run-MSBuild { > $c += "/p:RunCodeAnalysis=true " > $c += "/p:EnablePREFast=true " > } > + if ($Kasan) { > + $c += "/p:EnableKASAN=true " > + } > > $c += Join-Path -Path $SolutionPath -ChildPath $Name > > @@ -187,7 +192,7 @@ if (-Not (Test-Path -Path $archivepath)) { > } > > if (($Type -eq "free") -or ($Type -eq "checked")) { > - Run-MSBuild $solutionpath $SolutionName $configuration[$Type] > $platform[$Arch] -CodeAnalysis:$CodeAnalysis > + Run-MSBuild $solutionpath $SolutionName $configuration[$Type] > $platform[$Arch] -CodeAnalysis:$CodeAnalysis -Kasan:$Kasan > } > > if ($Type -eq "codeql") { -- Ngoc Tu Dinh | Vates XCP-ng Developer XCP-ng & Xen Orchestra - Vates solutions web: https://vates.tech
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |