aboutsummaryrefslogtreecommitdiff
path: root/fuzz/Jellyfin.Server.Fuzz
diff options
context:
space:
mode:
Diffstat (limited to 'fuzz/Jellyfin.Server.Fuzz')
-rw-r--r--fuzz/Jellyfin.Server.Fuzz/Jellyfin.Server.Fuzz.csproj22
-rw-r--r--fuzz/Jellyfin.Server.Fuzz/Program.cs33
-rw-r--r--fuzz/Jellyfin.Server.Fuzz/Testcases/UrlDecodeQueryFeature/test1.txt1
-rwxr-xr-xfuzz/Jellyfin.Server.Fuzz/fuzz.sh11
4 files changed, 0 insertions, 67 deletions
diff --git a/fuzz/Jellyfin.Server.Fuzz/Jellyfin.Server.Fuzz.csproj b/fuzz/Jellyfin.Server.Fuzz/Jellyfin.Server.Fuzz.csproj
deleted file mode 100644
index 20bc4c7244..0000000000
--- a/fuzz/Jellyfin.Server.Fuzz/Jellyfin.Server.Fuzz.csproj
+++ /dev/null
@@ -1,22 +0,0 @@
-<Project Sdk="Microsoft.NET.Sdk.Web">
-
- <PropertyGroup>
- <OutputType>Exe</OutputType>
- <TargetFramework>net7.0</TargetFramework>
- </PropertyGroup>
-
- <ItemGroup>
- <Reference Include="Jellyfin.Server">
- <HintPath>jellyfin.dll</HintPath>
- </Reference>
- </ItemGroup>
-
- <ItemGroup>
- <ProjectReference Include="../../MediaBrowser.Common/MediaBrowser.Common.csproj" />
- </ItemGroup>
-
- <ItemGroup>
- <PackageReference Include="SharpFuzz" />
- </ItemGroup>
-
-</Project>
diff --git a/fuzz/Jellyfin.Server.Fuzz/Program.cs b/fuzz/Jellyfin.Server.Fuzz/Program.cs
deleted file mode 100644
index e47286c131..0000000000
--- a/fuzz/Jellyfin.Server.Fuzz/Program.cs
+++ /dev/null
@@ -1,33 +0,0 @@
-using System;
-using System.Collections.Generic;
-using Jellyfin.Server.Middleware;
-using Microsoft.AspNetCore.Http;
-using Microsoft.AspNetCore.Http.Features;
-using Microsoft.Extensions.Primitives;
-using SharpFuzz;
-
-namespace Emby.Server.Implementations.Fuzz
-{
- public static class Program
- {
- public static void Main(string[] args)
- {
- switch (args[0])
- {
- case "UrlDecodeQueryFeature": Run(UrlDecodeQueryFeature); return;
- default: throw new ArgumentException($"Unknown fuzzing function: {args[0]}");
- }
- }
-
- private static void Run(Action<string> action) => Fuzzer.OutOfProcess.Run(action);
-
- private static void UrlDecodeQueryFeature(string data)
- {
- var dict = new Dictionary<string, StringValues>
- {
- { data, StringValues.Empty }
- };
- _ = new UrlDecodeQueryFeature(new QueryFeature(new QueryCollection(dict)));
- }
- }
-}
diff --git a/fuzz/Jellyfin.Server.Fuzz/Testcases/UrlDecodeQueryFeature/test1.txt b/fuzz/Jellyfin.Server.Fuzz/Testcases/UrlDecodeQueryFeature/test1.txt
deleted file mode 100644
index 73f356b936..0000000000
--- a/fuzz/Jellyfin.Server.Fuzz/Testcases/UrlDecodeQueryFeature/test1.txt
+++ /dev/null
@@ -1 +0,0 @@
-a%3D1%26b%3D2%26c%3D3
diff --git a/fuzz/Jellyfin.Server.Fuzz/fuzz.sh b/fuzz/Jellyfin.Server.Fuzz/fuzz.sh
deleted file mode 100755
index 303eb21356..0000000000
--- a/fuzz/Jellyfin.Server.Fuzz/fuzz.sh
+++ /dev/null
@@ -1,11 +0,0 @@
-#!/bin/sh
-
-set -e
-
-dotnet build -c Release ../../Jellyfin.Server/Jellyfin.Server.csproj --output bin
-sharpfuzz bin/jellyfin.dll
-cp bin/jellyfin.dll .
-
-dotnet build
-mkdir -p Findings
-AFL_SKIP_BIN_CHECK=1 afl-fuzz -i "Testcases/$1" -o "Findings/$1" -t 5000 -m 10240 dotnet bin/Debug/net6.0/Jellyfin.Server.Fuzz.dll "$1"