Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Initial commit for KBKDF #87

Draft
wants to merge 6 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
60 changes: 60 additions & 0 deletions .github/workflows/kbkdf.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
name: kbkdf

on:
pull_request:
paths:
- "kbkdf/**"
- "Cargo.*"
push:
branches: master

defaults:
run:
working-directory: kbkdf

env:
CARGO_INCREMENTAL: 0
RUSTFLAGS: "-Dwarnings"

jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
rust:
- 1.65.0 # MSRV
- stable
target:
- thumbv7em-none-eabi
- wasm32-unknown-unknown
steps:
- uses: actions/checkout@v4
- uses: RustCrypto/actions/cargo-cache@master
- uses: dtolnay/rust-toolchain@master
with:
toolchain: ${{ matrix.rust }}
targets: ${{ matrix.target }}
- run: cargo build --no-default-features --target ${{ matrix.target }}

minimal-versions:
uses: RustCrypto/actions/.github/workflows/minimal-versions.yml@master
with:
working-directory: ${{ github.workflow }}

test:
runs-on: ubuntu-latest
strategy:
matrix:
rust:
- 1.65.0 # MSRV
- stable
steps:
- uses: actions/checkout@v4
- uses: RustCrypto/actions/cargo-cache@master
- uses: dtolnay/rust-toolchain@master
with:
toolchain: ${{ matrix.rust }}
- run: cargo check --all-features
- run: cargo test --no-default-features
- run: cargo test
- run: cargo test --all-features
17 changes: 17 additions & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
[workspace]
members = [
"hkdf",
"concat-kdf",
"hkdf",
"kbkdf",
]

[profile.dev]
Expand Down
31 changes: 31 additions & 0 deletions kbkdf/Cargo.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
[package]
name = "kbkdf"
version = "0.1.0"
edition = "2018"
authors = ["RustCrypto Developers"]
license = "MIT OR Apache-2.0"
homepage = "https://github.com/RustCrypto/KDFs/"
repository = "https://github.com/RustCrypto/KDFs/"
description = "Key Derivation Using Pseudorandom Function (KBKDF)"
keywords = ["crypto", "KBKDF", "KDF"]
categories = ["cryptography", "no-std"]
readme = "README.md"
rust-version = "1.65"

[dependencies]
digest = { version = "0.10", default-features = false, features = ["mac"] }

# divrem can be dropped with MSRV >= 1.73
divrem = "1.0.0"

[dev-dependencies]
hex-literal = "0.2.2"
hmac = { version = "0.12.1", default-features = false }
sha2 = { version = "0.10", default-features = false }

[features]
std = ["hmac/std"]

[package.metadata.docs.rs]
all-features = true
rustdoc-args = ["--cfg", "docsrs"]
Loading