Skip to content

[Fuzzing] [adamsitnik] [NRBF] Fix bugs discovered by the fuzzer #627

@MihuBot

Description

@MihuBot

Job completed in 36 minutes 28 seconds.
dotnet/runtime#107368

// NrbfDecoderFuzzer
System.InvalidCastException: Unable to cast object of type 'System.Formats.Nrbf.SystemClassWithMembersAndTypesRecord' to type 'System.Formats.Nrbf.SerializedStreamHeaderRecord'.
   at System.Formats.Nrbf.NrbfDecoder.Decode(BinaryReader reader, PayloadOptions options, IReadOnlyDictionary`2& readOnlyRecordMap)
   at System.Formats.Nrbf.NrbfDecoder.Decode(Stream payload, IReadOnlyDictionary`2& recordMap, PayloadOptions options, Boolean leaveOpen)
   at System.Formats.Nrbf.NrbfDecoder.Decode(Stream payload, PayloadOptions options, Boolean leaveOpen)
   at DotnetFuzzing.Fuzzers.NrbfDecoderFuzzer.FuzzTarget(ReadOnlySpan`1 bytes) in D:\a\runtime-utils\runtime-utils\Runner\runtime\src\libraries\Fuzzing\DotnetFuzzing\Fuzzers\NrbfDecoderFuzzer.cs:line 94
   at DotnetFuzzing.Program.<>c__DisplayClass1_0.<RunFuzzer>b__0(ReadOnlySpan`1 bytes) in D:\a\runtime-utils\runtime-utils\Runner\runtime\src\libraries\Fuzzing\DotnetFuzzing\Program.cs:line 91
   at SharpFuzz.Fuzzer.LibFuzzer.Run(ReadOnlySpanAction action, Boolean ignoreExceptions)
==6968== ERROR: libFuzzer: deadly signal
NOTE: libFuzzer has rudimentary signal handlers.
      Combine libFuzzer with AddressSanitizer or similar for better crash reports.
SUMMARY: libFuzzer: deadly signal
MS: 3 ChangeBinInt-CopyPart-PersAutoDict- DE: "\377\377\377\377"-; base unit: 2c8961024dcdbe30195b1c293ff3526580f4bf98
0x60,0xff,0xff,0xff,0x0,0x2,0x0,0x79,0xff,0xff,0xff,0xff,0xff,0xff,
`\377\377\377\000\002\000y\377\377\377\377\377\377
artifact_prefix='./'; Test unit written to NrbfDecoderFuzzer-artifact-3
Base64: YP///wACAHn///////8=

Artifacts:

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions