-
Notifications
You must be signed in to change notification settings - Fork 3
Open
Description
Hi! I am planning to extend the targets for this project. I am currently looking to add TinyDTLS which also exists in https://github.com/profuzzbench/profuzzbench. However I am finding some issues.
I have the draft in #3.
What I'm facing:
- Building works.
- Each built binary works as intended.
- Fuzzing with
sudo ./target/debug/fuzztruction ./fuzztruction-experiments/comparison-with-state-of-the-art/configurations/networked/tinydtls/dtlsclient_dtlsserver.yml fuzz -j 1 -t 5m
inside the container fails with the following logs.
Unexpected Error: "Workdir \"/tmp/dtlsclient-dtlsserver-1\" exists and --purge was not provided!"
user@lin002:~/fuzztruction$ sudo ./target/debug/fuzztruction ./fuzztruction-experiments/comparison-with-state-of-the-art/configurations/networked/tinydtls/dtlsclient_dtlsserver.yml fuzz -j 1 -t 5m --purge
[2025-05-22 06:30:14:815419078][scheduler][56187][logging.rs:88][INFO] Panics are logged via log::error
[2025-05-22 06:30:14:815526793][fuzztruction][56187][fuzztruction.rs:572][INFO] Privileges will be dropped to uid: "1007" and gid: "1007"
[2025-05-22 06:30:14:815559983][scheduler][56187][checks.rs:157][INFO] Checking whether we have enough permissions to jail the fuzzing process.
[2025-05-22 06:30:14:815604809][scheduler][56187][checks.rs:177][INFO] Changeing umask to 0o000
[2025-05-22 06:30:14:818581552][scheduler][56187][checks.rs:122][INFO] Increasing RLIMIT_NOFILE to 1048576
[2025-05-22 06:30:14:819695322][scheduler][56187][campaign.rs:87][INFO] Spawning 1 worker(s).
[2025-05-22 06:30:14:820233090][scheduler][56187][worker.rs:395][INFO] Waiting for worker WorkerUid(0) to initialize
[2025-05-22 06:30:14:820325128][scheduler][56191][init.rs:24][INFO] Initializing worker WorkerUid(0). Thread id is 56191
[2025-05-22 06:30:14:820434922][scheduler][56191][source.rs:260][DEBUG] Creating workdir "/tmp/dtlsclient-dtlsserver-1/0/source/workdir"
[2025-05-22 06:30:14:820488217][scheduler][56191][source.rs:263][DEBUG] Creating state dir "/tmp/dtlsclient-dtlsserver-1/0/source/state"
[2025-05-22 06:30:14:831366876][scheduler][56191][source.rs:306][INFO] out_file_path=/tmp/dtlsclient-dtlsserver-1/0/source/workdir/93f5568804774ca39ef99b65a06b236d_output
[2025-05-22 06:30:14:858654416][scheduler][56191][init.rs:47][INFO] ret=Output { status: ExitStatus(unix_wait_status(0)), stdout: "", stderr: "" }
[2025-05-22 06:30:14:858702281][scheduler][56191][source.rs:565][DEBUG] Starting source
[2025-05-22 06:30:14:858733830][scheduler][56191][source.rs:567][DEBUG] Creating POSIX queues
[2025-05-22 06:30:14:858764378][scheduler][56191][source.rs:568][DEBUG] Creating sending MQ: /mq_send_8L9WwfCjwPv3UWRvLjXh0QvvrDLWZ5_tid_56191
[2025-05-22 06:30:14:858807048][scheduler][56191][source.rs:577][DEBUG] Creating receiving MQ: /mq_recv_8L9WwfCjwPv3UWRvLjXh0QvvrDLWZ5_tid_56191
[2025-05-22 06:30:14:858842578][scheduler][56191][source.rs:588][DEBUG] Forking child
[2025-05-22 06:30:14:859103737][scheduler][56191][source.rs:786][DEBUG] Waiting for handshake message.
[2025-05-22 06:30:14][generator_agent][56204][logging.rs:74][INFO] Panics are logged via log::error
[2025-05-22 06:30:14][generator_agent][56204][agent.rs:179][INFO] Starting forkserver
[2025-05-22 06:30:14][generator_agent][56204][agent.rs:180][INFO] Agent log level is DEBUG
[2025-05-22 06:30:14][generator_agent][56204][agent.rs:189][INFO] Sending HelloMessage
[2025-05-22 06:30:14:892081417][scheduler][56191][source.rs:790][DEBUG] Got HelloMessage. Agents TID is 56204
[2025-05-22 06:30:14:892692753][scheduler][56191][sink.rs:578][INFO] Forkserver has pid 56225
[2025-05-22 06:30:14:893589313][scheduler][56191][sink.rs:620][INFO] Forkserver status: 0xc2005315
[2025-05-22 06:30:14:893635336][scheduler][56191][sink.rs:622][INFO] Got extended option FS_OPT_MAPSIZE from forkserver
[2025-05-22 06:30:14:893667067][scheduler][56191][sink.rs:624][INFO] Target requests a map of size 10635 bytes
[2025-05-22 06:30:14:893697301][scheduler][56191][sink.rs:625][INFO] Current map size is 262144 bytes
[2025-05-22 06:30:14:893733664][scheduler][56191][init.rs:102][INFO] Worker WorkerUid(0) has the honor of initializing the shared state
[2025-05-22 06:30:14:893778998][scheduler][56191][source.rs:2090][DEBUG] Processing mapping: MapRange { range_start: 93824992247808, range_end: 93824992403456, offset: 16384, dev: "08:31", flags: "r-xp", inode: 668677798, pathname: Some("/home/user/fuzztruction/fuzztruction-experiments/comparison-with-state-of-the-art/binaries/networked/tinydtls/generator/tests/dtls-client") } @ "/home/user/fuzztruction/fuzztruction-experiments/comparison-with-state-of-the-art/binaries/networked/tinydtls/generator/tests/dtls-client"
[2025-05-22 06:30:14:894608222][scheduler][56191][source.rs:2113][INFO] Parsing stackmaps...
[2025-05-22 06:30:14:897520398][scheduler][56191][source.rs:2090][DEBUG] Processing mapping: MapRange { range_start: 140737340821504, range_end: 140737341341696, offset: 65536, dev: "08:01", flags: "r-xp", inode: 2148808099, pathname: Some("/usr/lib/x86_64-linux-gnu/libm.so.6") } @ "/usr/lib/x86_64-linux-gnu/libm.so.6"
[2025-05-22 06:30:14:898481942][scheduler][56191][source.rs:2120][DEBUG] Mapping does not have any patch points.
[2025-05-22 06:30:14:898524955][scheduler][56191][source.rs:2090][DEBUG] Processing mapping: MapRange { range_start: 140737341726720, range_end: 140737341874176, offset: 16384, dev: "08:01", flags: "r-xp", inode: 2148775944, pathname: Some("/usr/lib/x86_64-linux-gnu/libgcc_s.so.1") } @ "/usr/lib/x86_64-linux-gnu/libgcc_s.so.1"
[2025-05-22 06:30:14:898644450][scheduler][56191][source.rs:2120][DEBUG] Mapping does not have any patch points.
[2025-05-22 06:30:14:898682245][scheduler][56191][source.rs:2090][DEBUG] Processing mapping: MapRange { range_start: 140737342541824, range_end: 140737343885312, offset: 643072, dev: "08:01", flags: "r-xp", inode: 2148869470, pathname: Some("/usr/lib/x86_64-linux-gnu/libstdc++.so.6.0.33") } @ "/usr/lib/x86_64-linux-gnu/libstdc++.so.6.0.33"
[2025-05-22 06:30:14:901315191][scheduler][56191][source.rs:2120][DEBUG] Mapping does not have any patch points.
[2025-05-22 06:30:14:901358404][scheduler][56191][source.rs:2090][DEBUG] Processing mapping: MapRange { range_start: 140737344675840, range_end: 140737346281472, offset: 163840, dev: "08:01", flags: "r-xp", inode: 2148708749, pathname: Some("/usr/lib/x86_64-linux-gnu/libc.so.6") } @ "/usr/lib/x86_64-linux-gnu/libc.so.6"
[2025-05-22 06:30:14:902740397][scheduler][56191][source.rs:2120][DEBUG] Mapping does not have any patch points.
[2025-05-22 06:30:14:902781072][scheduler][56191][source.rs:2090][DEBUG] Processing mapping: MapRange { range_start: 140737347641344, range_end: 140737349652480, offset: 958464, dev: "08:31", flags: "r-xp", inode: 11319414434, pathname: Some("/home/user/fuzztruction/target/debug/libgenerator_agent.so") } @ "/home/user/fuzztruction/target/debug/libgenerator_agent.so"
[2025-05-22 06:30:14:967206098][scheduler][56191][source.rs:2120][DEBUG] Mapping does not have any patch points.
[2025-05-22 06:30:14:967274822][scheduler][56191][source.rs:2090][DEBUG] Processing mapping: MapRange { range_start: 140737353887744, range_end: 140737353895936, offset: 0, dev: "00:00", flags: "r-xp", inode: 0, pathname: Some("[vdso]") } @ "[vdso]"
[2025-05-22 06:30:14:967319113][scheduler][56191][source.rs:2093][WARN] File of mapping not found: "[vdso]"
[2025-05-22 06:30:14:967362907][scheduler][56191][source.rs:2090][DEBUG] Processing mapping: MapRange { range_start: 140737353900032, range_end: 140737354076160, offset: 4096, dev: "08:01", flags: "r-xp", inode: 2148708727, pathname: Some("/usr/lib/x86_64-linux-gnu/ld-linux-x86-64.so.2") } @ "/usr/lib/x86_64-linux-gnu/ld-linux-x86-64.so.2"
[2025-05-22 06:30:14:967538460][scheduler][56191][source.rs:2120][DEBUG] Mapping does not have any patch points.
[2025-05-22 06:30:14:967575475][scheduler][56191][source.rs:2090][DEBUG] Processing mapping: MapRange { range_start: 18446744073699065856, range_end: 18446744073699069952, offset: 0, dev: "00:00", flags: "r-xp", inode: 0, pathname: Some("[vsyscall]") } @ "[vsyscall]"
[2025-05-22 06:30:14:967611240][scheduler][56191][source.rs:2093][WARN] File of mapping not found: "[vsyscall]"
[2025-05-22 06:30:14:967792666][scheduler][56191][source.rs:943][INFO] patchpoint_type_frequency: {
Direct: 1924,
}
[2025-05-22 06:30:14:967910052][scheduler][56191][source.rs:955][INFO] target_value_size_freq in bits: {
2: 10,
8: 274,
3: 18,
128: 26,
1: 1064,
16: 18,
64: 157,
4: 19,
32: 331,
5: 7,
}
[2025-05-22 06:30:14:968028078][scheduler][56191][source.rs:967][INFO] patchpoint_instr_frequency: {
Store: 791,
InjectedCall: 77,
Select: 82,
Switch: 15,
Br: 959,
}
[2025-05-22 06:30:14:969454649][scheduler][56191][source.rs:881][INFO] Removing target values with loc_size > 8
[2025-05-22 06:30:14:972683348][scheduler][56191][source.rs:983][WARN] We lost 26 (1.35%) due to filtering...
[2025-05-22 06:30:14:972904000][scheduler][56191][source.rs:993][DEBUG] Found 1898 patch points in total
[2025-05-22 06:30:14:974381952][scheduler][56191][init.rs:170][INFO] Importing Input { sha256_digest: "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855", origin_path: Some("/home/user/fuzztruction/fuzztruction-experiments/comparison-with-state-of-the-art/configurations/networked/no-inputs/empty"), .. } into queue...
[2025-05-22 06:30:17:015570357][scheduler][56191][init.rs:195][INFO] Import result: Err(
SourceExecutionFailed(
TimedOut { .. },
),
)
[2025-05-22 06:30:17:015644916][scheduler][56191][init.rs:205][WARN] Failed to import input seeds file: Error while executing the source target TimedOut { .. }
[2025-05-22 06:30:17:015894774][scheduler][56191][source.rs:1128][DEBUG] Stopping source.
[2025-05-22 06:30:17:015937610][scheduler][56191][source.rs:2011][DEBUG] Sending SIGTERM to source 56204
[2025-05-22 06:30:17:015983581][scheduler][56191][source.rs:2018][ERROR] Source forkserver did not terminate after sending SIGTERM: Error while calling pidfd_open: Err(ENOSYS). Sending SIGKILL.
[2025-05-22 06:30:17:016020497][scheduler][56191][source.rs:2025][ERROR] Sending SIGKILL should cause the forkserver to terminate
[2025-05-22 06:30:17:016101909][scheduler][56191][sink.rs:745][INFO] Terminating sink forkserver
[2025-05-22 06:30:17:016151579][scheduler][56191][sink.rs:759][ERROR] Sink forkser ignored SIGTERM: Error while calling pidfd_open: Err(ENOSYS)
[2025-05-22 06:30:17:016188232][scheduler][56191][sink.rs:765][ERROR] Failed to terminated sink forkserver: Error while calling pidfd_open: Err(ENOSYS)
[2025-05-22 06:30:17:016391001][scheduler][56187][worker.rs:404][ERROR] child_error=Ok(
Err(
Error {
context: "Error while initializing the queue",
source: "Import of all import seeds failed",
},
),
)
[2025-05-22 06:30:17:016500708][scheduler][56187][worker.rs:411][ERROR] Timeout! Worker WorkerUid(0) failed to initialize! e=Disconnected
[2025-05-22 06:30:17:016583934][scheduler][56187][logging.rs:78][ERROR]
Panic: PanicInfo {
payload: Any { .. },
message: Some(
called `Result::unwrap()` on an `Err` value: Timeout! Worker WorkerUid(0) failed to initialize! e=Disconnected,
),
location: Location {
file: "scheduler/src/cli/handler.rs",
line: 66,
col: 29,
},
can_unwind: true,
force_no_backtrace: false,
}
[2025-05-22 06:30:17:016670016][scheduler][56187][logging.rs:82][ERROR] Location: scheduler/src/cli/handler.rs:66
Aborted
I'm guessing I would need to handle graceful exits on either the source/sink code (?).
It'd be great if you can give me hints on what I need to do :)
Thanks!
Metadata
Metadata
Assignees
Labels
No labels