aboutsummaryrefslogtreecommitdiffstats
path: root/tools/syz-bisect
Commit message (Collapse)AuthorAgeFilesLines
* pkg/build/linux: support building with a custom make binaryFlorent Revest2024-10-141-0/+2
| | | | | | Certain environments might need a specific make command or wrap make calls with extra logic. This lets users provide a path to a custom make binary.
* syz-ci: specify per-manager bisection backportsAleksandr Nogikh2023-07-201-3/+5
| | | | | | | | It might be the case that the kernels that are being fuzzed on syz-ci require their own backports to build/test older revisions during bisection. Let users specify it in the syz-ci config.
* pkg/bisect: support bisections on other treesAleksandr Nogikh2023-06-291-2/+4
| | | | | | | | | | | | | | | | | | | The current code only supports fix/cause bisections when the known bad commit is reachable from Kernel.Repo/Kernel.Branch. Add a CrossTree parameter to pkg/bisect. If it's set to true and we're doing a fix bisection, the bisection algorithm first operates with the original commit message (i.e. checks that it indeed crashes the kernel and performs config minimization), but the actual bisection starts from the merge base of Commit and Branch. We could have calculated the merge base outside of pkg/bisect and just started the algorithm from that merge base, but there's a problem: there's no guarantee that the kernel will build/boot with a syzbot config at the merge base. So we take the commit known to work well and then assume that the bug is also present on the merge base commit. If it were not present, we wouldn't have found a fix commit from Branch anyway.
* tools/syz-bisect: support Linker parameterAleksandr Nogikh2023-06-151-0/+2
|
* all: tools/syz-env make generate resultTaras Madan2023-02-241-2/+2
|
* all: ioutil is deprecated in go1.19 (#3718)Taras Madan2023-02-231-3/+2
|
* pkg/bisect: use default compiler during bisection where possibleSpace Meyer2022-10-071-5/+7
| | | | | | | This allows us to bisect at least recently introduced bugs, where the manager that found the bug uses a non standard compiler. This is usefull during development of a new sanitizer for which a compiler with non-upstreamed patches is required.
* pkg/bisect: try to reidentify commit rebased after crashSpace Meyer2022-10-061-11/+13
| | | | | | | | | | | | | | When bisecting a breaking commit, syzkaller starts the bisection from the commit recorded in the last crash for the given bug. Previously the bisection was aborted should the commit no longer exist in the repo. Now we try to reidentify the breaking commit. For git pretty much the best we can do is to search a commit reachable from HEAD with the same title. Other VCS systems might have something better. Syzkaller will still first validate that the start commit is indeed broken in the way it expects. This prevents syzkaller from getting confused should we accidentally pick a completely unrelated commit.
* pkg/bisect: support clang for crash bisectionSpace Meyer2022-09-011-5/+8
| | | | | Before we hardcoded bisection to use gcc, now the compiler family can be configured in the bisection config.
* tools/syz-bisect: store bisection resultsJouni Hogander2020-12-101-1/+27
| | | | Store bisection results into given crashdir as fix.commit or cause.commit
* pkg/kconfig: store minimization resultsJouni Hogander2020-12-101-5/+8
| | | | | Store config options identified using DebugTracer. Also change bisection and configuration minimization code to use new DebugTracer.
* tools/syz-bisect: use vcs.HEAD by defaultJouni Hogander2020-12-101-0/+8
| | | | Use vcs.HEAD if syzkaller or kernel commit is not given
* tools/syz-bisect: give kernel/syzkaller commit as argumentsJouni Hogander2020-12-101-19/+11
|
* tools/syz-bisect: use kernel configs from configuration fileJouni Hogander2020-12-101-8/+11
| | | | | | Currently syz-bisect is expecting to find kernel.config and kernel_baseline.config from given crashdir. Unify with syz-ci and use configuration files from bisect config file.
* tools/syz-bisect: read repro.cprog and/or repro.progJouni Hogander2020-12-101-7/+10
| | | | | | Currently syz-bisect is reading repro.c or repro.syz. Syz-manager is storing reproducers as repro.cprog and repro.prog. Use these names instead. Also add check to ensure either one is found before bisect.Run is called
* pkg/mgrconfig: add prog&sys.targets targets to ConfigDmitry Vyukov2020-11-301-2/+2
| | | | | | These are widely used with the config as the refactoring shows. This removes a bunch of unnecessary code. Also fixes a number of bugs where we confused Arch with VMArch.
* pkg/bisect: add ccache optionJouni Hogander2020-09-211-0/+2
| | | | | | Add option to use ccache in kernel builds. Signed-off-by: Jouni Hogander <jouni.hoegander@partner.bmw.de>
* pkg/bisect: Implement config bisectionJouni Hogander2020-07-021-0/+2
| | | | | | | | | Implement Linux kernel configuration bisection. Use bisected minimalistic configuration in commit bisection. Utilizes config_bisect.pl script from Linux kernel tree in bisection. Modify syz-bisect to read in kernel.baseline_config. This is used as a "good" configuration when bisection is run.
* tools/syz-bisect: fix file presence checkDmitry Vyukov2020-04-291-10/+11
| | | | | | 1. Filename should be relative to flagCrash, not the current dir. 2. Use osutil.IsExist, os.Stat can fail for other reasons, e.g. no permissions. 3. Dedup filepresence check.
* pkg/instance: Use syz or c source file when testingJouni Hogander2020-04-291-1/+6
| | | | | | Currenlty only syz file is taken into account when testing. Use also c source file if available. Still use syz as a "main" reproducer.
* pkg/bisect: detect wrong bisectionsDmitry Vyukov2019-11-071-1/+1
| | | | | | | | Detect bisection to merge commits and to commits that don't affect kernel binary (comments, other arches, whitespaces, etc). Such bisections are not reported in emails (but shown on web). Update #1271
* pkg/bisect: modify Run() to return information about commitZubin Mithra2019-11-051-1/+1
| | | | | | | * Modify Run() to return the commit object when a failure occurs on the oldest tested release(for BisectCause) and latest tested release(for BisectFix). * Modify tests to check the returned commit object.
* tools/syz-bisect: add usage docsDmitry Vyukov2019-05-131-9/+34
|
* pkg/bisect: various improvementsDmitry Vyukov2019-03-171-1/+1
| | | | | | | | | | A bunch of improvements after more wide bisection testing. Improve logging. Support returning several commits for inconclusive bisection. Return Report with the final crash. Remove code that was moved to pkg/vcs. Update #501
* pkg/bisect: check existence of input filesDmitry Vyukov2018-12-171-1/+4
| | | | | | It's better to fail early then to wait for kernel build. Update #501
* pkg/mgrconfig: move from syz-manager/mgrconfigDmitry Vyukov2018-08-021-1/+1
| | | | | | | | mgrconfig was used only by syz-manager initially, but now it's used by a dozen of packages and it's weird to import from under a binary dir. pkg/ is much more reasonable dir for a widely used helper package.
* pkg/bisect: add bisection logicDmitry Vyukov2018-05-171-0/+100
Add first version of bisection package (supports both bug and fix bisection). And tools/syz-bisect wrapper for testing. Update #501