Skip to content

Conversation

lomackie
Copy link
Contributor

@lomackie lomackie commented Jul 25, 2025

Please ensure your pull request adheres to the following guidelines:

  • For first time contributors, read Submitting a pull request
  • All code is covered by unit and/or runtime tests where feasible.
  • All commits contain a well written commit description including a title,
    description and a Fixes: #XXX line if the commit addresses a particular
    GitHub issue.
  • If your commit description contains a Fixes: <commit-id> tag, then
    please add the commit author[s] as reviewer[s] to this issue.
  • All commits are signed off. See the section Developer’s Certificate of Origin
  • Provide a title or release-note blurb suitable for the release notes.
  • Are you a user of Cilium? Please add yourself to the Users doc
  • Thanks for contributing!

This PR causes all fuzzers to build successfully (tested locally using my fork of oss-fuzz here: lomackie/oss-fuzz@e59bb05). I'm not entirely sure if it will build perfectly in CI but this workflow was green a few commits ago (doesn't account for any of the cncf-fuzzing changes - but those can fail without the build failing): https://github.com/cilium/cilium/actions/runs/16532943538

Linked PRs:

Given there are now going to be more fuzzers running which haven't run for a while I'd expect to see a bunch of tests failing, I can't see the original failure in the linked issue as the build logs have expired, but I'm assuming this resolving just the build errors is okay, and the tests themselves are a separate issue.

Fixes: #37885

@maintainer-s-little-helper maintainer-s-little-helper bot added the dont-merge/needs-release-note-label The author needs to describe the release impact of these changes. label Jul 25, 2025
@github-actions github-actions bot added the kind/community-contribution This was a contribution made by a community member. label Jul 25, 2025
@lomackie lomackie force-pushed the fix-ci-fuzz branch 2 times, most recently from 93bd463 to 74ff276 Compare July 25, 2025 20:38
@joestringer joestringer added the release-note/ci This PR makes changes to the CI. label Jul 25, 2025
@maintainer-s-little-helper maintainer-s-little-helper bot removed the dont-merge/needs-release-note-label The author needs to describe the release impact of these changes. label Jul 25, 2025
@lomackie lomackie force-pushed the fix-ci-fuzz branch 4 times, most recently from 08a3c4e to 446cee3 Compare July 25, 2025 22:10
@lomackie lomackie changed the title cli: Fix CI-Fuzz failures ci: Fix CI-Fuzz failures Jul 25, 2025
@maintainer-s-little-helper
Copy link

Commit 6994b8a does not match "(?m)^Signed-off-by:".

Please follow instructions provided in https://docs.cilium.io/en/stable/contributing/development/contributing_guide/#developer-s-certificate-of-origin

@maintainer-s-little-helper maintainer-s-little-helper bot added the dont-merge/needs-sign-off The author needs to add signoff to their commits before merge. label Jul 26, 2025
@maintainer-s-little-helper maintainer-s-little-helper bot removed the dont-merge/needs-sign-off The author needs to add signoff to their commits before merge. label Jul 26, 2025
lomackie added a commit to lomackie/cncf-fuzzing that referenced this pull request Jul 26, 2025
Already being copied in cilium/cilium#40728

Signed-off-by: lomackie <me@louismackie.com>
@lomackie lomackie force-pushed the fix-ci-fuzz branch 2 times, most recently from bd4a095 to 9d46054 Compare July 28, 2025 18:17
AdamKorcz pushed a commit to cncf/cncf-fuzzing that referenced this pull request Jul 28, 2025
* Remove elf fuzzer

Source was deleted by cilium/cilium@03b614f

Signed-off-by: lomackie <me@louismackie.com>

* Remove bgp config fuzzer

Source was deleted by cilium@cilium/c2b935042f3efe44eecbe434a312256237c4960f

Signed-off-by: lomackie <me@louismackie.com>

* Remove monitor fuzzers

These were removed by #467

Signed-off-by: lomackie <me@louismackie.com>

* Run separate cilium/proxy fuzz build

proxylib removed from cilium/cilium in cilium/cilium@51fc881
and moved to cilium/proxy
CXXFLAGS updated to resolve linker errors in final clang++ step

Signed-off-by: lomackie <me@louismackie.com>

* Remove bpf_fuzzer.go

BPFFSMigration was removed by cilium/cilium@8f5e88f

Signed-off-by: lomackie <me@louismackie.com>

* Remove logger setup

Moved to slog as part of cilium/cilium@5a54846

Signed-off-by: lomackie <me@louismackie.com>

* Update NewMonitorFormatter args

Align with cilium/cilium@4d33968

Signed-off-by: lomackie <me@louismackie.com>

* Remove l4_test

Already being copied in cilium/cilium#40728

Signed-off-by: lomackie <me@louismackie.com>

