Skip to content

Commit f91d2fd

Browse files
committed
Initial commit
0 parents  commit f91d2fd

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

90 files changed

+31123
-0
lines changed

.cargo/config

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
# Target configuration for the CTAP2 app on the nRF52840 chip
2+
[target.thumbv7em-none-eabi]
3+
rustflags = [
4+
"-C", "link-arg=-Tnrf52840dk_layout.ld",
5+
"-C", "relocation-model=static",
6+
"-D", "warnings",
7+
]

.github/ISSUE_TEMPLATE.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
## Expected Behavior
2+
3+
4+
## Actual Behavior
5+
6+
7+
## Steps to Reproduce the Problem
8+
9+
1.
10+
1.
11+
1.
12+
13+
## Specifications
14+
15+
- Version:
16+
- Platform:

.github/PULL_REQUEST_TEMPLATE.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
Fixes #<issue_number_goes_here>
2+
3+
> It's a good idea to open an issue first for discussion.
4+
5+
- [ ] Tests pass
6+
- [ ] Appropriate changes to README are included in PR

.gitignore

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
target/
2+
Cargo.lock
3+
4+
# Prevent people from commiting sensitive files.
5+
crypto_data/
6+
src/ctap/key_material.rs
7+

.gitmodules

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
[submodule "third_party/libtock-rs"]
2+
path = third_party/libtock-rs
3+
url = https://github.com/tock/libtock-rs
4+
[submodule "third_party/tock"]
5+
path = third_party/tock
6+
url = https://github.com/tock/tock

.markdownlint.json

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
{
2+
"default": true,
3+
"heading-style": {
4+
"style": "atx"
5+
},
6+
"no-trailing-spaces": {
7+
"br_spaces": 0,
8+
"strict": true
9+
},
10+
"ul-indent": {
11+
"indent": 4
12+
},
13+
"line-length": {
14+
"line_length": 80,
15+
"code_blocks": false
16+
},
17+
"list-marker-space": {
18+
"ol_single": 2,
19+
"ol_multi": 2,
20+
"ul_single": 3,
21+
"ul_multi": 3
22+
},
23+
"no-inline-html": {
24+
"allowed_elements": [
25+
"img"
26+
]
27+
},
28+
"fenced-code-language": true,
29+
"code-block-style": {
30+
"style": "fenced"
31+
},
32+
"code-fence-style": {
33+
"style": "backtick"
34+
}
35+
}

.travis.yml

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
# Copyright 2019 Google LLC
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License");
4+
# you may not use this file except in compliance with the License.
5+
# You may obtain a copy of the License at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# Unless required by applicable law or agreed to in writing, software
10+
# distributed under the License is distributed on an "AS IS" BASIS,
11+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
# See the License for the specific language governing permissions and
13+
# limitations under the License.
14+
15+
language: rust
16+
rust:
17+
- nightly-2020-01-16
18+
19+
os:
20+
- linux
21+
22+
dist: "trusty" # we need python3-pip
23+
24+
addons:
25+
apt:
26+
packages:
27+
- "python3"
28+
- "python3-pip"
29+
30+
cache:
31+
- rust
32+
- cargo
33+
34+
before-install:
35+
- openssl version
36+
37+
install:
38+
- rustup target add thumbv7em-none-eabi
39+
- rustup component add rustfmt
40+
- cargo install cargo-audit
41+
42+
script:
43+
- ./setup.sh
44+
- cargo audit
45+
- ./run_desktop_tests.sh

.vscode/extensions.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
{
2+
"recommendations": [
3+
"davidanson.vscode-markdownlint",
4+
"rust-lang.rust"
5+
]
6+
}

.vscode/settings.json

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
{
2+
"editor.formatOnSave": true,
3+
"rust-client.channel": "nightly",
4+
// The toolchain is updated from time to time so let's make sure that RLS is updated too
5+
"rust-client.updateOnStartup": true,
6+
"rust.clippy_preference": "on"
7+
}

Cargo.toml

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
[package]
2+
name = "ctap2"
3+
version = "0.1.0"
4+
authors = [
5+
"Fabian Kaczmarczyck <[email protected]>",
6+
"Guillaume Endignoux <[email protected]>",
7+
"Jean-Michel Picod <[email protected]>",
8+
]
9+
license = "Apache-2.0"
10+
edition = "2018"
11+
12+
[dependencies]
13+
libtock = { path = "third_party/libtock-rs" }
14+
cbor = { path = "libraries/cbor" }
15+
crypto = { path = "libraries/crypto" }
16+
byteorder = { version = "1", default-features = false }
17+
arrayref = "0.3.6"
18+
subtle = { version = "2.2", default-features = false, features = ["nightly"] }
19+
20+
[features]
21+
std = ["cbor/std", "crypto/std", "crypto/derive_debug"]
22+
debug_ctap = ["crypto/derive_debug"]
23+
with_ctap1 = ["crypto/with_ctap1"]
24+
panic_console = ["libtock/panic_console"]
25+
26+
[dev-dependencies]
27+
elf2tab = "0.4.0"
28+
29+
[profile.dev]
30+
panic = "abort"
31+
lto = true # Link Time Optimization usually reduces size of binaries and static libraries
32+
33+
[profile.release]
34+
panic = "abort"
35+
lto = true # Link Time Optimization usually reduces size of binaries and static libraries

0 commit comments

Comments
 (0)