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

[Feature] Enable basic-auth for faasd-containerd in faasd install #11

Closed
alexellis opened this issue Jan 2, 2020 · 1 comment · Fixed by #13
Closed

[Feature] Enable basic-auth for faasd-containerd in faasd install #11

alexellis opened this issue Jan 2, 2020 · 1 comment · Fixed by #13
Labels
good first issue Good for newcomers help wanted Extra attention is needed

Comments

@alexellis
Copy link
Member

alexellis commented Jan 2, 2020

Expected Behaviour

Enable basic-auth in faasd install by updating faas-containerd's unit file to set the basic_auth=true env-var.

Current Behaviour

Whilst faas-containerd now supports basic auth, it's disabled by default leaving it vulnerable, even if faasd and the gateway have it enabled.

Possible Solution

Edit https://github.com/alexellis/faasd/blob/master/hack/faas-containerd.service

Steps to Reproduce (for bugs)

  1. Deploy via current faasd release
  2. See that curl -i host:8080/system/functions has auth - status code 401
  3. See that curl -i host:8081/system/functions has no auth - status code 200

To test the fix, carry out step 1 with your new binary and new systemd unit file in place in your GOPATH. i.e. ./faasd install

Then repeat step 2 and step 3 making sure that both have auth enabled now, they should give status code 401.

@alexellis alexellis changed the title Enable basic-auth in faasd install Enable basic-auth for faasd-containerd in faasd install Jan 2, 2020
@alexellis
Copy link
Member Author

@alexellis alexellis changed the title Enable basic-auth for faasd-containerd in faasd install [Feature] Enable basic-auth for faasd-containerd in faasd install Jan 2, 2020
@alexellis alexellis added good first issue Good for newcomers help wanted Extra attention is needed labels Jan 2, 2020
alexellis pushed a commit that referenced this issue Jan 5, 2020
Fixes #11
Having this env variable set enables basic authentication for faas-containerd.

Signed-off-by: Mark Sharpley <mcs94@cam.ac.uk>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers help wanted Extra attention is needed
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant