mirror of
https://github.com/stellarbear/YaraSharp
synced 2026-06-08 17:36:09 +00:00
1.2.1 nuget update
This commit is contained in:
Binary file not shown.
Binary file not shown.
@@ -2,6 +2,8 @@
|
||||
C# wrapper around the [Yara pattern matching library](https://github.com/VirusTotal/yara).
|
||||
|
||||
Use signatures form [Loki](https://github.com/Neo23x0/signature-base/tree/master/yara) or [Yara](https://github.com/Yara-Rules/rules).
|
||||
|
||||
Nuget package is [available](https://www.nuget.org/packages/YaraSharp)
|
||||
## Usage
|
||||
```C#
|
||||
// All API calls happens here
|
||||
@@ -77,7 +79,7 @@ Soultion contains 2 projects:
|
||||
## Other
|
||||
Build in vs 2017
|
||||
|
||||
Compiled with yara 3.7.0
|
||||
Compiled with yara 3.8.1
|
||||
|
||||
You can use or modify the sources however you want
|
||||
|
||||
|
||||
Binary file not shown.
Binary file not shown.
@@ -46,10 +46,6 @@
|
||||
<Reference Include="Microsoft.CSharp" />
|
||||
<Reference Include="System.Data" />
|
||||
<Reference Include="System.Xml" />
|
||||
<Reference Include="YaraSharp, Version=1.1.3.0, Culture=neutral, processorArchitecture=AMD64">
|
||||
<SpecificVersion>False</SpecificVersion>
|
||||
<HintPath>.\YaraSharp.dll</HintPath>
|
||||
</Reference>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="Program.cs" />
|
||||
@@ -59,5 +55,11 @@
|
||||
<None Include="App.config" />
|
||||
<None Include="packages.config" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\YaraSharp\YaraSharp.vcxproj">
|
||||
<Project>{c005e3b9-2474-4fea-b5f4-7bb897111e8f}</Project>
|
||||
<Name>YaraSharp</Name>
|
||||
</ProjectReference>
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||
</Project>
|
||||
Binary file not shown.
@@ -2,7 +2,7 @@
|
||||
<package xmlns="http://schemas.microsoft.com/packaging/2013/05/nuspec.xsd">
|
||||
<metadata>
|
||||
<id>YaraSharp</id>
|
||||
<version>1.2.0</version>
|
||||
<version>1.2.1</version>
|
||||
<title>YaraSharp</title>
|
||||
<authors>stellarbears</authors>
|
||||
<owners>stellarbears</owners>
|
||||
@@ -16,7 +16,8 @@
|
||||
<tags>yara yara-scanner wrapper-api wrapper-library yara-forensics wrapper libyara async-scanning net csharp</tags>
|
||||
</metadata>
|
||||
<files>
|
||||
<file src="Release\x86\YaraSharp.dll" target="lib/net" />
|
||||
<file src="Release\**\YaraSharp.dll" target="build/net" />
|
||||
<file src="Release\**\YaraSharp.props" target="build/net" />
|
||||
<file src="Release\**\YaraSharp.targets" target="build/net" />
|
||||
</files>
|
||||
</package>
|
||||
@@ -7,10 +7,6 @@ param (
|
||||
$projectName = (Split-Path $SourceDirectory -Leaf)
|
||||
$ErrorActionPreference = 'Stop'
|
||||
|
||||
& $msbuild /m "$SourceDirectory/$projectName.sln" /p:Configuration=Release /p:Platform="Any CPU" '/t:Clean;Rebuild'
|
||||
if (-not $?) {
|
||||
throw "msbuild returned error code: $LASTEXITCODE"
|
||||
}
|
||||
& $msbuild /m "$SourceDirectory/$projectName.sln" /p:Configuration=Release /p:Platform="x86" '/t:Clean;Rebuild'
|
||||
if (-not $?) {
|
||||
throw "msbuild returned error code: $LASTEXITCODE"
|
||||
@@ -20,7 +16,7 @@ if (-not $?) {
|
||||
throw "msbuild returned error code: $LASTEXITCODE"
|
||||
}
|
||||
|
||||
(Get-Content "props").replace('PROJECTNAME', $projectName) | Set-Content "$SourceDirectory/Build/Release/$projectName.props"
|
||||
(Get-Content "targets").replace('PROJECTNAME', $projectName) | Set-Content "$SourceDirectory/Build/Release/$projectName.targets"
|
||||
|
||||
& $nuget pack -Exclude **\*.pdb -BasePath "$SourceDirectory/Build" "$PSScriptRoot/$projectName.nuspec"
|
||||
|
||||
-11
@@ -1,11 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup>
|
||||
<Reference Include="PROJECTNAME" Condition="'$(Platform)' == 'x86'">
|
||||
<HintPath>$(MSBuildThisFileDirectory)..\net\x86\PROJECTNAME.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="PROJECTNAME" Condition="'$(Platform)' == 'x64'">
|
||||
<HintPath>$(MSBuildThisFileDirectory)..\net\x64\PROJECTNAME.dll</HintPath>
|
||||
</Reference>
|
||||
</ItemGroup>
|
||||
</Project>
|
||||
@@ -0,0 +1,43 @@
|
||||
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<!--Based on SQLite .targets file-->
|
||||
<!--Library Build Items-->
|
||||
<ItemGroup>
|
||||
<PROJECTNAMEFiles Condition="'$(MSBuildThisFileDirectory)' != '' And HasTrailingSlash('$(MSBuildThisFileDirectory)')"
|
||||
Include="$(MSBuildThisFileDirectory)**\PROJECTNAME.*" />
|
||||
</ItemGroup>
|
||||
|
||||
<!--Library Content Items-->
|
||||
<ItemGroup Condition="'$(ContentPROJECTNAMEFiles)' != '' And '$(ContentPROJECTNAMEFiles)' != 'false' And '@(PROJECTNAMEFiles)' != ''">
|
||||
<Content Include="@(PROJECTNAMEFiles)">
|
||||
<Link>%(RecursiveDir)%(FileName)%(Extension)</Link>
|
||||
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
|
||||
</Content>
|
||||
</ItemGroup>
|
||||
|
||||
<!--Library Build Targets-->
|
||||
<Target Name="CopyPROJECTNAMEFiles" Condition="'$(CopyPROJECTNAMEFiles)' != 'false' And '$(OutDir)' != '' And HasTrailingSlash('$(OutDir)') And Exists('$(OutDir)')"
|
||||
Inputs="@(PROJECTNAMEFiles)" Outputs="@(PROJECTNAMEFiles -> '$(OutDir)%(RecursiveDir)%(Filename)%(Extension)')">
|
||||
<Copy SourceFiles="@(PROJECTNAMEFiles)" DestinationFiles="@(PROJECTNAMEFiles -> '$(OutDir)lib\%(RecursiveDir)%(Filename)%(Extension)')" />
|
||||
</Target>
|
||||
|
||||
<Target Name="CleanPROJECTNAMEFiles" Condition="'$(CleanPROJECTNAMEFiles)' != 'false' And '$(OutDir)' != '' And HasTrailingSlash('$(OutDir)') And Exists('$(OutDir)')">
|
||||
<Delete Files="@(PROJECTNAMEFiles -> '$(OutDir)lib\%(RecursiveDir)%(Filename)%(Extension)')" />
|
||||
</Target>
|
||||
|
||||
|
||||
<!--Library Build Properties-->
|
||||
<PropertyGroup>
|
||||
<PostBuildEventDependsOn>
|
||||
$(PostBuildEventDependsOn);
|
||||
CopyPROJECTNAMEFiles;
|
||||
</PostBuildEventDependsOn>
|
||||
<BuildDependsOn>
|
||||
$(BuildDependsOn);
|
||||
CopyPROJECTNAMEFiles;
|
||||
</BuildDependsOn>
|
||||
<CleanDependsOn>
|
||||
$(CleanDependsOn);
|
||||
CleanPROJECTNAMEFiles;
|
||||
</CleanDependsOn>
|
||||
</PropertyGroup>
|
||||
</Project>
|
||||
Reference in New Issue
Block a user