[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Using the GNU GMP Library for Bignums in Emacs

From: Eli Zaretskii
Subject: Re: Using the GNU GMP Library for Bignums in Emacs
Date: Sat, 21 Apr 2018 20:09:55 +0300

> From: Markus Triska <address@hidden>
> Date: Sat, 21 Apr 2018 18:46:07 +0200
> Using GMP has a significant downside if you run out of memory: There’s
> currently no defined way for the allocation functions to recover from an
> error such as out of memory, they must *terminate* program execution.
> Please see the following page for details:
>    https://gmplib.org/manual/Custom-Allocation.html
> Thus, situtations where you can currently throw an Emacs error that can
> be handled in user code would instead terminate the Emacs process. This
> can for example arise from malicious input that involves very large
> integers as results (7^7^7^7 etc.), and of course also elsewhere.
> Also, it may become hard to stop long GMP calculations, whereas you can
> easily stop computations that are written in Elisp. Thus, long GMP
> calculations may lead to denial of editing attacks.

How are those dangers different from using any other external
library.  Like the JSON library, for excample, or libxml2?

reply via email to

[Prev in Thread] Current Thread [Next in Thread]