MCPcopy Create free account
hub / github.com/BruceDevices/firmware / executeAttackWithTargetScan

Function executeAttackWithTargetScan

src/modules/ble/BLE_Suite.cpp:4055–4082  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

4053}
4054
4055void executeAttackWithTargetScan(int attackIndex) {
4056 String targetInfo = selectTargetFromScan(getScanTitle(attackIndex));
4057 if (targetInfo.isEmpty()) return;
4058
4059 NimBLEAddress target = parseAddress(targetInfo);
4060 if (!confirmAttack(target.toString().c_str())) return;
4061
4062 AutoCleanup cleanup([]() { BLEStateManager::deinitBLE(true); });
4063
4064 switch (attackIndex) {
4065 case 0: runQuickTest(target); break;
4066 case 1: runDeviceProfiling(target); break;
4067 case 2: showFastPairSubMenu(target); break;
4068 case 3: showHFPSubMenu(target); break;
4069 case 4: showAudioSubMenu(target); break;
4070 case 5: showHIDSubMenu(target); break;
4071 case 6: showMemorySubMenu(target); break;
4072 case 7: showDoSSubMenu(target); break;
4073 case 8: showPayloadSubMenu(target); break;
4074 case 9: showTestingSubMenu(target); break;
4075 case 10: runUniversalAttack(target); break;
4076 }
4077
4078 cleanup.disable();
4079
4080 showAttackProgress("Attack complete. Press any key to continue...", TFT_GREEN);
4081 while (!check(EscPress) && !check(SelPress) && !check(PrevPress) && !check(NextPress)) delay(50);
4082}
4083
4084//=============================================================================
4085// Submenu Display - with text wrapping for long options

Callers 1

BleSuiteMenuFunction · 0.85

Calls 15

selectTargetFromScanFunction · 0.85
getScanTitleFunction · 0.85
parseAddressFunction · 0.85
confirmAttackFunction · 0.85
runQuickTestFunction · 0.85
runDeviceProfilingFunction · 0.85
showFastPairSubMenuFunction · 0.85
showHFPSubMenuFunction · 0.85
showAudioSubMenuFunction · 0.85
showHIDSubMenuFunction · 0.85
showMemorySubMenuFunction · 0.85
showDoSSubMenuFunction · 0.85

Tested by

no test coverage detected