Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

build_fuzzers action fails on syzkaller project #10989

Closed
a-nogikh opened this issue Sep 20, 2023 · 4 comments · Fixed by google/syzkaller#4221
Closed

build_fuzzers action fails on syzkaller project #10989

a-nogikh opened this issue Sep 20, 2023 · 4 comments · Fixed by google/syzkaller#4221
Assignees

Comments

@a-nogikh
Copy link

Hello,

A few days ago our oss-fuzz pre-submit action began to fail 100% of the time with the following error:

2023-09-20T12:46:41.2697493Z + compile_go_fuzzer github.com/google/syzkaller/pkg/compiler Fuzz compiler_fuzzer
2023-09-20T12:46:41.2735973Z /usr/local/bin/compile_go_fuzzer: line 28: cd: /root/go/src/github.com/google/syzkaller/pkg/compiler: No such file or directory
2023-09-20T12:46:41.5369177Z github.com/google/syzkaller/pkg/compiler
2023-09-20T12:46:41.5882163Z github.com/google/syzkaller/pkg/compiler
2023-09-20T12:46:41.5892912Z Running go-fuzz -tags gofuzz -func Fuzz -o compiler_fuzzer.a github.com/google/syzkaller/pkg/compiler
2023-09-20T12:46:56.0962104Z + compile_go_fuzzer github.com/google/syzkaller/prog/test FuzzDeserialize prog_deserialize_fuzzer
2023-09-20T12:46:56.0987333Z /usr/local/bin/compile_go_fuzzer: line 28: cd: /root/go/src/github.com/google/syzkaller/prog/test: No such file or directory
2023-09-20T12:46:56.3639258Z github.com/google/syzkaller/prog/test
2023-09-20T12:46:56.4159026Z github.com/google/syzkaller/prog/test
2023-09-20T12:46:56.4171622Z Running go-fuzz -tags gofuzz -func FuzzDeserialize -o prog_deserialize_fuzzer.a github.com/google/syzkaller/prog/test
2023-09-20T12:46:58.0466767Z + compile_go_fuzzer github.com/google/syzkaller/prog/test FuzzParseLog prog_parselog_fuzzer
2023-09-20T12:46:58.0493963Z /usr/local/bin/compile_go_fuzzer: line 28: cd: /root/go/src/github.com/google/syzkaller/prog/test: No such file or directory
2023-09-20T12:46:58.3455892Z github.com/google/syzkaller/prog/test
2023-09-20T12:46:58.4104276Z github.com/google/syzkaller/prog/test
2023-09-20T12:46:58.4119080Z Running go-fuzz -tags gofuzz -func FuzzParseLog -o prog_parselog_fuzzer.a github.com/google/syzkaller/prog/test
2023-09-20T12:46:59.9486701Z + compile_go_fuzzer github.com/google/syzkaller/pkg/report Fuzz report_fuzzer
2023-09-20T12:46:59.9516840Z /usr/local/bin/compile_go_fuzzer: line 28: cd: /root/go/src/github.com/google/syzkaller/pkg/report: No such file or directory
2023-09-20T12:47:00.4717192Z github.com/google/syzkaller/pkg/report
2023-09-20T12:47:00.7119005Z github.com/google/syzkaller/pkg/report
2023-09-20T12:47:00.7139327Z Running go-fuzz -tags gofuzz -func Fuzz -o report_fuzzer.a github.com/google/syzkaller/pkg/report
2023-09-20T12:48:45.0215442Z /usr/bin/ld: /usr/bin/ld: DWARF error: invalid or unhandled FORM value: 0x25
2023-09-20T12:48:45.0217091Z report_fuzzer.a(000021.o): in function `_cgo_9c8efe9babca_C2func_res_search':
2023-09-20T12:48:45.0329186Z cgo_unix_cgo_res.cgo2.c:(.text+0x32): undefined reference to `__res_search'
2023-09-20T12:48:45.0330054Z /usr/bin/ld: report_fuzzer.a(000021.o): in function `_cgo_9c8efe9babca_Cfunc_res_search':
2023-09-20T12:48:45.0330556Z cgo_unix_cgo_res.cgo2.c:(.text+0x81): undefined reference to `__res_search'
2023-09-20T12:48:45.8122842Z clang-15: error: linker command failed with exit code 1 (use -v to see invocation)
2023-09-20T12:48:48.8019821Z 2023-09-20 12:48:48,801 - root - ERROR - Building fuzzers failed.
2023-09-20T12:48:48.8024317Z 2023-09-20 12:48:48,801 - root - ERROR - Error building fuzzers for (commit: 348a0f03bc7330f7a92f18573557f6a67b41c757, pr_ref: refs/pull/4217/merge).

There have been no recent changes on our side that could have caused any such compilation errors. Could you please give some pointers where to look for the actual problem?

Here's the workflow config that we use: https://github.com/google/syzkaller/blob/master/.github/workflows/oss-fuzz.yml

Cc @dvyukov

@jonathanmetzman
Copy link
Contributor

The timing makes me think it's related to 6efce3b any ideas @catenacyber ? I may have to revert if I can't figure it out.

@catenacyber
Copy link
Contributor

Looks like export CXX="${CXX} -lresolv" is not applied...

@catenacyber
Copy link
Contributor

Looks like export CXX="${CXX} -lresolv" is not applied...

Because the language was not explicitly set to golang as your PR does ;-)

@jonathanmetzman
Copy link
Contributor

Yeah I meant to tell you I figured it out

jonathanmetzman added a commit to jonathanmetzman/syzkaller that referenced this issue Sep 27, 2023
Fix compilation error and make other improvements:
* Only upload crash on run fail, not build fail
* Enable SARIF notification.
Fixes: google/oss-fuzz#10989
github-merge-queue bot pushed a commit to google/syzkaller that referenced this issue Sep 27, 2023
Fix compilation error and make other improvements:
* Only upload crash on run fail, not build fail
* Enable SARIF notification.
Fixes: google/oss-fuzz#10989
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants