Marcus Meissner
853e9337e9
- updated to 4.06c - afl-fuzz: - ensure temporary file descriptor is closed when not used - added `AFL_NO_WARN_INSTABILITY` - added time_wo_finds to fuzzer_stats - fixed a crash in pizza (1st april easter egg) mode. Sorry for everyone who was affected! - allow pizza mode to be disabled when AFL_PIZZA_MODE is set to -1 - option `-p mmopt` now also selects new queue items more often - fix bug in post_process custom mutator implementation - print name of custom mutator in UI - slight changes that improve fuzzer performance - afl-cc: - add CFI sanitizer variant to gcc targets - llvm 16 + 17 support (thanks to @devnexen!) - support llvm 15 native pcguard changes - support for LLVMFuzzerTestOneInput -1 return - LTO autoken and llvm_mode: added AFL_LLVM_DICT2FILE_NO_MAIN support - qemu_mode: - fix _RANGES envs to allow hyphens in the filenames - basic riscv support - frida_mode: - added `AFL_FRIDA_STATS_INTERVAL` - fix issue on MacOS - unicorn_mode: - updated and minor issues fixed - nyx_mode support for all tools - better sanitizer default options support for all tools - new custom module: autotoken, a grammar free fuzzer for text inputs - fixed custom mutator C examples OBS-URL: https://build.opensuse.org/request/show/1079878 OBS-URL: https://build.opensuse.org/package/show/devel:tools/afl?expand=0&rev=164
121 lines
3.8 KiB
RPMSpec
121 lines
3.8 KiB
RPMSpec
#
|
|
# spec file for package afl
|
|
#
|
|
# Copyright (c) 2023 SUSE LLC
|
|
#
|
|
# All modifications and additions to the file contributed by third parties
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
# upon. The license for this file, and modifications and additions to the
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
# license for the pristine package is not an Open Source License, in which
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
# published by the Open Source Initiative.
|
|
|
|
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
|
#
|
|
|
|
|
|
%define afl_rt compiler-rt,llvm-rt,llvm-rt-lto
|
|
|
|
%ifarch %{arm} %ix86 s390x x86_64
|
|
%define afl_32 1
|
|
%endif
|
|
%ifarch ppc64le
|
|
%if %{pkg_vcmp clang < 12}
|
|
%define afl_32 1
|
|
%endif
|
|
%endif
|
|
|
|
%ifarch aarch64 ppc64 ppc64le riscv64 s390x x86_64
|
|
%define afl_64 1
|
|
%endif
|
|
|
|
Name: afl
|
|
Version: 4.06c
|
|
Release: 0
|
|
Summary: American fuzzy lop is a security-oriented fuzzer
|
|
#URL: https://lcamtuf.coredump.cx/afl/
|
|
License: Apache-2.0
|
|
URL: https://github.com/AFLplusplus/AFLplusplus
|
|
Source: https://github.com/AFLplusplus/AFLplusplus/archive/%{version}.tar.gz
|
|
Source1: afl-rpmlintrc
|
|
Patch1: afl-3.0c-fix-paths.patch
|
|
BuildRequires: gcc-c++
|
|
BuildRequires: (clang < 16 or clang15)
|
|
%ifarch x86_64
|
|
BuildRequires: gcc-32bit
|
|
%endif
|
|
%if %?suse_version >= 1550
|
|
BuildRequires: gcc-devel
|
|
%endif
|
|
BuildRequires: lld
|
|
BuildRequires: python3-devel
|
|
BuildRequires: ((llvm-devel >= 11.0.0 with llvm-devel < 16) or llvm15-devel)
|
|
Requires: lld
|
|
|
|
%description
|
|
American fuzzy lop is a security-oriented fuzzer that employs a novel type
|
|
of compile-time instrumentation and genetic algorithms to automatically
|
|
discover clean, interesting test cases that trigger new internal states in
|
|
the targeted binary. This substantially improves the functional coverage
|
|
for the fuzzed code. The compact synthesized corpora produced by the tool
|
|
are also useful for seeding other, more labor- or resource-intensive
|
|
testing regimes down the road.
|
|
|
|
Compared to other instrumented fuzzers, afl-fuzz is designed to be
|
|
practical: it has modest performance overhead, uses a variety of highly
|
|
effective fuzzing strategies and effort minimization tricks, requires
|
|
essentially no configuration, and seamlessly handles complex, real-world
|
|
use cases - say, common image parsing or file compression libraries.
|
|
|
|
%prep
|
|
%setup -q -n AFLplusplus-%version
|
|
%patch1 -p1
|
|
sed -i 's|#!/usr/bin/env sh|#!/bin/sh|g' afl-cmin
|
|
sed -i 's|#!/usr/bin/env bash|#!/bin/bash|g' afl-cmin.bash
|
|
|
|
%build
|
|
export CFLAGS="$CFLAGS %{optflags} -fno-lto"
|
|
%ifnarch %{ix86} x86_64
|
|
export AFL_NO_X86=1
|
|
%endif
|
|
make %{?_smp_mflags} PREFIX=%{_prefix} LIBEXEC_DIR=%{_libexecdir} DOC_DIR=%{_docdir}
|
|
# make radamsa
|
|
|
|
%install
|
|
%ifnarch %{ix86} x86_64
|
|
export AFL_NO_X86=1
|
|
%endif
|
|
make %{?_smp_mflags} PREFIX=%{_prefix} LIBEXEC_DIR=%{_libexecdir} DOC_DIR=%{_docdir} MAN_PATH=%{_mandir}/man8 DESTDIR=%{buildroot} install
|
|
chmod -x %{buildroot}/%{_libexecdir}/%{name}/*.o
|
|
|
|
%files
|
|
%license docs/COPYING LICENSE
|
|
%doc /usr/share/doc/packages/%name/
|
|
%{_bindir}/%{name}-*
|
|
%dir %{_libexecdir}/%{name}
|
|
%{_libexecdir}/%{name}/%{name}-as
|
|
%{_libexecdir}/%{name}/as
|
|
%if 0%{?afl_64}
|
|
%{_libexecdir}/%{name}/afl-{%{afl_rt}}-64.o
|
|
%endif
|
|
%if 0%{?afl_32}
|
|
%{_libexecdir}/%{name}/afl-{%{afl_rt}}-32.o
|
|
%endif
|
|
%ifarch aarch64
|
|
%{_libexecdir}/%{name}/afl-llvm-rt-lto-32.o
|
|
%endif
|
|
%{_libexecdir}/%{name}/afl-{%{afl_rt}}.o
|
|
%{_libexecdir}/%{name}/dynamic_list.txt
|
|
%{_libexecdir}/%{name}/*.so
|
|
%{_libexecdir}/%{name}/*.a
|
|
%dir %{_datadir}/%{name}
|
|
%dir %{_datadir}/%{name}/testcases
|
|
%{_datadir}/%{name}/testcases/*
|
|
%dir %{_datadir}/afl/dictionaries/
|
|
%{_datadir}/afl/dictionaries/*
|
|
%{_mandir}/man8/afl*.8*
|
|
|
|
%changelog
|