<div dir="ltr"><div>The following inputs to gcry_mpi_invm():</div><div><br></div><div>36fb5bdb5daa9864113ad8a49a41722fc7003a40b02a13daca6997859c2d8534192ff6c02447</div><div>25c88352cfa171fc728503df037c355a6d5588b22e3510b08f10848ad7c0980b400</div><div><br></div><div>produces the number:</div><div><br></div><div>66CAF1A9A03478A288760C2E05E237F11432BA70BECEE56D942ACCD337470E5D77</div><div><br></div><div>But this is incorrect (another library reports the modular inverse does not exist).</div><div><br></div><div>----------</div><div><br></div><div>The following inputs to gcry_mpi_invm():</div><div><br></div><div>12cf3a8ca3d97bea2f080362600cee355</div><div>1c3fddf62aee0be2f6dc2ef8471f1be2e</div><div><br></div><div>produces the number:</div><div><br></div><div>60A6520F494E6EE6EE436283FB34B945</div><div><br></div><div>but it should produce:</div><div><br></div><div>1339462644931fd624528ea6b3fb1f985</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Mon, Jun 1, 2020 at 9:39 AM NIIBE Yutaka <<a href="mailto:gniibe@fsij.org">gniibe@fsij.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Jussi Kivilinna <<a href="mailto:jussi.kivilinna@iki.fi" target="_blank">jussi.kivilinna@iki.fi</a>> wrote:<br>
> Cryptofuzz is reporting another heap-buffer-overflow issue in<br>
> _gcry_mpi_invm. I've attached reproducer, original from Guido and<br>
> as patch applied to tests/basic.c.<br>
<br>
My fix of 69b55f87053ce2494cd4b38dc600f867bc4355be was not enough.<br>
I just push another change:<br>
<br>
6f8b1d4cb798375e6d830fd6b73c71da93ee5f3f<br>
<br>
Thank you for your report.<br>
-- <br>
<br>
_______________________________________________<br>
Gcrypt-devel mailing list<br>
<a href="mailto:Gcrypt-devel@gnupg.org" target="_blank">Gcrypt-devel@gnupg.org</a><br>
<a href="http://lists.gnupg.org/mailman/listinfo/gcrypt-devel" rel="noreferrer" target="_blank">http://lists.gnupg.org/mailman/listinfo/gcrypt-devel</a><br>
</blockquote></div>