From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jeroen Hofstee Date: Wed, 30 Jul 2014 23:17:43 +0200 Subject: [U-Boot] [PATCH] rsa: Fix two errors in the implementation In-Reply-To: <53D956EE.20202@myspectrum.nl> References: <1406736017-4554-1-git-send-email-sjg@chromium.org> <53D956EE.20202@myspectrum.nl> Message-ID: <53D960F7.1090705@myspectrum.nl> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Hello Simon, >> { >> - uint32_t i; >> + int i; >> - for (i = key->len - 1; i >= 0; i--) { >> + for (i = (int)key->len - 1; i >= 0; i--) { >> if (num[i] < key->modulus[i]) >> return 0; >> if (num[i] > key->modulus[i]) > > I did indeed not post a patch, since I do not know how this code > is used and how critical it is. And I still haven't bothered to look it > up. > > So just a general comment, which might not make any sense > at all for the actual usage. If num can somehow be controlled by an I meant key->len here of course ^ Regards, Jeroen