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

auth v3: support jwt as auth token #5718

Closed
mitake opened this issue Jun 20, 2016 · 7 comments
Closed

auth v3: support jwt as auth token #5718

mitake opened this issue Jun 20, 2016 · 7 comments
Assignees
Milestone

Comments

@mitake
Copy link
Contributor

mitake commented Jun 20, 2016

For production use cases, current simple token of auth v3 is too naive e.g. its token is a randomly generated string and doesn't care about the cost of guessing by attackers.

JWT seems to be useful for the purpose. auth v3 needs to support it as its token. jwt-go would be a suitable implementation for etcd.

@mitake mitake self-assigned this Jun 20, 2016
@mitake
Copy link
Contributor Author

mitake commented Jun 20, 2016

@xiang90 I think https://github.com/dgrijalva/jwt-go is a suitable library for the purpose. Do you have opinions about library selection? CoreOS people would know well about jwt libraries because of https://github.com/coreos/jwtproxy (jwtproxy has its own jwt implementation?). I'd like to hear suggestions about jwt library selection.

@xiang90
Copy link
Contributor

xiang90 commented Jun 21, 2016

What do we expect to put inside each jwt token? Just username? Or also the role details attached to the user?

@mitake
Copy link
Contributor Author

mitake commented Jun 22, 2016

I think just username would be fine for now. It may be affected by proxy design and including role details would be useful for the case (but it will bring consistency problems).

@xiang90
Copy link
Contributor

xiang90 commented Jun 22, 2016

how are we going to revoke a jwt token? will it be timeout based?

@mitake
Copy link
Contributor Author

mitake commented Jun 22, 2016

I think there are two ways;

  1. revision based. It requires that AuthStore is revision aware
  2. timeout based. Of course etcd nodes must not use their local clock for this purpose. So we need a new clock driven by raftpb.MsgHeartbeat.

The second one would be simpler. How do you think?

@heyitsanthony heyitsanthony added this to the v3.2.0 milestone Dec 7, 2016
@xiang90
Copy link
Contributor

xiang90 commented Mar 9, 2017

@mitake I am closing this. We still need to work on the documentation side. There is already a tracking issue.

@xiang90 xiang90 closed this as completed Mar 9, 2017
@mitake
Copy link
Contributor Author

mitake commented Mar 9, 2017

@xiang90 yes, the doc issues can be tracked here: #7251
Thanks for closing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

3 participants