Re: [PATCH] Limit the size of the data block passed to SHA1_Update()

2015-11-04 Thread Eric Sunshine
On Tuesday, November 3, 2015, wrote: > [PATCH] Limit the size of the data block passed to SHA1_Update() As an aid for reviewers, please include the version number of the patch, such as [PATCH vN] where "N" is the revision. format-patch's -v option can help automate this. >

Re: [PATCH] Limit the size of the data block passed to SHA1_Update()

2015-11-04 Thread Junio C Hamano
Junio C Hamano writes: >> ifdef BLK_SHA1 >> SHA1_HEADER = "block-sha1/sha1.h" >> LIB_OBJS += block-sha1/sha1.o >> else >> ifdef PPC_SHA1 >> SHA1_HEADER = "ppc/sha1.h" >> LIB_OBJS += ppc/sha1.o ppc/sha1ppc.o >> else >> ifdef APPLE_COMMON_CRYPTO

Re: [PATCH] Limit the size of the data block passed to SHA1_Update()

2015-11-02 Thread Atousa Duprat
In the Makefile there is the following: ifdef BLK_SHA1 SHA1_HEADER = "block-sha1/sha1.h" LIB_OBJS += block-sha1/sha1.o else ifdef PPC_SHA1 SHA1_HEADER = "ppc/sha1.h" LIB_OBJS += ppc/sha1.o ppc/sha1ppc.o else ifdef APPLE_COMMON_CRYPTO COMPAT_CFLAGS +=

Re: [PATCH] Limit the size of the data block passed to SHA1_Update()

2015-11-02 Thread Junio C Hamano
Atousa Duprat writes: > On Sun, Nov 1, 2015 at 10:37 AM, Junio C Hamano wrote: >> >> Hmm, I admit that this mess is my creation, but unfortunately it >> does not allow us to say: >> >> make SHA1_MAX_BLOCK_SIZE='1024L*1024L*1024L' >> >> when using

Re: [PATCH] Limit the size of the data block passed to SHA1_Update()

2015-11-01 Thread Eric Sunshine
On Sun, Nov 1, 2015 at 1:32 AM, wrote: > Some implementations of SHA_Updates have inherent limits > on the max chunk size. SHA1_MAX_BLOCK_SIZE can be defined > to set the max chunk size supported, if required. This is > enabled for OSX CommonCrypto library and set to 1GiB. >

Re: [PATCH] Limit the size of the data block passed to SHA1_Update()

2015-11-01 Thread Atousa Duprat
>> +int git_SHA1_Update(SHA_CTX *c, const void *data, size_t len) >> +{ >> + size_t nr; >> + size_t total = 0; >> + char *cdata = (char*)data; > I am not sure about the cast > here, though. Doesn't the function SHA1_Update() you are going to > call in the body of the loop take "const

Re: [PATCH] Limit the size of the data block passed to SHA1_Update()

2015-11-01 Thread Atousa Duprat
> Didn't we have this same issue with NonStop port about a year ago and > decided to provision this through the configure script? I'll be happy to look at it. Can you point me to the right email thread or location in the configure.ac file? Atousa -- To unsubscribe from this list: send the line

Re: [PATCH] Limit the size of the data block passed to SHA1_Update()

2015-11-01 Thread Junio C Hamano
atous...@gmail.com writes: > diff --git a/cache.h b/cache.h > index 79066e5..ec84b16 100644 > --- a/cache.h > +++ b/cache.h > @@ -14,7 +14,12 @@ > #ifndef git_SHA_CTX > #define git_SHA_CTX SHA_CTX > #define git_SHA1_InitSHA1_Init > -#define git_SHA1_Update SHA1_Update > +#ifdef

Re: [PATCH] Limit the size of the data block passed to SHA1_Update()

2015-11-01 Thread Junio C Hamano
Atousa Duprat writes: > Indeed, the declaration needs a const void *; but I need to advance by > a specific number of bytes in each iteration of the loop. Hence the > cast. Ah, of course you are right. Silly me. Thanks. -- To unsubscribe from this list: send the line

Re: [PATCH] Limit the size of the data block passed to SHA1_Update()

2015-10-31 Thread Junio C Hamano
"Randall S. Becker" writes: > Didn't we have this same issue with NonStop port about a year ago and > decided to provision this through the configure script? I do not recall, but a support in configure.ac would be a nice addition. It does not have to be a requirement

Re: [PATCH] Limit the size of the data block passed to SHA1_Update()

2015-10-31 Thread Eric Sunshine
On Fri, Oct 30, 2015 at 6:12 PM, Atousa Pahlevan Duprat wrote: > Some implementations of SHA_Updates have inherent limits > on the max chunk size. SHA1_MAX_BLOCK_SIZE can be defined > to set the max chunk size supported, if required. This is > enabled for OSX CommonCrypto

Re: [PATCH] Limit the size of the data block passed to SHA1_Update()

2015-10-30 Thread Junio C Hamano
Atousa Pahlevan Duprat writes: > Some implementations of SHA_Updates have inherent limits > on the max chunk size. SHA1_MAX_BLOCK_SIZE can be defined > to set the max chunk size supported, if required. This is > enabled for OSX CommonCrypto library and set to 1GiB. > ---

RE: [PATCH] Limit the size of the data block passed to SHA1_Update()

2015-10-30 Thread Randall S. Becker
On October-30-15 6:18 PM, Atousa Pahlevan Duprat wrote: >Some implementations of SHA_Updates have inherent limits on the max chunk size. >SHA1_MAX_BLOCK_SIZE can be defined to set the max chunk size supported, if >required. This is enabled for OSX CommonCrypto library and set to 1GiB. >--- >