Commit graph

771 commits

Author SHA1 Message Date
Heiko Schaefer
5e96cb6f07
ci: fix opgpcard-rs test image
There is currently no opcard-rs-builddeps image, use opcard-rs-tools instead.
2023-05-19 15:55:50 +02:00
Heiko Schaefer
321258ec06
pcsc: Release 0.3.1 2023-05-01 19:07:48 +02:00
Heiko Schaefer
cf5090bbc6
pcsc: add fn PcscBackend::activate_terminated_card() 2023-05-01 19:07:48 +02:00
Heiko Schaefer
806918b939
openpgp-card: Release 0.3.5 2023-05-01 19:07:48 +02:00
Heiko Schaefer
50e3d12f26
openpgp-card: Add activate_file() to CardTransaction 2023-05-01 19:07:48 +02:00
Heiko Schaefer
81ef12ffb2
ci: set PATH for smartpgp-builddeps image 2023-05-01 19:07:48 +02:00
Heiko Schaefer
4a042d703f
Don't panic if a long command is sent and the backend reports no support for extended length
This case should not happen during normal operation with the pcsc backend. But the condition was triggered in tests with an alternate CardBackend implementation (see: https://gitlab.com/openpgp-card/openpgp-card/-/issues/69).
2023-04-13 18:20:16 +02:00
Heiko Schaefer
629eecd510
Add a comment about the interaction between CardTransaction::init_card_caps and CardTransaction::initialize 2023-04-13 18:07:02 +02:00
Heiko Schaefer
a85d3164d7
openpgp-card-sequoia: Release 0.1.2 2023-04-08 13:52:54 +02:00
Heiko Schaefer
365670041f
openpgp-card-sequoia: fix padding for Curve 25519 private key material.
Importing 25519 keys with leading zero bytes led to failures on at least Gnuk and Nitrokey's opgpcard-rs implementation.

Reported by Wiktor Kwapisiewicz, also see https://codeberg.org/wiktor/broken-nitro
2023-04-08 13:49:01 +02:00
Heiko Schaefer
7a28d36e93
openpgp-card-tools moved to https://codeberg.org/openpgp-card/openpgp-card-tools 2023-03-17 15:16:27 +01:00
Heiko Schaefer
971a19b4f2
Release openpgp-card 0.3.4, openpgp-card-tools 0.9.2 2023-03-13 18:48:00 +01:00
Heiko Schaefer
c460904925
opgpcard: Add a parameter '--key-only' to the ssh command.
This outputs only one line, containing the ssh public key string, which is useful in scripts (e.g. in CI).
2023-03-13 18:47:24 +01:00
Heiko Schaefer
8b9e921db7
Adjust README and subplot test to fix previously wrong application ID format. 2023-03-06 14:41:54 +01:00
Heiko Schaefer
2427708f97
Don't print application ID twice.
Fixes #67.
2023-02-24 00:49:26 +01:00
Heiko Schaefer
8e13ac99ac
opgpcard: Release 0.9.1
Don't hard-depend on nettle and allow explicitly choosing sequoia's cryptographic backend.

Make release builds reproducible.
2023-02-17 20:00:20 +01:00
Heiko Schaefer
89bb29c73a
opgpcard: Make release builds reproducible (by setting "codegen-units = 1"). 2023-02-17 20:00:15 +01:00
Heiko Schaefer
8579919f03
opgpcard: Allow building with different sequoia crypto-backends.
E.g.:

cargo build --no-default-features --features sequoia-openpgp/crypto-rust --features sequoia-openpgp/allow-experimental-crypto --features sequoia-openpgp/allow-variable-time-crypto
2023-02-17 20:00:03 +01:00
Heiko Schaefer
05dc5af9b5
Release openpgp-card-sequoia 0.1.1 2023-02-14 17:52:34 +01:00
Heiko
85874218d8 Merge branch 'allow-feature-selection' into 'main'
openpgp-card-sequoia: Allow selecting crypto backend.

See merge request openpgp-card/openpgp-card!35
2023-02-14 16:46:03 +00:00
Wiktor Kwapisiewicz
6c3163da4b
CI: Install cargo-udeps in a more straightforward way 2023-02-14 16:22:07 +01:00
Wiktor Kwapisiewicz
3c3051e31e
openpgp-card-sequoia: Allow disabling default crypto backend.
Previously the list of features of `sequoia-openpgp` unconditionally
included `crypto-nettle`. That was preventing the use of this crate in
pure Rust setups.

This commit allows disabling crypto backends and it is up to the
crate user to explicitly include `sequoia_openpgp` features that they
want.

See: https://gitlab.com/sequoia-pgp/sequoia/-/blob/main/README.md#note
2023-02-14 16:21:29 +01:00
Heiko
d2db840645 Merge branch 'switch-rsa-to-pure-rust' into 'main'
Replace nettle with pure-rust RSA for conversions

Closes #66

See merge request openpgp-card/openpgp-card!34
2023-02-10 12:32:29 +00:00
Wiktor Kwapisiewicz
5bd73d81fc
Replace nettle with pure-rust RSA for conversions
Fixes: https://gitlab.com/openpgp-card/openpgp-card/-/issues/66
2023-02-10 12:52:47 +01:00
Wiktor Kwapisiewicz
c80e549cc4
Add test for verifying SqRSA conversions 2023-02-10 12:24:51 +01:00
Heiko
bb5f495a5c Merge branch 'update-to-rust' into 'main'
Update to newer Rust

See merge request openpgp-card/openpgp-card!33
2023-02-02 12:16:27 +00:00
Wiktor Kwapisiewicz
c81f3ba6a9 Fix clippy warnings: remove explicit lifetime and unneeded Deref impl 2023-02-02 09:26:21 +01:00
Wiktor Kwapisiewicz
4510c34cdc Fix clippy lints: directly use variables in format! strings
The source has been reformatted using `cargo +nightly fmt`.
2023-02-02 09:09:47 +01:00
Heiko Schaefer
f40f2ffbfb
clippy: new lints 2022-12-25 13:50:19 +01:00
Heiko Schaefer
49b2e95f56
CI: Enable RSA tests for opcard-rs 2022-12-25 00:52:29 +01:00
Heiko Schaefer
e001d9bdba
Don't use deprecated chrono fn. 2022-12-05 15:36:36 +01:00
Heiko Schaefer
65789b0470
opgpcard: Make status output clearer for empty keyslots, in text output mode 2022-12-05 11:30:15 +01:00
Heiko Schaefer
79117415de
Fix dependency version 2022-12-05 11:28:20 +01:00
Heiko
20b5a45e8b Merge branch 'liw/examples' into 'main'
add an example Python script to prepare a card for some organization

Closes #44

See merge request openpgp-card/openpgp-card!24
2022-11-07 20:16:49 +00:00
Lars Wirzenius
3a241a107f add an example Python script to prepare a card for some organization
This is a fairly simplistic example, but shows how to use opgpcard via
its JSON API to set up a card with a specific configuration, for a
specific user. It's meant to show how to get started, and hopefully
can be a base for a custom tool for an organization with specific
needs.

It won't modify a card that already has an OpenPGP key on it, unless
--force is used.

Sponsored-by: author
2022-11-07 21:11:15 +02:00
Heiko Schaefer
4d94386b82
Fix new clippy lints for Rust 1.65 2022-11-07 17:32:28 +01:00
Heiko Schaefer
b80b86b201
opgpcard: simplify directory hierarchy 2022-11-03 16:11:37 +01:00
Heiko Schaefer
a1d6d8cad2
openpgp-card-sequoia: add comments to url fns 2022-11-03 15:10:15 +01:00
Heiko Schaefer
a4dff1ecb8
rustfmt: enable format_code_in_doc_comments 2022-11-03 14:43:28 +01:00
Heiko Schaefer
5e039204d5
remove "use sequoia_openpgp as openpgp;" pattern 2022-11-03 14:43:28 +01:00
Heiko Schaefer
fd07f6b6b9
ci: work around confusing cargo-fmt problem with CARGO_HOME 2022-11-03 14:43:28 +01:00
Heiko Schaefer
27697cb2c5
add rustfmt.toml and set group_imports = "StdExternalCrate" 2022-11-03 14:32:00 +01:00
Heiko Schaefer
87a80a4797
opgpcard: rename "key_status" to "additional_key_status".
This field will only contain data in rare cases (I don't know of a card where it will) when a card has key information for unusual key types (also see OpenPGP card spec 3.4.1 pg.43)
2022-11-03 11:57:20 +01:00
Heiko Schaefer
bfaff6b9bf
opgpcard: handle "key status" information for attestation key. 2022-11-03 11:57:20 +01:00
Heiko Schaefer
80659f71bd
opgpcard: bump version to 0.9.0 2022-10-31 15:50:04 +01:00
Heiko Schaefer
876c22997a
opgpcard: edit README.md
- move text about non-interactive use to its own section
- add a brief introduction to JSON output
- edits to adjust output to changed output format
- minor edits for clarity
2022-10-31 15:50:04 +01:00
Heiko Schaefer
abd2bae179
opgpcard: edits to scripting.md
- use standard example card ident
- slightly generalize manufacturer section
- move copyright information to header (like in other markdown documents)
- minor edits
2022-10-31 15:50:03 +01:00
Heiko Schaefer
7fe693ab98
opgpcard: re-add newlines in text output for 'ssh' 2022-10-31 15:50:03 +01:00
Heiko Schaefer
001bbd4412
opgpcard: tweak 'info' text output; add FIXME to re-work the form of algorithm information output 2022-10-31 15:50:03 +01:00
Heiko Schaefer
ae25e6b608
opgpcard: move creation time up in text output for 'status', and adjust printed field name 2022-10-31 15:50:03 +01:00