You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Upgrade to `tokio` 1.44, `rand` 0.9
* Renamed to yubico_ng and published crate
* Made edition 2024 compatible
* Added several clippy/rust lints and fixed those
* Fixed a panic if the `YK_API_HOST` was invalid
* Use only the main api server, the others are deprecated
* Run cargo fmt
* Updated GHA to use hashes and run/fix zizmor
Signed-off-by: BlackDex <black.dex@gmail.com>
-[X] Synchronous Yubikey client API library, [validation protocol version 2.0](https://developers.yubico.com/yubikey-val/Validation_Protocol_V2.0.html).
17
+
-[X] Synchronous Yubikey client API library, [validation protocol version 2.0](https://developers.yubico.com/OTP/Specifications/OTP_validation_protocol.html).
19
18
-[X] Asynchronous Yubikey client API library relying on [Tokio](https://github.com/tokio-rs/tokio)
20
19
21
20
**Note:** The USB-related features have been moved to a sepatated repository, [yubico-manager](https://github.com/wisespace-io/yubico-manager)
@@ -26,19 +25,27 @@ Add this to your Cargo.toml
26
25
27
26
```toml
28
27
[dependencies]
29
-
yubico = "0.12"
28
+
yubico_ng = "0.13"
29
+
```
30
+
31
+
Or, since this crate is still backwards compatible with the yubico crate.
32
+
```toml
33
+
[dependencies]
34
+
yubico = { version = "0.13", package = "yubico_ng" }
30
35
```
31
36
32
37
The following are a list of Cargo features that can be enabled or disabled:
33
38
34
39
- online-tokio (enabled by default): Provides integration to Tokio using futures.
40
+
- native-tls (enabled by default): Use native-tls provided by the OS.
41
+
- rustls-tls: Use rustls instead of native-tls.
35
42
36
43
You can enable or disable them using the example below:
37
44
38
45
```toml
39
-
[dependencies.yubico]
40
-
version = "0.12"
41
-
# don't include the default features (online-tokio)
46
+
[dependencies.yubico_ng]
47
+
version = "0.13"
48
+
# don't include the default features (online-tokio, native-tls)
42
49
default-features = false
43
50
# cherry-pick individual features
44
51
features = []
@@ -49,10 +56,10 @@ You can enable or disable them using the example below:
49
56
### OTP with Default Servers
50
57
51
58
```rust
52
-
externcrateyubico;
59
+
externcrateyubico_ng;
53
60
54
-
useyubico::config::*;
55
-
useyubico::verify;
61
+
useyubico_ng::config::*;
62
+
useyubico_ng::verify;
56
63
57
64
fnmain() {
58
65
letconfig=Config::default()
@@ -69,8 +76,8 @@ fn main() {
69
76
## OTP with custom API servers
70
77
71
78
```rust
72
-
useyubico::verify;
73
-
useyubico::config::Config;
79
+
useyubico_ng::verify;
80
+
useyubico_ng::config::Config;
74
81
75
82
fnmain() {
76
83
letconfig=Config::default()
@@ -92,8 +99,8 @@ fn main() {
92
99
usefutures::TryFutureExt;
93
100
94
101
usestd::io::stdin;
95
-
useyubico::config::Config;
96
-
useyubico::verify_async;
102
+
useyubico_ng::config::Config;
103
+
useyubico_ng::verify_async;
97
104
98
105
#[tokio::main]
99
106
asyncfnmain() ->Result<(), ()> {
@@ -172,6 +179,16 @@ The OTP is valid.
172
179
173
180
## Changelog
174
181
182
+
- 0.13.0 (2025-04-23):
183
+
* Upgrade to `tokio` 1.44, `rand` 0.9
184
+
* Renamed to yubico_ng and published crate
185
+
* Made edition 2024 compatible
186
+
* Added several clippy/rust lints and fixed those
187
+
* Fixed a panic if the `YK_API_HOST` was invalid
188
+
* Use only the main api server, the others are deprecated
0 commit comments