/drivers/peripheral/wlan/test/fuzztest/ |
D | wlan_common_fuzzer.cpp | 57 bool PreProcessRawData(const uint8_t *rawData, size_t size, uint8_t *tmpRawData, size_t tmpRawDataS… in PreProcessRawData() argument 59 if (rawData == nullptr || tmpRawData == nullptr) { in PreProcessRawData() 64 if (memcpy_s(tmpRawData, tmpRawDataSize, rawData + OFFSET, dataSize) != EOK) { in PreProcessRawData() 75 void FuzzGetChipId(struct IWlanInterface *interface, const uint8_t *rawData) in FuzzGetChipId() argument 79 feature.ifName = const_cast<char *>(reinterpret_cast<const char *>(rawData)); in FuzzGetChipId() 80 feature.type = *const_cast<int32_t *>(reinterpret_cast<const int32_t *>(rawData)); in FuzzGetChipId() 86 void FuzzGetDeviceMacAddress(struct IWlanInterface *interface, const uint8_t *rawData) in FuzzGetDeviceMacAddress() argument 91 feature.ifName = const_cast<char *>(reinterpret_cast<const char *>(rawData)); in FuzzGetDeviceMacAddress() 92 feature.type = *const_cast<int32_t *>(reinterpret_cast<const int32_t *>(rawData)); in FuzzGetDeviceMacAddress() 95 *const_cast<uint8_t *>(reinterpret_cast<const uint8_t *>(rawData))); in FuzzGetDeviceMacAddress() [all …]
|
D | wlan_common_fuzzer.h | 33 bool PreProcessRawData(const uint8_t *rawData, size_t size, uint8_t *tmpRawData, size_t tmpRawDataS… 34 void FuzzGetChipId(struct IWlanInterface *interface, const uint8_t *rawData); 35 void FuzzGetDeviceMacAddress(struct IWlanInterface *interface, const uint8_t *rawData); 36 void FuzzGetFeatureType(struct IWlanInterface *interface, const uint8_t *rawData); 37 void FuzzGetFreqsWithBand(struct IWlanInterface *interface, const uint8_t *rawData); 38 void FuzzGetNetworkIfaceName(struct IWlanInterface *interface, const uint8_t *rawData); 39 void FuzzSetMacAddress(struct IWlanInterface *interface, const uint8_t *rawData); 40 void FuzzSetTxPower(struct IWlanInterface *interface, const uint8_t *rawData); 41 void FuzzGetPowerMode(struct IWlanInterface *interface, const uint8_t *rawData); 42 void FuzzSetPowerMode(struct IWlanInterface *interface, const uint8_t *rawData); [all …]
|
/drivers/peripheral/codec/test/fuzztest/omx_fuzzer/codeccomponenttunnelrequestomx_fuzzer/ |
D | codeccomponenttunnelrequest_fuzzer.cpp | 39 uint8_t *rawData = const_cast<uint8_t *>(data); in CodecComponentTunnelRequest() local 41 params.port = Convert2Uint32(rawData); in CodecComponentTunnelRequest() 42 rawData = rawData + sizeof(uint32_t); in CodecComponentTunnelRequest() 43 params.tunneledComp = static_cast<int32_t>(Convert2Uint32(rawData)); in CodecComponentTunnelRequest() 44 rawData = rawData + sizeof(int32_t); in CodecComponentTunnelRequest() 45 params.tunneledPort = Convert2Uint32(rawData); in CodecComponentTunnelRequest() 46 rawData = rawData + sizeof(uint32_t); in CodecComponentTunnelRequest() 47 params.tunnelSetup = reinterpret_cast<OMX_TUNNELSETUPTYPE *>(rawData); in CodecComponentTunnelRequest() 49 params.tunneledComp = static_cast<int32_t>(Convert2Uint32(rawData)); in CodecComponentTunnelRequest() 50 params.port = Convert2Uint32(rawData); in CodecComponentTunnelRequest() [all …]
|
/drivers/peripheral/audio/test/fuzztest/audio_hdi_fuzzer/audioadapter_fuzzer/ |
D | audioadapter_fuzzer.cpp | 46 static void AdapterFucSwitch(struct IAudioAdapter *&adapter, uint32_t cmd, const uint8_t *&rawData) in AdapterFucSwitch() argument 48 uint8_t *data = const_cast<uint8_t *>(rawData); in AdapterFucSwitch() 52 … adapter->CreateRender(adapter, reinterpret_cast<const struct AudioDeviceDescriptor *>(rawData), in AdapterFucSwitch() 53 reinterpret_cast<const struct AudioSampleAttributes *>(rawData), in AdapterFucSwitch() 63 … adapter->CreateCapture(adapter, reinterpret_cast<const struct AudioDeviceDescriptor *>(rawData), in AdapterFucSwitch() 64 reinterpret_cast<const struct AudioSampleAttributes *>(rawData), in AdapterFucSwitch() 74 …adapter->GetPortCapability(adapter, reinterpret_cast<const struct AudioPort *>(rawData), &capabili… in AdapterFucSwitch() 83 …SetPassthroughMode(adapter, &port, *(reinterpret_cast<const AudioPortPassthroughMode *>(rawData))); in AdapterFucSwitch() 101 bool DoSomethingInterestingWithMyAPI(const uint8_t *rawData, size_t size) in DoSomethingInterestingWithMyAPI() argument 103 if (rawData == nullptr) { in DoSomethingInterestingWithMyAPI() [all …]
|
/drivers/peripheral/codec/test/fuzztest/omx_fuzzer/codecsendcommandomx_fuzzer/ |
D | codecsendcommand_fuzzer.cpp | 39 uint8_t *rawData = const_cast<uint8_t *>(data); in CodecSendCommand() local 40 params.param = Convert2Uint32(rawData); in CodecSendCommand() 42 rawData = rawData + sizeof(uint32_t); in CodecSendCommand() 44 params.cmdData = reinterpret_cast<int8_t *>(rawData); in CodecSendCommand() 46 rawData = rawData + sizeof(int8_t *); in CodecSendCommand() 47 params.cmd = static_cast<OMX_COMMANDTYPE>(*rawData); in CodecSendCommand() 49 params.cmdData = reinterpret_cast<int8_t *>(rawData); in CodecSendCommand() 51 params.cmd = static_cast<OMX_COMMANDTYPE>(*rawData); in CodecSendCommand()
|
/drivers/peripheral/camera/test/fuzztest/camera_host/ |
D | camera_host_fuzzer.cpp | 51 static void HostFuncSwitch(uint32_t cmd, const uint8_t *&rawData) in HostFuncSwitch() argument 55 …est->serviceV1_1->Prelaunch(reinterpret_cast<const HDI::Camera::V1_1::PrelaunchConfig &>(rawData)); in HostFuncSwitch() 60 … std::string *data = const_cast<std::string *>(reinterpret_cast<const std::string *>(rawData)); in HostFuncSwitch() 67 uint8_t *data = const_cast<uint8_t *>(rawData); in HostFuncSwitch() 69 …raTest->serviceV1_1->GetCameraAbility(*reinterpret_cast<const std::string *>(rawData), abilityVec); in HostFuncSwitch() 76 reinterpret_cast<const HDI::Camera::V1_0::ICameraDeviceCallback *>(rawData)); in HostFuncSwitch() 79 *reinterpret_cast<const std::string *>(rawData), callback, g_CameraDevice); in HostFuncSwitch() 86 reinterpret_cast<const HDI::Camera::V1_0::ICameraDeviceCallback *>(rawData)); in HostFuncSwitch() 88 *reinterpret_cast<const std::string *>(rawData), callback, g_CameraDevice); in HostFuncSwitch() 92 … cameraTest->serviceV1_1->SetFlashlight(*reinterpret_cast<const std::string *>(rawData), true); in HostFuncSwitch() [all …]
|
/drivers/peripheral/audio/test/fuzztest/audio_hdi_fuzzer/audiorender_fuzzer/ |
D | audiorender_fuzzer.cpp | 64 void RenderFucSwitch(struct IAudioRender *&render, uint32_t cmd, const uint8_t *&rawData, size_t si… in RenderFucSwitch() argument 66 uint8_t *data = const_cast<uint8_t *>(rawData); in RenderFucSwitch() 69 …nder->SetSampleAttributes(render, reinterpret_cast<const struct AudioSampleAttributes *>(rawData)); in RenderFucSwitch() 73 …ender->CheckSceneCapability(render, reinterpret_cast<const struct AudioSceneDescriptor *>(rawData), in RenderFucSwitch() 78 … render->SelectScene(render, reinterpret_cast<const struct AudioSceneDescriptor *>(rawData)); in RenderFucSwitch() 88 … render->RenderFrame(render, reinterpret_cast<const int8_t *>(rawData), size, &replyBytes); in RenderFucSwitch() 92 render->SetExtraParams(render, reinterpret_cast<const char *>(rawData)); in RenderFucSwitch() 111 bool DoSomethingInterestingWithMyAPI(const uint8_t *rawData, size_t size) in DoSomethingInterestingWithMyAPI() argument 113 if (rawData == nullptr) { in DoSomethingInterestingWithMyAPI() 118 uint32_t cmd = Convert2Uint32(rawData); in DoSomethingInterestingWithMyAPI() [all …]
|
/drivers/peripheral/camera/test/fuzztest/camera_device/ |
D | camera_device_fuzzer.cpp | 54 static void DeviceFuncSwitch(uint32_t cmd, const uint8_t *&rawData) in DeviceFuncSwitch() argument 60 uint8_t *data = const_cast<uint8_t *>(rawData); in DeviceFuncSwitch() 69 reinterpret_cast<const HDI::Camera::V1_0::IStreamOperatorCallback *>(rawData)); in DeviceFuncSwitch() 78 reinterpret_cast<const HDI::Camera::V1_0::IStreamOperatorCallback *>(rawData)); in DeviceFuncSwitch() 85 uint8_t *data = const_cast<uint8_t *>(rawData); in DeviceFuncSwitch() 92 *reinterpret_cast<const HDI::Camera::V1_0::ResultCallbackMode *>(rawData)); in DeviceFuncSwitch() 97 int32_t *data = const_cast<int32_t *>(reinterpret_cast<const int32_t *>(rawData)); in DeviceFuncSwitch() 104 int32_t *data = const_cast<int32_t *>(reinterpret_cast<const int32_t *>(rawData)); in DeviceFuncSwitch() 111 int32_t *data = const_cast<int32_t *>(reinterpret_cast<const int32_t *>(rawData)); in DeviceFuncSwitch() 123 bool DoSomethingInterestingWithMyApi(const uint8_t *rawData, size_t size) in DoSomethingInterestingWithMyApi() argument [all …]
|
/drivers/peripheral/audio/test/fuzztest/audio_hdi_fuzzer/audiocapture_fuzzer/ |
D | audiocapture_fuzzer.cpp | 63 void CaptureFucSwitch(struct IAudioCapture *&capture, uint32_t cmd, const uint8_t *&rawData) in CaptureFucSwitch() argument 65 uint8_t *data = const_cast<uint8_t *>(rawData); in CaptureFucSwitch() 68 …ure->SetSampleAttributes(capture, reinterpret_cast<const struct AudioSampleAttributes *>(rawData)); in CaptureFucSwitch() 72 …ture->CheckSceneCapability(capture, reinterpret_cast<const struct AudioSceneDescriptor *>(rawData), in CaptureFucSwitch() 77 … capture->SelectScene(capture, reinterpret_cast<const struct AudioSceneDescriptor *>(rawData)); in CaptureFucSwitch() 93 capture->SetExtraParams(capture, reinterpret_cast<const char *>(rawData)); in CaptureFucSwitch() 109 bool DoSomethingInterestingWithMyAPI(const uint8_t *rawData, size_t size) in DoSomethingInterestingWithMyAPI() argument 111 if (rawData == nullptr) { in DoSomethingInterestingWithMyAPI() 117 uint32_t cmd = Convert2Uint32(rawData); in DoSomethingInterestingWithMyAPI() 119 rawData = rawData + OFFSET; in DoSomethingInterestingWithMyAPI() [all …]
|
/drivers/peripheral/wlan/test/fuzztest/ap_fuzzer/ |
D | ap_fuzzer.cpp | 28 void FuzzGetAssociatedStas(struct IWlanInterface *interface, const uint8_t *rawData) in FuzzGetAssociatedStas() argument 33 feature.type = *const_cast<int32_t *>(reinterpret_cast<const int32_t *>(rawData)); in FuzzGetAssociatedStas() 34 feature.ifName = const_cast<char *>(reinterpret_cast<const char *>(rawData)); in FuzzGetAssociatedStas() 40 void FuzzSetCountryCode(struct IWlanInterface *interface, const uint8_t *rawData) in FuzzSetCountryCode() argument 42 const char *mac = reinterpret_cast<const char *>(rawData); in FuzzSetCountryCode() 43 uint32_t macLen = *const_cast<int32_t *>(reinterpret_cast<const int32_t *>(rawData)); in FuzzSetCountryCode() 45 feature.ifName = const_cast<char *>(reinterpret_cast<const char *>(rawData)); in FuzzSetCountryCode() 46 feature.type = *const_cast<uint32_t *>(reinterpret_cast<const uint32_t *>(rawData)); in FuzzSetCountryCode() 83 bool DoSomethingInterestingWithMyAPI(const uint8_t *rawData, size_t size) in DoSomethingInterestingWithMyAPI() argument 88 if (rawData == nullptr || size == 0) { in DoSomethingInterestingWithMyAPI() [all …]
|
/drivers/peripheral/camera/test/fuzztest/stream_operator/ |
D | stream_operator_fuzzer.cpp | 20 bool CameraStreamOperatorFuzzTest(const uint8_t *rawData, size_t size) in CameraStreamOperatorFuzzTest() argument 22 if (rawData == nullptr) { in CameraStreamOperatorFuzzTest() 26 uint32_t code = U32_AT(rawData); in CameraStreamOperatorFuzzTest() 27 rawData = rawData + OFFSET; in CameraStreamOperatorFuzzTest() 32 data.WriteBuffer(rawData, size); in CameraStreamOperatorFuzzTest()
|
/drivers/peripheral/camera/test/fuzztest/offline_stream_operator/ |
D | offline_stream_operator_fuzzer.cpp | 20 bool CameraOfflineStreamOperatorFuzzTest(const uint8_t *rawData, size_t size) in CameraOfflineStreamOperatorFuzzTest() argument 22 if (rawData == nullptr) { in CameraOfflineStreamOperatorFuzzTest() 26 uint32_t code = U32_AT(rawData); in CameraOfflineStreamOperatorFuzzTest() 27 rawData = rawData + OFFSET; in CameraOfflineStreamOperatorFuzzTest() 32 data.WriteBuffer(rawData, size); in CameraOfflineStreamOperatorFuzzTest()
|
/drivers/peripheral/wlan/test/fuzztest/sta_fuzzer/ |
D | sta_fuzzer.cpp | 25 static void FuzzStartScan(struct IWlanInterface *interface, const uint8_t *rawData) in FuzzStartScan() argument 29 feature.ifName = const_cast<char *>(reinterpret_cast<const char *>(rawData)); in FuzzStartScan() 30 feature.type = *const_cast<int32_t *>(reinterpret_cast<const int32_t *>(rawData)); in FuzzStartScan() 36 static void FuzzSetScanningMacAddress(struct IWlanInterface *interface, const uint8_t *rawData) in FuzzSetScanningMacAddress() argument 39 feature.ifName = const_cast<char *>(reinterpret_cast<const char *>(rawData)); in FuzzSetScanningMacAddress() 40 feature.type = *const_cast<int32_t *>(reinterpret_cast<const int32_t *>(rawData)); in FuzzSetScanningMacAddress() 41 const uint8_t *scanMac = rawData; in FuzzSetScanningMacAddress() 83 bool DoSomethingInterestingWithMyAPI(const uint8_t *rawData, size_t size) in DoSomethingInterestingWithMyAPI() argument 88 if (rawData == nullptr || size == 0) { in DoSomethingInterestingWithMyAPI() 91 …uint32_t cmdId = Convert2Uint32(rawData) % ((sizeof(g_fuzzWlanFuncs) / sizeof(g_fuzzWlanFuncs[0]))… in DoSomethingInterestingWithMyAPI() [all …]
|
/drivers/peripheral/audio/effect/test/fuzztest/effectmodel_fuzzer/ |
D | effectmodel_fuzzer.cpp | 51 void EffectModelFucSwitch(struct IEffectModel *&model, uint32_t cmd, const uint8_t *&rawData, size_… in EffectModelFucSwitch() argument 53 uint8_t *data = const_cast<uint8_t *>(rawData); in EffectModelFucSwitch() 95 bool DoSomethingInterestingWithMyAPI(const uint8_t *rawData, size_t size) in DoSomethingInterestingWithMyAPI() argument 97 if (rawData == nullptr) { in DoSomethingInterestingWithMyAPI() 100 uint32_t cmd = Convert2Uint32(rawData) % EFFECT_MODEL_GET_EFFECT_DESCRIPTOR; in DoSomethingInterestingWithMyAPI() 101 rawData = rawData + OFFSET; in DoSomethingInterestingWithMyAPI() 108 EffectModelFucSwitch(model, cmd, rawData, size); in DoSomethingInterestingWithMyAPI()
|
/drivers/peripheral/codec/test/fuzztest/omx_fuzzer/codecgetconfigomx_fuzzer/ |
D | codecgetconfig_fuzzer.cpp | 38 uint8_t *rawData = const_cast<uint8_t *>(data); in CodecGetConfig() local 39 params.index = Convert2Uint32(rawData); in CodecGetConfig() 41 rawData = rawData + sizeof(uint32_t); in CodecGetConfig() 43 params.cfgStruct = reinterpret_cast<int8_t *>(rawData); in CodecGetConfig() 46 params.cfgStruct = reinterpret_cast<int8_t *>(rawData); in CodecGetConfig()
|
/drivers/peripheral/codec/test/fuzztest/omx_fuzzer/codecgetparameteromx_fuzzer/ |
D | codecgetparameter_fuzzer.cpp | 38 uint8_t *rawData = const_cast<uint8_t *>(data); in CodecGetParameter() local 39 params.paramIndex = Convert2Uint32(rawData); in CodecGetParameter() 41 rawData = rawData + sizeof(uint32_t); in CodecGetParameter() 43 params.paramStruct = reinterpret_cast<int8_t *>(rawData); in CodecGetParameter() 46 params.paramStruct = reinterpret_cast<int8_t *>(rawData); in CodecGetParameter()
|
/drivers/peripheral/codec/test/fuzztest/omx_fuzzer/codecsetconfigomx_fuzzer/ |
D | codecsetconfig_fuzzer.cpp | 38 uint8_t *rawData = const_cast<uint8_t *>(data); in CodecSetConfig() local 39 params.index = Convert2Uint32(rawData); in CodecSetConfig() 41 rawData = rawData + sizeof(uint32_t); in CodecSetConfig() 43 params.cfgStruct = reinterpret_cast<int8_t *>(rawData); in CodecSetConfig() 46 params.cfgStruct = reinterpret_cast<int8_t *>(rawData); in CodecSetConfig()
|
/drivers/peripheral/codec/test/fuzztest/omx_fuzzer/codecsetparameteromx_fuzzer/ |
D | codecsetparameter_fuzzer.cpp | 39 uint8_t *rawData = const_cast<uint8_t *>(data); in CodecSetParameter() local 40 params.index = Convert2Uint32(rawData); in CodecSetParameter() 42 rawData = rawData + sizeof(uint32_t); in CodecSetParameter() 44 params.paramStruct = reinterpret_cast<int8_t *>(rawData); in CodecSetParameter() 47 params.paramStruct = reinterpret_cast<int8_t *>(rawData); in CodecSetParameter()
|
/drivers/peripheral/codec/test/fuzztest/hdi_fuzzer/codechdi_fuzzer/ |
D | codec_fuzzer.cpp | 41 bool DoSomethingInterestingWithMyAPI(const uint8_t* rawData, size_t size) in DoSomethingInterestingWithMyAPI() argument 43 if (rawData == nullptr) { in DoSomethingInterestingWithMyAPI() 46 uint32_t code = Convert2Uint32(rawData); in DoSomethingInterestingWithMyAPI() 47 rawData = rawData + OFFSET; in DoSomethingInterestingWithMyAPI() 52 data.WriteBuffer(rawData, size); in DoSomethingInterestingWithMyAPI()
|
/drivers/peripheral/vibrator/test/fuzztest/vibrator_fuzzer/ |
D | vibrator_fuzzer.cpp | 41 bool DoSomethingInterestingWithMyAPI(const uint8_t* rawData, size_t size) in DoSomethingInterestingWithMyAPI() argument 43 if (rawData == nullptr) { in DoSomethingInterestingWithMyAPI() 46 uint32_t code = Convert2Uint32(rawData); in DoSomethingInterestingWithMyAPI() 47 rawData = rawData + OFFSET; in DoSomethingInterestingWithMyAPI() 52 data.WriteBuffer(rawData, size); in DoSomethingInterestingWithMyAPI()
|
/drivers/peripheral/usb/test/fuzztest/usbdevice_fuzzer/ |
D | usbdevice_fuzzer.cpp | 44 bool DoSomethingInterestingWithMyAPI(const uint8_t *rawData, size_t size) in DoSomethingInterestingWithMyAPI() argument 46 if (rawData == nullptr) { in DoSomethingInterestingWithMyAPI() 49 uint32_t code = Convert2Uint32(rawData); in DoSomethingInterestingWithMyAPI() 50 rawData = rawData + OFFSET; in DoSomethingInterestingWithMyAPI() 55 data.WriteBuffer(rawData, size); in DoSomethingInterestingWithMyAPI()
|
/drivers/peripheral/light/test/fuzztest/light_fuzzer/ |
D | light_fuzzer.cpp | 41 bool DoSomethingInterestingWithMyAPI(const uint8_t* rawData, size_t size) in DoSomethingInterestingWithMyAPI() argument 43 if (rawData == nullptr) { in DoSomethingInterestingWithMyAPI() 46 uint32_t code = Convert2Uint32(rawData); in DoSomethingInterestingWithMyAPI() 47 rawData = rawData + OFFSET; in DoSomethingInterestingWithMyAPI() 52 data.WriteBuffer(rawData, size); in DoSomethingInterestingWithMyAPI()
|
/drivers/peripheral/sensor/test/fuzztest/sensor_fuzzer/ |
D | sensor_fuzzer.cpp | 41 bool DoSomethingInterestingWithMyAPI(const uint8_t* rawData, size_t size) in DoSomethingInterestingWithMyAPI() argument 43 if (rawData == nullptr) { in DoSomethingInterestingWithMyAPI() 46 uint32_t code = Convert2Uint32(rawData); in DoSomethingInterestingWithMyAPI() 47 rawData = rawData + OFFSET; in DoSomethingInterestingWithMyAPI() 52 data.WriteBuffer(rawData, size); in DoSomethingInterestingWithMyAPI()
|
/drivers/peripheral/input/test/fuzztest/input_fuzzer/ |
D | input_fuzzer.cpp | 41 bool DoSomethingInterestingWithMyAPI(const uint8_t* rawData, size_t size) in DoSomethingInterestingWithMyAPI() argument 43 if (rawData == nullptr) { in DoSomethingInterestingWithMyAPI() 46 uint32_t code = Convert2Uint32(rawData); in DoSomethingInterestingWithMyAPI() 47 rawData = rawData + OFFSET; in DoSomethingInterestingWithMyAPI() 52 data.WriteBuffer(rawData, size); in DoSomethingInterestingWithMyAPI()
|
/drivers/peripheral/audio/test/fuzztest/audio_hdi_fuzzer/audiomanager_fuzzer/ |
D | audiomanager_fuzzer.cpp | 39 bool DoSomethingInterestingWithMyAPI(const uint8_t *rawData, size_t size) in DoSomethingInterestingWithMyAPI() argument 41 if (rawData == nullptr) { in DoSomethingInterestingWithMyAPI() 44 uint32_t cmd = Convert2Uint32(rawData); in DoSomethingInterestingWithMyAPI() 45 rawData = rawData + OFFSET; in DoSomethingInterestingWithMyAPI() 50 uint8_t *data = const_cast<uint8_t *>(rawData); in DoSomethingInterestingWithMyAPI()
|