mirror of
https://github.com/bettercap/bettercap
synced 2025-07-12 16:13:48 -07:00
fix: handling CORS for api.rest
This commit is contained in:
parent
e90c6b5e2d
commit
3c1277ebbc
2 changed files with 10 additions and 0 deletions
|
@ -172,6 +172,8 @@ func (mod *RestAPI) Configure() error {
|
|||
|
||||
router := mux.NewRouter()
|
||||
|
||||
router.Methods("OPTIONS").HandlerFunc(mod.corsRoute)
|
||||
|
||||
router.HandleFunc("/api/events", mod.eventsRoute)
|
||||
router.HandleFunc("/api/session", mod.sessionRoute)
|
||||
router.HandleFunc("/api/session/ble", mod.sessionRoute)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue