Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/webstronauts/ex_verify_origin
Plug adapter to protect from CSRF attacks by verifying the `Origin` header.
https://github.com/webstronauts/ex_verify_origin
cors csrf elixir phoenix plug
Last synced: about 23 hours ago
JSON representation
Plug adapter to protect from CSRF attacks by verifying the `Origin` header.
- Host: GitHub
- URL: https://github.com/webstronauts/ex_verify_origin
- Owner: webstronauts
- License: mit
- Created: 2020-03-06T19:34:17.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2020-08-06T07:40:49.000Z (over 4 years ago)
- Last Synced: 2024-10-29T08:42:28.756Z (10 days ago)
- Topics: cors, csrf, elixir, phoenix, plug
- Language: Elixir
- Homepage: https://hexdocs.pm/ex_verify_origin
- Size: 16.6 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# ex_verify_origin
[![Build Status](https://img.shields.io/github/workflow/status/webstronauts/ex_verify_origin/test.svg?style=flat-square)](https://github.com/webstronauts/ex_verify_origin/actions?query=workflow%3Atest)
[![Hex.pm](https://img.shields.io/hexpm/v/ex_verify_origin.svg?style=flat-square)](https://hex.pm/packages/ex_verify_origin)A Plug adapter to protect from CSRF attacks by verifying the `Origin` header.
## Installation
To use VerifyOrigin, you can add it to your application's dependencies.
```elixir
def deps do
[
{:ex_verify_origin, "~> 2.0.0"}
]
end
```## Usage
You can use the plug within your pipeline.
```elixir
defmodule MyApp.Endpoint do
plug Logger
plug VerifyOrigin
plug MyApp.Router
end
```To find out more, head to the [online documentation]([https://hexdocs.pm/ex_verify_origin).
## Changelog
Please see [CHANGELOG](CHANGELOG.md) for more information on what has changed recently.
## Contributing
Clone the repository and run `mix test`. To generate docs, run `mix docs`.
## Credits
- [Robin van der Vleuten](https://github.com/robinvdvleuten)
- [All Contributors](../../contributors)## License
The MIT License (MIT). Please see [License File](LICENSE) for more information.