crypto/poly1305/poly1305.c:503: error: BUFFER_OVERRUN_L3
  Offset added: [-15, 15] Size: 16.
Showing all 6 steps of the trace


crypto/poly1305/poly1305.c:466:1: <Offset trace>
464.   #endif
465.   
466. > void Poly1305_Update(POLY1305 *ctx, const unsigned char *inp, size_t len)
467.   {
468.   #ifdef POLY1305_ASM

crypto/poly1305/poly1305.c:466:1: Parameter `len`
464.   #endif
465.   
466. > void Poly1305_Update(POLY1305 *ctx, const unsigned char *inp, size_t len)
467.   {
468.   #ifdef POLY1305_ASM

crypto/poly1305/poly1305.c:494:5: Assignment
492.       }
493.   
494.       rem = len % POLY1305_BLOCK_SIZE;
           ^
495.       len -= rem;
496.   

crypto/poly1305/poly1305.c:466:1: <Length trace>
464.   #endif
465.   
466. > void Poly1305_Update(POLY1305 *ctx, const unsigned char *inp, size_t len)
467.   {
468.   #ifdef POLY1305_ASM

crypto/poly1305/poly1305.c:466:1: Parameter `ctx->data[*]`
464.   #endif
465.   
466. > void Poly1305_Update(POLY1305 *ctx, const unsigned char *inp, size_t len)
467.   {
468.   #ifdef POLY1305_ASM

crypto/poly1305/poly1305.c:503:9: Array access: Offset added: [-15, 15] Size: 16
501.   
502.       if (rem)
503.           memcpy(ctx->data, inp, rem);
               ^
504.   
505.       ctx->num = rem;

void Poly1305_Update(POLY1305 *ctx, const unsigned char *inp, size_t len)
{
#ifdef POLY1305_ASM
    poly1305_blocks_f poly1305_blocks_p = ctx->func.blocks;
#endif
    size_t rem, num;
    if ((num = ctx->num)) {
        rem = POLY1305_BLOCK_SIZE - num;
        if (len >= rem) {
            memcpy(ctx->data + num, inp, rem);
            poly1305_blocks(ctx->opaque, ctx->data, POLY1305_BLOCK_SIZE, 1);
            inp += rem;
            len -= rem;
        } else {
            memcpy(ctx->data + num, inp, len);
            ctx->num = num + len;
            return;
        }
    }
    rem = len % POLY1305_BLOCK_SIZE;
    len -= rem;
    if (len >= POLY1305_BLOCK_SIZE) {
        poly1305_blocks(ctx->opaque, inp, len, 1);
        inp += len;
    }
    if (rem)
        memcpy(ctx->data, inp, rem);
    ctx->num = rem;
}
['void Poly1305_Update(POLY1305 *ctx, const unsigned char *inp, size_t len)\n{\n#ifdef POLY1305_ASM\n    poly1305_blocks_f poly1305_blocks_p = ctx->func.blocks;\n#endif\n    size_t rem, num;\n    if ((num = ctx->num)) {\n        rem = POLY1305_BLOCK_SIZE - num;\n        if (len >= rem) {\n            memcpy(ctx->data + num, inp, rem);\n            poly1305_blocks(ctx->opaque, ctx->data, POLY1305_BLOCK_SIZE, 1);\n            inp += rem;\n            len -= rem;\n        } else {\n            memcpy(ctx->data + num, inp, len);\n            ctx->num = num + len;\n            return;\n        }\n    }\n    rem = len % POLY1305_BLOCK_SIZE;\n    len -= rem;\n    if (len >= POLY1305_BLOCK_SIZE) {\n        poly1305_blocks(ctx->opaque, inp, len, 1);\n        inp += len;\n    }\n    if (rem)\n        memcpy(ctx->data, inp, rem);\n    ctx->num = rem;\n}']