Commit graph

22 commits

Author SHA1 Message Date
Giuseppe Trotta
ed652622e2 Refactoring modules 2019-02-10 23:58:08 +01:00
evilsocket
08f3766d30 new: new /api/session/modules route 2018-09-29 12:48:32 +02:00
evilsocket
8f7f6545b1 new: new api.rest.alloworigin parameter to customize the Access-Control-Allow-Origin header of the server. 2018-09-29 02:10:46 +02:00
evilsocket
0ada0fdf7b fix: fixed a json encoding issue that caused the api.rest controller to return an empty list of events when a net.sniff http event is triggered 2018-09-27 16:09:11 +02:00
evilsocket
7b7739358d fix: locking the session object when it's read by the api module (fixes #349) 2018-09-27 15:25:35 +02:00
evilsocket
e0906c0afb
fix: enabled CORS on the api.rest module in order to allow usage from other ports 2018-09-17 17:39:52 +02:00
evilsocket
f9656e1d1d
new: disabling api.rest authentication if username or password are empty 2018-08-29 16:00:17 +03:00
evilsocket
7919cda5ec
lint driven refactoring 2018-04-24 16:33:38 +02:00
evilsocket
d09eec3535
misc: small fix or general refactoring i did not bother commenting 2018-03-13 14:41:37 +01:00
evilsocket
cc01a99579
refact: refactored api.rest controller 2018-03-13 13:57:52 +01:00
KhasMek
4b8d4aeb1b api: switch request router and add more paths
This switches the url router to gorilla and
  adds the following routes.

  - /api/events
  - /api/session
  - /api/session/ble
  - /api/session/ble/{mac}
  - /api/session/env
  - /api/session/gateway
  - /api/session/interface
  - /api/session/lan
  - /api/session/lan/{mac}
  - /api/session/options
  - /api/session/packets
  - /api/session/started-at
  - /api/session/wifi
  - /api/session/wifi/{mac}

  where {mac} is the mac address of a device.
2018-03-12 18:42:32 -06:00
evilsocket
5e6741d544
fix: /api/events n parameter did not work as expected (fixes #158) 2018-03-07 18:39:31 +01:00
evilsocket
5ad1a17118 new: implemented optional websocket for /api/events 2018-03-06 13:54:37 +01:00
evilsocket
b243e67828 some progress but still doesn't work 2018-03-01 19:30:10 +01:00
evilsocket
894cbe76a1 refact: refactored api.rest to avoid using global variables 2018-03-01 18:06:42 +01:00
evilsocket
63cea73f8e misc: small fix or general refactoring i did not bother commenting 2018-02-23 00:07:09 +01:00
evilsocket
1728ed63f1 refact: we got rid of huge GIN dependency by using core golang libs for api.rest module 2018-02-22 16:59:23 +01:00
evilsocket
bec98e3d1f misc: small fix or general refactoring i did not bother commenting 2018-02-22 15:43:32 +01:00
evilsocket
5d3381fc76 fix: make sure events are sorted 2018-01-29 14:20:24 +01:00
evilsocket
4f1c508a7c refact: refactored api.rest utility functions into separate file. 2018-01-17 17:04:15 +01:00
evilsocket
d14bd6fc1c balls 2018-01-14 15:13:43 +01:00
evilsocket
fd18dffd1a refact: refactored api.rest module to use GIN and have better security (fixes #11) 2018-01-14 15:10:11 +01:00