To evaluate HAFuzz's seed selection and generation efficacy, we conducted a comparative experiment analyzing three strategies: random seed generation (HAFuzz-R), LTLFuzzer's seed selection (LTLFuzzer), and our novel distance-based selection approach (HAFuzz-D). This evaluation incorporates specially crafted scenarios that simulate sophisticated device status dynamics and environmental interactions.
Illustrative Example
Rules:
IF Air Quality Monitor.carbonDioxide > 60 & Weather.weather != rainy THEN Window.open
IF Clock.time = 20 THEN Door.lock
IF Door.LockState = unlocked THEN Camera.take photo
IF Temperature Sensor.temperature < 46 & Home Mode.Mode = away THEN Air Conditioner.off
IF Temperature Sensor.temperature > 50 THEN Air Conditioner.cool
IF Weather.weather = windy THEN Sina Weibo.post
IF Air Quality Monitor.airQuality > 60 THEN Alarm.siren
IF Alarm.AlertState = off & Illuminance Sensor.illuminance < 60 THEN Light.on
Specification:
G ( Air Conditioner.HvacMode = auto -> X G ( Air Conditioner.HvacMode = off -> ! ( X F ( Temperature Sensor.temperature >= 55 ) ) ) )
This scenario demonstrates a particularly challenging specification where intricate rule interdependencies and multi-clause temporal constraints create significant violation barriers. Successful violation requires precise temperature modulation: initial values must remain below 46 followed by subsequent escalation to 55. Experimental validation through 20 iterative runs yielded the following comparison results:
HAFuzz-R
Execution times (in milliseconds):
Run 1: 75308 ms
Run 2: 16095 ms
Run 3: 17015 ms
Run 4: 18476 ms
Run 5: 34303 ms
Run 6: 21501 ms
Run 7: 23988 ms
Run 8: 10317 ms
Run 9: 64423 ms
Run 10: 16374 ms
Run 11: 27310 ms
Run 12: 12844 ms
Run 13: 18432 ms
Run 14: 21206 ms
Run 15: 3531 ms
Run 16: 39998 ms
Run 17: 75413 ms
Run 18: 64267 ms
Run 19: 28404 ms
Run 20: 14102 ms
Average execution time: 30165 ms
LTLFuzzer
Execution times (in milliseconds):
Run 1: 467 ms
Run 2: 1013 ms
Run 3: 1098 ms
Run 4: 3550 ms
Run 5: 96391 ms
Run 6: 2950 ms
Run 7: 3176 ms
Run 8: 4044 ms
Run 9: 1242 ms
Run 10: 4847 ms
Run 11: 13995 ms
Run 12: 10818 ms
Run 13: 9782 ms
Run 14: 2914 ms
Run 15: 26256 ms
Run 16: 1649 ms
Run 17: 7427 ms
Run 18: 6223 ms
Run 19: 1024 ms
Run 20: 31542 ms
Average execution time: 11520 ms
HAFuzz-D
Execution times (in milliseconds):
Run 1: 90 ms
Run 2: 238 ms
Run 3: 690 ms
Run 4: 875 ms
Run 5: 3033 ms
Run 6: 530 ms
Run 7: 2784 ms
Run 8: 1100 ms
Run 9: 1069 ms
Run 10: 2549 ms
Run 11: 109 ms
Run 12: 309 ms
Run 13: 206 ms
Run 14: 5089 ms
Run 15: 491 ms
Run 16: 208 ms
Run 17: 107 ms
Run 18: 306 ms
Run 19: 2102 ms
Run 20: 546 ms
Average execution time: 1121 ms
Comprehensive results are presented in Table 4 (330-sample averages) and Figure 8 (visualized comparisons) of the paper.