diff --git a/openpgp-card/README.md b/openpgp-card/README.md index 28f1c92..173946a 100644 --- a/openpgp-card/README.md +++ b/openpgp-card/README.md @@ -16,18 +16,14 @@ specification. **Card access backends** -This crate doesn't contain code to talk to cards, The trait `CardClient` -needs to be implemented for access to cards. +This crate doesn't contain code to talk to cards. Implementations of the traits +`CardBackend`/`CardTransaction` need to be provided for access to cards. -The crates -[openpgp-card-pcsc](https://crates.io/crates/openpgp-card-pcsc) -and the experimental crate -[openpgp-card-scdc](https://crates.io/crates/openpgp-card-scdc) -provide implementations of `CardClient` for use with this crate. +The crates [openpgp-card-pcsc](https://crates.io/crates/openpgp-card-pcsc) +and the experimental crate [openpgp-card-scdc](https://crates.io/crates/openpgp-card-scdc) +provide implementations of these traits for use with this crate. **Sequoia PGP wrapper** -See the companion crate -[openpgp-card-sequoia](https://crates.io/crates/openpgp-card-sequoia) -for a high level wrapper to use this library with -[Sequoia PGP](https://sequoia-pgp.org/). \ No newline at end of file +See the companion crate [openpgp-card-sequoia](https://crates.io/crates/openpgp-card-sequoia) +for a high level wrapper to use this library with [Sequoia PGP](https://sequoia-pgp.org/). \ No newline at end of file diff --git a/openpgp-card/src/lib.rs b/openpgp-card/src/lib.rs index 71806f0..27ed054 100644 --- a/openpgp-card/src/lib.rs +++ b/openpgp-card/src/lib.rs @@ -1,7 +1,7 @@ // SPDX-FileCopyrightText: 2021 Heiko Schaefer // SPDX-License-Identifier: MIT OR Apache-2.0 -//! Access library for +//! Client library for //! [OpenPGP card](https://en.wikipedia.org/wiki/OpenPGP_card) //! devices (such as Gnuk, Yubikey, or Java smartcards running an OpenPGP //! card application). diff --git a/pcsc/README.md b/pcsc/README.md index 3418fac..436cc05 100644 --- a/pcsc/README.md +++ b/pcsc/README.md @@ -1,10 +1,25 @@ -**pcsc client for the openpgp-card library** +# PC/SC client for the openpgp-card library -This crate provides `PcscClient`, which is an implementation of the -`CardClient` trait that uses [pcsc](https://crates.io/crates/pcsc) -to access OpenPGP cards. \ No newline at end of file +This crate provides `PcscBackend` and `PcscTransaction`, which are implementations of the +`CardBackend` and `CardTransactions` traits from the [`openpgp-card`](https://crates.io/crates/openpgp-card) crate. + +This implementation uses the [pcsc](https://crates.io/crates/pcsc) Rust wrapper crate +to access OpenPGP cards. + +## Documentation + +[PC/SC](https://en.wikipedia.org/wiki/PC/SC) is a standard for interaction with smartcards and readers. + +The workgroup publishes an [overview]( https://pcscworkgroup.com/specifications/) +and a [set of documents](https://pcscworkgroup.com/specifications/download/) detailing the standard. + +The [pcsc-lite](https://pcsclite.apdu.fr/ ) implementation is used on many free software systems +([API documentation for pcsc-lite](https://pcsclite.apdu.fr/api/group__API.html)). + +Microsoft [documentation](https://docs.microsoft.com/en-us/windows/win32/api/winscard/) +about their implementation of PC/SC. diff --git a/pcsc/src/lib.rs b/pcsc/src/lib.rs index 6389a06..4393ff8 100644 --- a/pcsc/src/lib.rs +++ b/pcsc/src/lib.rs @@ -1,7 +1,7 @@ // SPDX-FileCopyrightText: 2021-2022 Heiko Schaefer // SPDX-License-Identifier: MIT OR Apache-2.0 -//! This crate implements a `CardBackend`/`CardTransaction` backend for +//! This crate implements the `CardBackend`/`CardTransaction` backend for //! `openpgp-card`. It uses the PCSC middleware to access the OpenPGP //! application on smart cards. diff --git a/scdc/README.md b/scdc/README.md index 9b3bf44..29eb68e 100644 --- a/scdc/README.md +++ b/scdc/README.md @@ -5,14 +5,14 @@ SPDX-License-Identifier: MIT OR Apache-2.0 **scdaemon client for the openpgp-card library** -This crate provides `ScdClient`, which is an implementation of the -CardClient trait that uses an instance of GnuPG's +This crate provides `ScdBackend`/`ScdTransaction`, which is an implementation of the +`CardBackend`/`CardTransaction` traits that uses an instance of GnuPG's [scdaemon](https://www.gnupg.org/documentation/manuals/gnupg/Invoking-SCDAEMON.html) to access OpenPGP cards. **Known limitations** -- Uploading RSA 4096 keys via scdaemon doesn't work with cards that don't +- Uploading RSA 4096 keys via `scdaemon` doesn't work with cards that don't support Command Chaining (e.g. the "Floss Shop OpenPGP Smart Card"). This is caused by a size limitation for client requests via the [Assuan](https://www.gnupg.org/documentation/manuals/assuan/) protocol. @@ -24,7 +24,7 @@ to access OpenPGP cards. - When using `scdaemon` via pcsc (by configuring `scdaemon` with `disable-ccid`), choosing a specific card of multiple plugged in OpenPGP cards seems to be broken. - So you probably want to plug in one OpenPGP card at a time when using + So you probably want to plug in only one OpenPGP card at a time when using `openpgp-card-scdc` combined with `disable-ccid`. - When using `scdaemon` via its default `ccid` driver, choosing a @@ -32,3 +32,4 @@ to access OpenPGP cards. to 4 plugged in cards. So you probably want to plug in at most four OpenPGP cards at a time when using `openpgp-card-scdc` with its ccid driver. + (This limit has been raised in GnuPG 2.3.x) diff --git a/scdc/src/lib.rs b/scdc/src/lib.rs index 4686c2d..bd1b48e 100644 --- a/scdc/src/lib.rs +++ b/scdc/src/lib.rs @@ -1,7 +1,7 @@ // SPDX-FileCopyrightText: 2021 Heiko Schaefer // SPDX-License-Identifier: MIT OR Apache-2.0 -//! This crate implements the experimental `ScdClient` backend for the +//! This crate implements the experimental `ScdBackend`/`ScdTransaction` backend for the //! `openpgp-card` crate. //! It uses GnuPG's scdaemon (via GnuPG Agent) to access OpenPGP cards.