[package]
name = "casbin"
version = "0.8.4"
authors = ["Joey <joey.xf@gmail.com>", "Cheng JIANG <jiang.cheng@vip.163.com>"]
edition = "2018"
license = "Apache-2.0"
description = "An authorization library that supports access control models like ACL, RBAC, ABAC."
homepage = "https://casbin.org/"
repository = "https://github.com/casbin/casbin-rs"
readme = "README.md"
keywords = ["auth", "authorization", "rbac", "acl", "abac"]

# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html

[dependencies]
regex = "1.3.1"
rhai = { version = "0.13.0", default-features = false, features = ["sync", "only_i32", "no_function", "no_float"] }
ip_network = { version = "0.3.4", optional = true }
ttl_cache = { version = "0.5.1", optional = true }
lazy_static = "1.4.0"
indexmap = "1.3.1"
async-std = { version = "1.5.0", optional = true }
async-trait = "0.1.24"
log = { version = "0.4.8", optional = true }
tokio = { version = "0.2.11", optional = true, default-features = false }
globset = { version = "0.4.5", optional = true }
thiserror = "1.0.14"

[features]
default = ["runtime-async-std", "incremental"]

runtime-tokio = ["tokio/fs", "tokio/io-util"]
runtime-async-std = ["async-std"]
logging = ["log"]
ip = ["ip_network"]
glob = ["globset"]
cached = ["ttl_cache"]
watcher = []
incremental = []
explain = []

[profile.release.build-override]
opt-level = 0

[target.'cfg(target_arch = "wasm32")'.dev-dependencies]
async-std = { version = "1.5.0", features = [ "attributes" ] }

[target.'cfg(not(target_arch = "wasm32"))'.dev-dependencies]
tokio = { version = "0.2.11", features = [ "full" ] }
async-std = { version = "1.5.0", features = [ "attributes" ] }
