# RF SCYTHE Network Visualization

The RF SCYTHE system includes a network visualization component that allows you to monitor network traffic in real-time.

## Running the Server

To run the RF SCYTHE server, use one of the following methods:

### Standard Start

```bash
./manage_server.sh start
```

This will start the server and display the available interfaces:
- Main Web Interface: http://localhost:5000/
- Network Visualization: http://localhost:5000/network
- WebSocket Server: Ports 8765 (SDR) and 8766 (clients)

### Emergency Reset

If the server is having issues, you can use the emergency reset script to forcefully terminate all server processes and start fresh:

```bash
./emergency_reset.sh
```

## Network Infrastructure Visualization

The RF SCYTHE system now includes enhanced visualization of network infrastructure to help track FCC violators who jump between hardline and radio connections. This feature has been integrated into the Command Operations Center interface.

### Features

1. **Multi-Infrastructure Visualization**
   - Undersea Cables: View global submarine cable networks with detailed metadata
   - Satellites: Visualize satellite positions, orbits, and coverage areas
   - 5G/Cell Towers: Map terrestrial wireless infrastructure with signal coverage
   - Fiber Backbones: Display major fiber optic routes across continents

2. **Cross-Network FCC Violation Tracking**
   - Track violators who attempt to evade detection by jumping between network types
   - Visualize network paths of suspicious transmissions
   - Integrate with Gemini API for advanced network traffic analysis

3. **Interactive Controls**
   - Toggle visibility of different network infrastructure layers
   - Select network elements to view detailed information
   - Track violations across infrastructure types with visual indicators

### Usage

Access the network visualization through the Command Operations Center interface and use the NETWORK tab to interact with the visualization features.

## Network Traffic Capture and Analysis

The RF SCYTHE system now includes advanced network traffic capture and analysis capabilities, allowing you to monitor and visualize traffic patterns across different infrastructure types.

### Traffic Capture Features

1. **Real-time Packet Visualization**
   - View live packet flow between network infrastructure components
   - Detect unauthorized communications and FCC violations in real-time
   - Visualize traffic density and patterns across global infrastructure

2. **Gemini API Integration for Traffic Analysis**
   - AI-powered analysis of network traffic patterns
   - Detection of suspicious cross-infrastructure communications
   - Identification of potential FCC violations based on traffic characteristics
   - Classification of encryption and communication protocols

3. **Forensic Traffic Analysis**
   - Historical traffic pattern visualization
   - Detection of correlation between seemingly unrelated transmissions
   - Visualization of violator paths across different network types

### Using Network Traffic Capture

1. Navigate to the NETWORK tab in the Command Operations Center
2. Click the "Capture Traffic" button to start real-time traffic visualization
3. View the packet flow visualization in the 2D panel
4. After capture completes, review the Gemini API analysis results
5. Use the controls to follow violations across different infrastructure types

## Network Traffic Visualization Tips

- The 2D packet visualization shows different network types (cellular, satellite, undersea cables, fiber) in separate columns
- Red packets indicate potential violations or unauthorized communications
- Connection lines between columns show packets jumping between different infrastructure types
- Use the "Stop Capture" button to end the visualization and clear highlighted elements

## Troubleshooting

If you encounter issues with the network visualization:

1. Check that your browser supports WebGL and 3D canvas
2. Ensure Gemini API access is enabled (status indicator in header)
3. Try refreshing the browser if network elements fail to appear
4. Use the console to check for any JavaScript errors

1. Access the Command Operations Center: http://localhost:5000/command
2. Click on the "NETWORK" tab in the sidebar
3. Use the network infrastructure controls to:
   - Toggle visibility of undersea cables, satellites, cell towers, and fiber backbones
   - Scan for network infrastructure elements
   - Track FCC violators across network types
4. Click on any network element on the map to view detailed information

### Integration with Gemini API

The network visualization leverages Google's Gemini API to:
- Analyze signal characteristics to identify potential network infrastructure jumping
- Correlate transmissions across different infrastructure types
- Generate threat analysis for FCC violators using multiple network types
- Provide recommended actions for monitoring and enforcement

### Technical Details

The network infrastructure visualization uses:
- Cesium.js for 3D visualization of global infrastructure
- Custom entity highlighting for interactive engagement
- Real-time data updates via WebSocket connections
- Coordination with RF beamforming and voxel visualization modules
- Integrated coordinate validation to prevent rendering errors

### Future Enhancements

- Real-time data from satellite tracking APIs
- Integration with submarine cable outage databases
- Automatic correlation of FCC violations with network infrastructure patterns
- Machine learning prediction of violator network jumping patterns
