import { CanActivate, ExecutionContext, Logger } from '@nestjs/common'; import { KeycloakService } from '../service'; import { Reflector } from '@nestjs/core'; /** * Guard that is used to protect a UMA resource. If a resource is defined * with the @DefineResource decorator, the guard checks the users access to * any scopes of that resource on Keycloak. * Resource name and all authorised scopes are stored in the request. * * If used with a @DefineScope decorator, the guard checks access for the * given scope and does not append to the request. * * For example: \ * `@DefineResource('administration')` \ * `@UseGuards(ResourceGuard)` * @fritzforsit */ export declare class ResourceGuard implements CanActivate { private keycloak; private readonly reflector; logger: Logger; constructor(keycloak: KeycloakService, reflector: Reflector); getRequest(context: ExecutionContext): any; canActivate(context: ExecutionContext): Promise; } //# sourceMappingURL=resource.guard.d.ts.map