why2 1.3.2

Lightweight, fast, secure, and easy to use encryption system.
Documentation
# This is part of WHY2
# Copyright (C) 2022-2025 Václav Šmejkal

# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.

# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# GNU General Public License for more details.

# You should have received a copy of the GNU General Public License
# along with this program.  If not, see <https://www.gnu.org/licenses/>.

[package]
name = "why2"
version = "1.3.2"
authors = ["Václav Šmejkal <engo@satan.red>"]
edition = "2024"
license = "GPL-3.0-only"
repository = "https://git.satan.red/ENGO150/WHY2"
description = "Lightweight, fast, secure, and easy to use encryption system."
keywords = ["encryption", "chat", "security", "rust"]
categories = ["cryptography", "network-programming", "command-line-utilities"]

default-run = "why2"

[lib]
name = "why2"
path = "core/lib.rs"

[[bin]]
name = "why2"
path = "chat/bin/client.rs"
required-features = ["client"]

[[bin]]
name = "why2-server"
path = "chat/bin/server.rs"
required-features = ["server"]

[features]
default = []

chat = [
    "dep:base91",
    "dep:bincode",
    "dep:serde",
    "dep:ureq",
    "dep:colored",
    "dep:toml_edit",
    "dep:dirs",
    "dep:semver",
    "dep:p521",
    "dep:hmac",
    "dep:hkdf"
]

client = ["chat", "dep:crossterm"]
server = ["chat", "dep:ctrlc", "dep:argon2", "dep:dashmap"]

[dependencies]
rand = "0.9.2"
rand_chacha = "0.9.0"
sha2 = "0.10.9"
serde_json = "1.0.145"

serde = { version = "1.0.228", features = ["derive"], optional = true }
argon2 = { version = "0.5.3", optional = true }
base91 = { version = "0.1.0", optional = true }
bincode = { version = "2.0.1", features = ["serde"], optional = true }
colored = { version = "3.0.0", optional = true }
crossterm = { version = "0.29.0", optional = true }
ctrlc = { version = "3.5.1", optional = true }
dirs = { version = "6.0.0", optional = true }
p521 = { version = "0.13.3", features = ["ecdh", "pkcs8"], optional = true }
ureq = { version = "3.1.4", optional = true }
semver = { version = "1.0.27", optional = true }
toml_edit = { version = "0.24.0", optional = true }
dashmap = { version = "6.1.0", optional = true }
hmac = { version = "0.12.1", optional = true }
hkdf = { version = "0.12.4", optional = true }

[profile.release]
opt-level = "s"
lto = true
codegen-units = 1
panic = "abort"
strip = true