8000 GitHub - roq3/JWT-drogon: JWT implementation for the Drogon framework
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

roq3/JWT-drogon

Repository files navigation

JWT-drogon

JWT implementation for the Drogon framework

It is made as a plugin for the Drogon framework.

Plugin required dependencies

Clone repos to root dir of your drogon app

$ cd ~/drogon-app
$ git clone https://github.com/arun11299/cpp-jwt.git
$ git clone https://github.com/nlohmann/json.git

Add some lines in CMakeLists.txt of your dragon app

...
find_package(Drogon CONFIG REQUIRED)

add_subdirectory(cpp-jwt)
add_subdirectory(json)

target_link_libraries(${PROJECT_NAME} PRIVATE Drogon::Drogon cpp-jwt::cpp-jwt nlohmann_json::nlohmann_json)
...

Usage

Download to the plugin directory of the target drogon app, E.g. ~/drogon-app/plugins

$ git clone https://github.com/roq3/JWT-drogon.git
$ cp JWT-drogon/JWT.* ~/drogon-app/plugins
$ cp JWT-drogon/JWT*.* ~/drogon-app/plugins

Be aware of add the plugin into the config.json. Set the "name" field to "JWT"

...
"plugins": [
    {
        "name": "JWT",
        "dependencies": [],
        "config": {
        }
    }
],
...

Build the app as usual

Tests

Clone repos to root dir of the project

$ cd ~/JWT-drogon
$ git clone https://github.com/arun11299/cpp-jwt.git
$ git clone https://github.com/nlohmann/json.git

Before run tests

$ chmod +x test.sh

Run base tests

$ ./test.sh

Run unit tests

$ ./test.sh -t 

Licence

MIT

About

JWT implementation for the Drogon framework

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published
0