CoreID/app/routing/routers/auth/mfa.routes.js
2020-05-30 17:21:47 -05:00

34 lines
729 B
JavaScript

const mfa_routes = {
prefix: '/auth/mfa',
middleware: [
'auth:UserOnly',
],
get: {
'/setup': [
['middleware::auth:RequireTrust', { scope: 'mfa.enable' }],
'controller::auth:MFA.setup',
],
'/challenge': [
'controller::auth:MFA.challenge',
],
'/disable': [
'controller::auth:MFA.get_disable',
],
'/disable/process': [
['middleware::auth:RequireTrust', { scope: 'mfa.disable' }],
'controller::auth:MFA.do_disable',
],
'/recovery': [
'controller::auth:MFA.get_recovery',
],
},
post: {
},
}
module.exports = exports = mfa_routes