keepass 0.8.21

KeePass .kdbx database file parser
Documentation
[package]
name = "keepass"
description = "KeePass .kdbx database file parser"
edition = "2018"
rust-version = "1.85.1"

homepage = "https://github.com/sseemayer/keepass-rs"
repository = "https://github.com/sseemayer/keepass-rs"
documentation = "https://docs.rs/keepass"

version = "0.8.21"
authors = ["Stefan Seemayer <stefan@seemayer.de>"]
license = "MIT"

readme = "README.md"

include = [
  "src/",
  "README.md",
  "LICENSE",
]

[features]
utilities = ["anyhow", "clap", "rpassword", "serialization", "totp"]
serialization = ["serde", "serde_json", "chrono/serde"]
totp = ["totp-lite", "url", "base32"]
save_kdbx4 = []
challenge_response = ["sha1", "dep:challenge_response"]
_merge = []

default = []

[dependencies]
thiserror = "2"

# encoding and parsing
byteorder = "1"
flate2 = "1"
xml-rs = "1.0"
base64 = "0.22"
hex-literal = "1"
secstr = "0.5"
chrono = { version = "0.4.23", default-features = false, features = [
    "serde",
    "clock",
    "std",
] }

# cryptography
rust-argon2 = "3.0"
sha1 = { version = "0.10", optional = true }
sha2 = "0.10"
aes = "0.8"
block-modes = "0.9"
hmac = "0.12"
salsa20 = "0.10"
chacha20 = "0.9"
cipher = { version = "0.4", features = ["std"] }
twofish = "0.7"
cbc = "0.1"

challenge_response = { version = "0.5", optional = true, default-features = false, features = ["nusb"] }

uuid = { version = "1.18.1", features = ["v4", "serde"] }
hex = { version = "0.4" }
getrandom = { version = "0.4", features = ["std"] }
zeroize = { version = "1", features = ["zeroize_derive"] }

# dependencies for command-line utilities
anyhow = { version = "1", optional = true }
clap = { version = "4", optional = true, features = ["derive"] }
rpassword = { version = "7", optional = true }

# dependencies for serialization (enabled by "serialization" feature)
serde = { version = "1", optional = true, features = ["derive"] }
serde_json = { version = "1", optional = true }

# dependencies for totp (enabled by "totp" feature)
totp-lite = { version = "2.0", optional = true }
url = { version = "2.2", optional = true }
base32 = { version = "0.5", optional = true }

[target.'cfg(not(target_arch = "wasm32"))'.dev-dependencies]
# rustfmt is only needed for native targets; compiling it (and its syntex_*) for
# wasm32 causes build failures, so we keep it as a dev-dependency but exclude it
# on wasm.
rustfmt = "0.10"

[target.'cfg(target_arch = "wasm32")'.dependencies]
js-sys = "0.3"
# For wasm32-unknown-unknown, use the JS backend of getrandom. This mirrors the
# configuration used in the database crate and ensures that random bytes work
# correctly in WebAssembly environments.
getrandom = { version = "0.4", features = ["wasm_js"] }
uuid = { version = "1.18.1", features = ["js"] }

[target.'cfg(target_arch = "wasm32")'.dev-dependencies]
wasm-bindgen-test = "0.3"

[[bin]]
# parse a KeePass database and output as a JSON document
name = "kp-dump-json"
required-features = ["utilities"]

[[bin]]
# decrypt a KeePass database and output the inner XML document
name = "kp-dump-xml"
required-features = ["utilities"]

[[bin]]
# Purge the history items in the Database entries
name = "kp-purge-history"
required-features = ["utilities", "save_kdbx4"]

[[bin]]
# decrypt a KeePass database and show the contained data
name = "kp-show-db"
required-features = ["utilities"]

[[bin]]
# decrypt a KeePass database and show the TOTP value for an entry
name = "kp-show-otp"
required-features = ["utilities"]

[[bin]]
# get the version of a KeePass database file
name = "kp-get-version"
required-features = ["utilities"]

[[bin]]
# parse and write a KeePass database (to check if all fields are kept)
name = "kp-rewrite"
required-features = ["utilities", "save_kdbx4"]

[[bin]]
name = "kp-yk-add"
required-features = ["utilities", "save_kdbx4", "challenge_response"]

[[bin]]
name = "kp-yk-remove"
required-features = ["utilities", "save_kdbx4", "challenge_response"]

[[bin]]
name = "kp-yk-recover"
required-features = ["utilities", "save_kdbx4", "challenge_response"]

[lints.rust]
unexpected_cfgs = { level = "warn", check-cfg = ['cfg(tarpaulin_include)'] }

[[example]]
name = "save_database"
required-features = ["save_kdbx4"]