* Symlink cilium/proxy under GOPATH

The oss-fuzz action handles this for cilium/cilium so we need to do it
manually for cilium/proxy

Signed-off-by: lomackie <me@louismackie.com>

---------

Signed-off-by: lomackie <me@louismackie.com>
@lomackie lomackie marked this pull request as ready for review July 28, 2025 18:59
@lomackie lomackie requested review from a team as code owners July 28, 2025 18:59
@lomackie lomackie requested review from Artyop and fristonio July 28, 2025 18:59
@lomackie
Copy link
Contributor Author

Looks like passing a nil Logger is causing the fuzzers to fail. You'll have to construct a logger and pass it directly.

Yes I see the issue, thanks. I've updated all the fuzzers to use a slog.Logger and they all seem to run for me locally now. I used io.Discard as the logs were very spammy but I can change them if seeing them is important. I've made the same change here: cncf/cncf-fuzzing#558

The only test that seems to fail now is fuzz_multiple_parsers from cncf/cncf-fuzzing: https://github.com/lomackie/cncf-fuzzing/blob/main/projects/cilium/OnData_fuzzer.go#L151. Strangely it doesn't crash, it just exits out with status code 1. I'll do some digging to try and find out where that is coming from.

@joestringer joestringer added the needs-backport/1.18 This PR / issue needs backporting to the v1.18 branch label Jul 29, 2025
@lomackie
Copy link
Contributor Author

I think with these 3 PRs merged everything should build and run, I have all 14 fuzzers building and running successfully locally:
google/oss-fuzz#13746
cncf/cncf-fuzzing#559
cilium/proxy#1487

@squeed
Copy link
Contributor

squeed commented Jul 30, 2025

@lomackie nice. Any order in which these should be merged?

@squeed
Copy link
Contributor

squeed commented Jul 30, 2025

/test

@lomackie
Copy link
Contributor Author

@lomackie nice. Any order in which these should be merged?

I think as long as they all go in before this one it doesn't particularly matter.

lomackie added 3 commits July 31, 2025 00:03
Source file was deleted by 9d3c5e5
Fixes: cilium#37885

Signed-off-by: lomackie <me@louismackie.com>
l4_filter_test.go requires perSelectorPolicyToString

Signed-off-by: lomackie <me@louismackie.com>
hivetest.Logger(t) isn't compatible with go-fuzz as the replacement *testing.T does not implement Chdir()
hivetest.Logger(t) was been introduced by 5a54846, while CI Fuzz was not working.
Replacing these with a slog.Logger that outputs nothing.

Signed-off-by: lomackie <me@louismackie.com>
@lomackie
Copy link
Contributor Author

lomackie commented Jul 30, 2025

Annoyingly my oss-fuzz PR fails its CI because the project CIFuzz build doesn't work (which this PR is supposed to fix). google/oss-fuzz#13746

So this one will need to be merged first. The fuzzers should still be green without my other PRs merged in first, there will just be one fuzzer missing from the build and runs.

I think some of the ginkgo tests are failing due to #40801 so hopefully a rebase might fix it, but I'm not sure if that first failing test is related to that issue. Are you able to rerun the test suite now that I've rebased? Thanks

Copy link
Member

@fristonio fristonio left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚀

@fristonio
Copy link
Member

/test

@maintainer-s-little-helper maintainer-s-little-helper bot added the ready-to-merge This PR has passed all tests and received consensus from code owners to merge. label Jul 30, 2025
@joestringer joestringer added this pull request to the merge queue Aug 1, 2025
@joestringer
Copy link
Member

Thanks for this @lomackie . Happy to see the CIFuzz workflow passing again 🎉

Merged via the queue into cilium:main with commit 129e218 Aug 1, 2025
69 checks passed
DavidKorczynski pushed a commit to google/oss-fuzz that referenced this pull request Aug 6, 2025
See cilium/cilium#40728 and
cncf/cncf-fuzzing#557 for full context

Signed-off-by: lomackie <me@louismackie.com>
@rastislavs rastislavs mentioned this pull request Aug 6, 2025
17 tasks
@rastislavs rastislavs added backport-pending/1.18 The backport for Cilium 1.18.x for this PR is in progress. and removed needs-backport/1.18 This PR / issue needs backporting to the v1.18 branch labels Aug 6, 2025
@github-actions github-actions bot added backport-done/1.18 The backport for Cilium 1.18.x for this PR is done. and removed backport-pending/1.18 The backport for Cilium 1.18.x for this PR is in progress. labels Aug 8, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport-done/1.18 The backport for Cilium 1.18.x for this PR is done. kind/community-contribution This was a contribution made by a community member. ready-to-merge This PR has passed all tests and received consensus from code owners to merge. release-note/ci This PR makes changes to the CI.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Fix CI-Fuzz breakage
7 participants