mirror of
https://github.com/bettercap/bettercap
synced 2025-08-19 13:09:49 -07:00
new: api.rest now exposes polled_at time field for the object session
This commit is contained in:
parent
7d46e7aa7a
commit
529a1b48d9
1 changed files with 2 additions and 0 deletions
|
@ -51,6 +51,7 @@ type sessionJSON struct {
|
||||||
HID *network.HID `json:"hid"`
|
HID *network.HID `json:"hid"`
|
||||||
Queue *packets.Queue `json:"packets"`
|
Queue *packets.Queue `json:"packets"`
|
||||||
StartedAt time.Time `json:"started_at"`
|
StartedAt time.Time `json:"started_at"`
|
||||||
|
PolledAt time.Time `json:"polled_at"`
|
||||||
Active bool `json:"active"`
|
Active bool `json:"active"`
|
||||||
GPS GPS `json:"gps"`
|
GPS GPS `json:"gps"`
|
||||||
Modules ModuleList `json:"modules"`
|
Modules ModuleList `json:"modules"`
|
||||||
|
@ -74,6 +75,7 @@ func (s *Session) MarshalJSON() ([]byte, error) {
|
||||||
HID: s.HID,
|
HID: s.HID,
|
||||||
Queue: s.Queue,
|
Queue: s.Queue,
|
||||||
StartedAt: s.StartedAt,
|
StartedAt: s.StartedAt,
|
||||||
|
PolledAt: time.Now(),
|
||||||
Active: s.Active,
|
Active: s.Active,
|
||||||
GPS: s.GPS,
|
GPS: s.GPS,
|
||||||
Modules: s.Modules,
|
Modules: s.Modules,
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue