mirror of
git://git.gnupg.org/gnupg.git
synced 2025-07-02 22:46:30 +02:00
agent: Protect commit 135b1e3
against misbehaving Libgcrypt.
* agent/command-ssh.c (ssh_key_to_blob): Check DATALEN. Signed-off-by: Werner Koch <wk@gnupg.org>
This commit is contained in:
parent
f9c83d84e7
commit
9ba4ccdaf5
1 changed files with 1 additions and 1 deletions
|
@ -1964,7 +1964,7 @@ ssh_key_to_blob (gcry_sexp_t sexp, int with_secret,
|
|||
err = gpg_error (GPG_ERR_INV_SEXP);
|
||||
goto out;
|
||||
}
|
||||
if (*p_elems == 'q')
|
||||
if (*p_elems == 'q' && datalen)
|
||||
{ /* Remove the prefix 0x40. */
|
||||
data++;
|
||||
datalen--;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue