Project status & info:
| License | Crates Version | Docs |
| :--------------------------------------------: | :---------------------------------------: | :----------------------------------: |
| |
|
|
Tower service which limits request from only hosts
Edit Cargo.toml file to add towerallowedhosts as dependencies
toml
[dependencies]
tower_allowed_hosts = "0.1.0"
rust
let tower_layer = tower_allowed_hosts::AllowedHostLayer::new(vec![regex::Regex::new("^127.0.0.1$")]);