package
0.0.0-20221007105759-dc5495358fd7
Repository: https://github.com/jamescun/wg-api.git
Documentation: pkg.go.dev
# Packages
No description provided by the author
# Functions
AuthTokens only allows a request to continue if one of the pre-configured tokens is provided by the client in the Authorization header, otherwise a HTTP 403 Forbidden is returned and the request terminated.
Logger logs JSON-RPC requests.
NewServer initializes a Server with a WireGuard client.
PreventReferer blocks any request that contains a Referer or Origin header, as this would indicate a web browser is submitting the request and this server should NOT be directly accessible that way.