Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
+ 'GCKIQ0_btqK-jFunT2NBC8RItanDZpptQ',
use: 'sig',
}
]
};
class AppController {
@Get('/.well-known/jwks.json')
getJWKS() {
return new HttpResponseOK(jwks);
}
@Get('/api/users/me')
@JWTRequired({
secretOrPublicKey: getRSAPublicKeyFromJWKS({
jwksUri: 'http://localhost:3000/.well-known/jwks.json'
})
})
getUser() {
return new HttpResponseOK({
name: 'Alix'
});
}
}
server = createApp(AppController).listen(3000);
try {
const response = await superagent
.get('http://localhost:3000/api/users/me')