netbird/management/server/http
Bethuel Mmbaga 35c892aea3
[management] Restrict accessible peers to user-owned peers for non-admins (#2618)
* Restrict accessible peers to user-owned peers for non-admin users

Signed-off-by: bcmmbaga <bethuelmbaga12@gmail.com>

* add tests

Signed-off-by: bcmmbaga <bethuelmbaga12@gmail.com>

* add service user test

Signed-off-by: bcmmbaga <bethuelmbaga12@gmail.com>

* reuse account from token

Signed-off-by: bcmmbaga <bethuelmbaga12@gmail.com>

* return error when peer not found

Signed-off-by: bcmmbaga <bethuelmbaga12@gmail.com>

---------

Signed-off-by: bcmmbaga <bethuelmbaga12@gmail.com>
2024-09-20 12:36:58 +03:00
..
api [management] Add accessible peers endpoint (#2579) 2024-09-12 16:19:27 +03:00
middleware Add context to throughout the project and update logging (#2209) 2024-07-03 11:33:02 +02:00
util Add context to throughout the project and update logging (#2209) 2024-07-03 11:33:02 +02:00
accounts_handler_test.go Add context to throughout the project and update logging (#2209) 2024-07-03 11:33:02 +02:00
accounts_handler.go Add context to throughout the project and update logging (#2209) 2024-07-03 11:33:02 +02:00
dns_settings_handler_test.go Add context to throughout the project and update logging (#2209) 2024-07-03 11:33:02 +02:00
dns_settings_handler.go Add context to throughout the project and update logging (#2209) 2024-07-03 11:33:02 +02:00
events_handler_test.go Add context to throughout the project and update logging (#2209) 2024-07-03 11:33:02 +02:00
events_handler.go Add context to throughout the project and update logging (#2209) 2024-07-03 11:33:02 +02:00
geolocation_handler_test.go [management] Auto update geolite (#2297) 2024-09-09 18:27:42 +02:00
geolocations_handler.go Add context to throughout the project and update logging (#2209) 2024-07-03 11:33:02 +02:00
groups_handler_test.go Add context to throughout the project and update logging (#2209) 2024-07-03 11:33:02 +02:00
groups_handler.go Add context to throughout the project and update logging (#2209) 2024-07-03 11:33:02 +02:00
handler.go [management] Add accessible peers endpoint (#2579) 2024-09-12 16:19:27 +03:00
nameservers_handler_test.go Add context to throughout the project and update logging (#2209) 2024-07-03 11:33:02 +02:00
nameservers_handler.go Add context to throughout the project and update logging (#2209) 2024-07-03 11:33:02 +02:00
pat_handler_test.go Add context to throughout the project and update logging (#2209) 2024-07-03 11:33:02 +02:00
pat_handler.go Add context to throughout the project and update logging (#2209) 2024-07-03 11:33:02 +02:00
peers_handler_test.go [management] Restrict accessible peers to user-owned peers for non-admins (#2618) 2024-09-20 12:36:58 +03:00
peers_handler.go [management] Restrict accessible peers to user-owned peers for non-admins (#2618) 2024-09-20 12:36:58 +03:00
policies_handler_test.go Add context to throughout the project and update logging (#2209) 2024-07-03 11:33:02 +02:00
policies_handler.go Add context to throughout the project and update logging (#2209) 2024-07-03 11:33:02 +02:00
posture_checks_handler_test.go Fix lint (#2427) 2024-08-14 13:30:10 +03:00
posture_checks_handler.go Add context to throughout the project and update logging (#2209) 2024-07-03 11:33:02 +02:00
routes_handler_test.go Add context to throughout the project and update logging (#2209) 2024-07-03 11:33:02 +02:00
routes_handler.go Add context to throughout the project and update logging (#2209) 2024-07-03 11:33:02 +02:00
setupkeys_handler_test.go Add context to throughout the project and update logging (#2209) 2024-07-03 11:33:02 +02:00
setupkeys_handler.go Add context to throughout the project and update logging (#2209) 2024-07-03 11:33:02 +02:00
users_handler_test.go Add context to throughout the project and update logging (#2209) 2024-07-03 11:33:02 +02:00
users_handler.go Add context to throughout the project and update logging (#2209) 2024-07-03 11:33:02 +02:00