Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitd880b20

Browse files
committed
Fix generation of padding message before encrypting Elgamal in pgcrypto
fe0a0b5, which has added a stronger random source in Postgres, hasintroduced a thinko when creating a padding message which gets encryptedfor Elgamal. The padding message cannot have zeros, which are replacedby random bytes. However if pg_strong_random() failed, the messagewould finish by being considered in correct shape for encryption withzeros.Author: Tom LaneReviewed-by: Michael PaquierDiscussion:https://postgr.es/m/20186.1546188423@sss.pgh.pa.usBackpatch-through: 10
1 parent8d3b389 commitd880b20

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

‎contrib/pgcrypto/pgp-pubenc.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ pad_eme_pkcs1_v15(uint8 *data, int data_len, int res_len, uint8 **res_p)
6666
{
6767
px_memset(buf,0,res_len);
6868
px_free(buf);
69-
break;
69+
returnPXE_NO_RANDOM;
7070
}
7171
}
7272
if (*p!=0)

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp