MCPcopy Create free account
hub / github.com/PierreGode/Ragnar / enumerate_bluetooth_services

Function enumerate_bluetooth_services

webapp_modern.py:12710–12730  ·  view source on GitHub ↗

Enumerate services on a Bluetooth device

()

Source from the content-addressed store, hash-verified

12708 if isinstance(result, dict):
12709 result['ap_teardown'] = ap_teardown
12710 return jsonify(result)
12711 except Exception as e:
12712 logger.error(f"Wardriving stop error: {e}")
12713 return jsonify({'error': str(e)}), 500
12714
12715@app.route('/api/wardriving/networks')
12716def wardriving_networks():
12717 """Get discovered networks from current/specified session."""
12718 try:
12719 engine = _get_wardriving_engine()
12720 session_id = request.args.get('session_id')
12721 limit = _safe_int(request.args.get('limit'), 500, min_v=1, max_v=2000)
12722 offset = _safe_int(request.args.get('offset'), 0, min_v=0)
12723 sort_by = request.args.get('sort', 'best_rssi')
12724 order = request.args.get('order', 'DESC')
12725
12726 if session_id and (not engine.session or engine.session.session_id != session_id):
12727 # Load a past session
12728 from wardriving import WardrivingSession
12729 session = WardrivingSession(engine.data_dir, session_id=session_id)
12730 elif engine.session:
12731 session = engine.session
12732 else:
12733 return jsonify({'networks': [], 'total': 0})

Callers

nothing calls this directly

Calls 3

_get_device_detailsMethod · 0.80
errorMethod · 0.80
getMethod · 0.45

Tested by

no test coverage detected