tangled
alpha
login
or
join now
khanwinter.com
/
CBOR
A fast, safe, and efficient CBOR serialization library for Swift on any platform.
swiftpackageindex.com/thecoolwinter/CBOR/1.1.1/documentation/cbor
atproto
swift
cbor
2
fork
atom
overview
issues
pulls
pipelines
Break Fuzzing out into it's own step
Khan Winter
5 months ago
5bda8ef9
ab87a98d
+15
-7
1 changed file
expand all
collapse all
unified
split
.github
workflows
ci.yml
+15
-7
.github/workflows/ci.yml
···
38
38
else
39
39
set -o pipefail && swift test | xcbeautify
40
40
fi
41
41
+
42
42
+
fuzz:
43
43
+
name: Fuzzing CBOR
44
44
+
needs: swiftlint
45
45
+
runs-on: macos-latest
46
46
+
steps:
47
47
+
- name: Checkout repository
48
48
+
uses: actions/checkout@v5
49
49
+
- uses: swift-actions/setup-swift@v2
50
50
+
with:
51
51
+
swift-version: "6.1"
41
52
- name: Building Fuzzing Target
42
53
run: |
43
43
-
if [ "$RUNNER_OS" == "Linux" ]; then
44
44
-
swift build -c release --sanitize fuzzer,address
45
45
-
else
46
46
-
set -o pipefail && swift build -c release --sanitize fuzzer,address | xcbeautify
47
47
-
fi
48
48
-
- name: Fuzzing For 30 Seconds
54
54
+
set -o pipefail && swift build -c release --sanitize fuzzer,address | xcbeautify
55
55
+
- name: Fuzzing For 15 Seconds
49
56
run: |
50
57
mkdir -p .fuzz
51
58
mkdir -p .fuzz/new-corpus
52
59
mkdir -p .fuzz/corpus
53
60
mkdir -p .fuzz/artifacts
54
54
-
./.build/release/Fuzzing .fuzz/new-corpus .fuzz/corpus -max_total_time=10 -artifact_prefix=.fuzz/artifacts -max_len=1000000
61
61
+
./.build/release/Fuzzing .fuzz/new-corpus .fuzz/corpus -max_total_time=15 -artifact_prefix=.fuzz/artifacts -max_len=1000000
55
62
- name: "Upload Fuzzing Artifacts (if available)"
56
63
uses: actions/upload-artifact@v4
57
64
with:
···
59
66
path: ".fuzz/artifacts"
60
67
if-no-files-found: "ignore"
61
68
retention-days: 14
69
69
+