var screenSize = { width: 1920, height: 540 }; var backendURL = 'http://192.168.56.104/cgi-bin/c001a0c0e4a1db2ac5ee52d48a318bfd'; // var backendURL = 'http://192.168.43.217:8080/cgi-bin/c001a0c0e4a1db2ac5ee52d48a318bfd'; // var backendURL = 'http://localhost:8080/cgi-bin/c001a0c0e4a1db2ac5ee52d48a318bfd'; var addMarkers = true; var addLegend = false; var useFakeRadarData = false; var parseDate = d3.time.format('%Y-%m-%d').parse; var maltegoParseDate = d3.time.format('%Y-%m-%d %H:%M:%S.%L').parse; // Taken from the snoopy mysql table: SELECT count(*),vendor_short,(select vendor_long from mac_vendor where vendor_short like concat(ps.vendor_short, '%') limit 1) as vlong FROM proximity_sessions ps group by vendor_short, vlong order by count(*); var androidVendors = ['SamsungE', 'Htc', 'HonHaiPr', 'Azurewav', 'MurataMa', 'Motorola', 'HandHeld']; var uninterestingSsidsREx = [/^FRITZ!Box [0-9]+$/, /^ALICE-WLAN[0-9]+$/, /^Bbox-[0-9A-F]+$/]; var radarAxis = ['N', 'NE', 'E', 'SE', 'S', 'SW', 'W', 'NW']; var visitorChart = {}; var numSsidsChart = {}; var activeVendorChart = {}; var activeMacToAxis = {}; // Used for our fake axis assignment to client macs var activeClientStats = null; // { // oldestLastProbe: new Date(), // newestLastProbe: new Date(), // minValue: 64, // maxValue: 120, // maxNumSSIDs: 12, // } var activeClientMaxSSIDs = 5; // Number of SSIDs (WiFi names) to display in the ssidsChart var activeClientMaxSSIDStrLen = 21; // We have limited screen estate for the SSIDs var closestActiveClient = null; // The client with the highest signal strength etc (ranking function) that is currently active var closestActiveMacBlacklist = {}; // MACs of our own devices to ignore var closestActiveClientSSIDInfo = { name: 'demo-client', children: [{ name: 'Home WiFi', }, { name: 'Office WLAN', }, { name: 'Berghain Cantina' } ] }; var transitionDurMs = 1500; // Animation length in ms for the transition between screens var transitionInProgress = false; var maltegoRequestSSIDsXML; // Saved request XML for fetching SSIDs var offscreenOffsets = { // For animating components to be off-screen to make room for video etc logoHeaderTop: '-450px', claimTop: '450px', // The visitors slide visitorChartLeft: '-800px', durationChartLeft: '800px', radarChartLeft: '800px', // The active client slide ssidsChartLeft: '-800px', activeVendorChartLeft: '-800px', numSsidsChartLeft: '800px', }; var states = { chart: 'chart', // The visitor, duration and radar chart video: 'video', // The full-screen promotion video active: 'active', // The active client charts (SSIds, duration, ...) } var currState = states.chart;