EAP-FAST Internal Crypto Libraries take a lot of time

Jouni Malinen jkmaline at cc.hut.fi
Tue Jan 16 11:02:25 EST 2007


On Tue, Jan 16, 2007 at 09:15:19PM +0530, ramprasad.rajendran at wipro.com wrote:

> I am using the internal TLS and crypto libraries and have
> CONFIG_INTERNAL_LIBTOMMATH enabled for bringing down the size.

> I find that during EAP-FAST authentication, after the server has sent
> out a Server Hello Message, the code keeps looping infinitely in the
> function s_mp_exptmod in a for(;;) loop. It takes atleast 10 mins before
> the function returns :-(
> 
> Is this behaviour because, the run time memory is not enough or the
> processor is pretty slow.

10 minutes is bit extreme.. One thing to note is that the
CONFIG_INTERNAL_LIBTOMMATH version does not include all the optimized
bignum algorithms from LibTomMath. In other words, it is expected to
take much more CPU than the optimized version (but take less code size).
At least in this particular case, I would recommend testing with the
full LibTomMath (if at all possible with the memory/flash restrictions)
and if the end result is considerable faster, it would be reasonable to
merge in some of the more optimized code into libtommath.c.

-- 
Jouni Malinen                                            PGP id EFC895FA



More information about the HostAP mailing list