diff options
| author | Wolfram Sang <wsa@the-dreams.de> | 2017-10-27 15:53:39 +0200 |
|---|---|---|
| committer | Wolfram Sang <wsa@the-dreams.de> | 2017-10-27 15:53:39 +0200 |
| commit | 9b09342f5cfa5b4b3447de17de284111bfdeab26 (patch) | |
| tree | c71fcb17aecf0f77fb8e24f48feb07482f3cff77 /lib | |
| parent | b9e43e363d0115ca981c106d968e24140ad37f6c (diff) | |
| parent | 0224d45c9d46401b6d7018a96cfe049c5da7d91c (diff) | |
| download | net-9b09342f5cfa5b4b3447de17de284111bfdeab26.tar.gz | |
Merge branch 'i2c/cht-wc-fusb302-immutable' into i2c/for-4.15
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/digsig.c | 6 | ||||
| -rw-r--r-- | lib/ts_fsm.c | 2 | ||||
| -rw-r--r-- | lib/ts_kmp.c | 2 |
3 files changed, 8 insertions, 2 deletions
diff --git a/lib/digsig.c b/lib/digsig.c index 03d7c63837aecb..6ba6fcd92dd10c 100644 --- a/lib/digsig.c +++ b/lib/digsig.c @@ -87,6 +87,12 @@ static int digsig_verify_rsa(struct key *key, down_read(&key->sem); ukp = user_key_payload_locked(key); + if (!ukp) { + /* key was revoked before we acquired its semaphore */ + err = -EKEYREVOKED; + goto err1; + } + if (ukp->datalen < sizeof(*pkh)) goto err1; diff --git a/lib/ts_fsm.c b/lib/ts_fsm.c index 5696a35184e4a3..69557c74ef9f8e 100644 --- a/lib/ts_fsm.c +++ b/lib/ts_fsm.c @@ -11,7 +11,7 @@ * ========================================================================== * * A finite state machine consists of n states (struct ts_fsm_token) - * representing the pattern as a finite automation. The data is read + * representing the pattern as a finite automaton. The data is read * sequentially on an octet basis. Every state token specifies the number * of recurrences and the type of value accepted which can be either a * specific character or ctype based set of characters. The available diff --git a/lib/ts_kmp.c b/lib/ts_kmp.c index 632f783e65f1cf..ffbe66cbb0ed60 100644 --- a/lib/ts_kmp.c +++ b/lib/ts_kmp.c @@ -27,7 +27,7 @@ * * [1] Cormen, Leiserson, Rivest, Stein * Introdcution to Algorithms, 2nd Edition, MIT Press - * [2] See finite automation theory + * [2] See finite automaton theory */ #include <linux/module.h> |
