Implement RADIUS server!
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
48
app/routing/routers/api/v1/radius.routes.js
Normal file
48
app/routing/routers/api/v1/radius.routes.js
Normal file
@@ -0,0 +1,48 @@
|
||||
const saml_routes = {
|
||||
prefix: '/api/v1/radius',
|
||||
|
||||
middleware: [],
|
||||
|
||||
get: {
|
||||
'/clients': [
|
||||
['middleware::auth:APIRoute'],
|
||||
['middleware::api:Permission', { check: 'v1:radius:clients:list' }],
|
||||
'controller::api:v1:Radius.get_clients',
|
||||
],
|
||||
'/clients/:id': [
|
||||
['middleware::auth:APIRoute'],
|
||||
['middleware::api:Permission', { check: 'v1:radius:clients:get' }],
|
||||
'controller::api:v1:Radius.get_client',
|
||||
],
|
||||
},
|
||||
|
||||
post: {
|
||||
'/attempt': [
|
||||
['middleware::auth:GuestOnly'],
|
||||
'controller::api:v1:Radius.attempt',
|
||||
],
|
||||
'/clients': [
|
||||
['middleware::auth:APIRoute'],
|
||||
['middleware::api:Permission', { check: 'v1:radius:clients:create' }],
|
||||
'controller::api:v1:Radius.create_client',
|
||||
],
|
||||
},
|
||||
|
||||
patch: {
|
||||
'/clients/:id': [
|
||||
['middleware::auth:APIRoute'],
|
||||
['middleware::api:Permission', { check: 'v1:radius:clients:update' }],
|
||||
'controller::api:v1:Radius.update_client',
|
||||
],
|
||||
},
|
||||
|
||||
delete: {
|
||||
'/clients/:id': [
|
||||
['middleware::auth:APIRoute'],
|
||||
['middleware::api:Permission', { check: 'v1:radius:clients:delete' }],
|
||||
'controller::api:v1:Radius.delete_client',
|
||||
],
|
||||
},
|
||||
}
|
||||
|
||||
module.exports = exports = saml_routes
|
||||
Reference in New Issue
Block a user