Coverage Report

Created: 2026-09-14 06:31

next uncovered line (L), next uncovered region (R), next uncovered branch (B)
/src/FreeRDP/libfreerdp/utils/test/TestFuzzSmartcardOperations.c
Line
Count
Source
1
#include <winpr/stream.h>
2
#include <freerdp/channels/scard.h>
3
#include <freerdp/utils/smartcard_operations.h>
4
5
int LLVMFuzzerTestOneInput(const uint8_t* Data, size_t Size)
6
2.66k
{
7
2.66k
  SMARTCARD_OPERATION operation = WINPR_C_ARRAY_INIT;
8
2.66k
  wStream sbuffer = WINPR_C_ARRAY_INIT;
9
10
2.66k
  wStream* s = Stream_StaticConstInit(&sbuffer, Data, Size);
11
2.66k
  if (!s)
12
0
    return 0;
13
14
  /* Decodes the Device Control Request header, then dispatches on the
15
   * IoControlCode into the matching smartcard_unpack_*_call(). */
16
2.66k
  (void)smartcard_irp_device_control_decode_request(s, 1, 0, &operation);
17
2.66k
  smartcard_operation_free(&operation, FALSE);
18
19
2.66k
  return 0;
20
2.66k
}