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

Include LUA for nginx when building ESP #679

Open
aashish004 opened this issue Aug 21, 2019 · 8 comments
Open

Include LUA for nginx when building ESP #679

aashish004 opened this issue Aug 21, 2019 · 8 comments

Comments

@aashish004
Copy link

Is it possible to include LUA for nginx when building ESP

@qiwzhang
Copy link
Contributor

@PiotrSikora your take on this?

@PiotrSikora
Copy link
Contributor

It's possible, since Lua is just another module, that can be built separately from the core, but it requires creating and maintaining BUILD files for it.

@aashish004
Copy link
Author

@PiotrSikora - Do you think it is worth building and maintaining this?

@PiotrSikora
Copy link
Contributor

@aashish004 that depends on your use case, really.

@aashish004
Copy link
Author

My use case is validation of JWT via cookie, queryParams, or Header (Last one is supported by ESP). The motivation here is to do authentication for all types of clients in one place so that they don't have to do it also for web clients cookie is much secure for me.

@aashish004
Copy link
Author

Also If you can please point me to some documentation on how to include external modules while building ESP.

@qiwzhang
Copy link
Contributor

If just for jwt validation, you can file enhancement issues specifically. ESP currently supports authorization header and "access_token=" query parameter. It doesn't support cookie now, but should be easy to add. The code is here: https://github.com/cloudendpoints/esp/blob/master/src/api_manager/check_auth.cc#L165

@qiwzhang
Copy link
Contributor

ESP gets its Nignx with Bazel supports from here. I am not sure if it supports external contributions.

Another way is to add the Lua module in ESP. The task is: to add bazel dependencies, bazel BUILD file to build it, and add it to the src/nginx/main/module.cc. You can try to play with it, if it works, submit a PR.

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

No branches or pull requests

3 participants