Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Authorization #2

Closed
deadtrickster opened this issue Mar 9, 2017 · 0 comments
Closed

Authorization #2

deadtrickster opened this issue Mar 9, 2017 · 0 comments

Comments

@deadtrickster
Copy link
Owner

deadtrickster commented Mar 9, 2017

By default all resources are public.
To enable authorizaton set authorizaton config entry to authorizaton provider.
prometheus_httpd comes with basic auth provider with configuration shortcuts:

%% enable basic auth
{authorizaton, {basic, Login, Password}}

%% enable basic auth with external credentials
%% CredentialsProvider is Callable or {Callable, Args}
%% Callable is Fun/2, Module exporting authorize/2, or {Module, authorize/2}
{authorizaton, {basic, CredentialsProvider}}

%% custom authorization provider
%% Provider = is Callable or {Callable, Args}
%% Callable is Fun/1, Module exporting authorize/1, or {Module, authorize/1}
{authorizaton, Provider}
@deadtrickster deadtrickster changed the title Authentication Authorization Mar 9, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant