tupi-auth-key

command module
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 8, 2023 License: AGPL-3.0 Imports: 14 Imported by: 0

README

Tupi-auth-key is a plugin for Tupi to allow the use of an Authorization header to authenticate a request. Autorization keys are stored hashed with sha512 in a sqlite database.

Install

To install tupi-auth-key first clone the code:

$ git clone https://github.com/jucacrispim/tupi-auth-key

And then build the code:

$ cd tupi-auth-key
$ make build

This will create two binaries: ./build/auth_plugin.so and ./build/tupi-auth-key. The first file is the plugin that will be used by Tupi. The second file is a small command line tool to manage your keys.

Usage

To use the plugin with tupi, in your config file put:

...
AuthPlugin = "/path/to/auth_plugin.so"
AuthPluginConf = {
    "uri": "/path/to/db.sqlite?the=option&other=value"
}
...

To manage your keys use the command line tool:

$ ./build/tupi-auth-key -h

Documentation

Overview

go:build !test

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL