mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: "Jan Lübbe" <jlu@pengutronix.de>
To: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Cc: barebox@lists.infradead.org
Subject: Re: [PATCH 8/8] command: add hmac sum supportfor md5, sha1, sha224, sha256, sha384, sha512
Date: Mon, 16 Mar 2015 12:01:32 +0100	[thread overview]
Message-ID: <1426503692.3330.41.camel@pengutronix.de> (raw)
In-Reply-To: <1426092789-7708-8-git-send-email-plagnioj@jcrosoft.com>

On Mi, 2015-03-11 at 17:53 +0100, Jean-Christophe PLAGNIOL-VILLARD
wrote:
> diff --git a/include/digest.h b/include/digest.h
> index a26848c..fd47a7e 100644
> --- a/include/digest.h
> +++ b/include/digest.h
> @@ -54,11 +54,14 @@ struct digest *digest_alloc(char* name);
>  void digest_free(struct digest *d);
>  
>  int digest_file_window(struct digest *d, char *filename,
> +                      unsigned char *key, size_t keylen,
>                        unsigned char *hash,
>                        ulong start, ulong size);
>  int digest_file(struct digest *d, char *filename,
> +                      unsigned char *key, size_t keylen,
>                        unsigned char *hash);

This is already in next, but I'd like to know why you added the
key/keylen args to each function instead of letting the caller use
digest_set_key()?

In the patch "[PATCH 04/10] command: add generic digest command" you add
another parameter (unsigned char *sig) to these functions, which is used
instead of the key parameter when verifying.

Maybe we are overloading them with to much different functionality? 

Regards,
Jan
-- 
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |


_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

  reply	other threads:[~2015-03-16 11:01 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-03-11 16:50 [PATCH 0/8 v3] add sha384/sha512 and hmac support Jean-Christophe PLAGNIOL-VILLARD
2015-03-11 16:53 ` [PATCH 1/8] digest: move digest.c to crypto Jean-Christophe PLAGNIOL-VILLARD
2015-03-11 16:53   ` [PATCH 2/8] digest: introduce digest_{init/update/final/length} Jean-Christophe PLAGNIOL-VILLARD
2015-03-11 16:53   ` [PATCH 3/8] digest: make it multi-instance Jean-Christophe PLAGNIOL-VILLARD
2015-03-11 16:53   ` [PATCH 4/8] crypto: add sha384 & sha512 support Jean-Christophe PLAGNIOL-VILLARD
2015-03-11 16:53   ` [PATCH 5/8] command: add sha384sum and sha512sum support Jean-Christophe PLAGNIOL-VILLARD
2015-03-11 16:53   ` [PATCH 6/8] password: add support for sha512 Jean-Christophe PLAGNIOL-VILLARD
2015-03-11 16:53   ` [PATCH 7/8] digest: add HMAC support for md5, sha1, sha224, sha256, sha384, sha512 Jean-Christophe PLAGNIOL-VILLARD
2015-03-12  7:17     ` Sascha Hauer
2015-03-12  8:13       ` Jean-Christophe PLAGNIOL-VILLARD
2015-03-11 16:53   ` [PATCH 8/8] command: add hmac sum supportfor " Jean-Christophe PLAGNIOL-VILLARD
2015-03-16 11:01     ` Jan Lübbe [this message]
2015-03-16 11:27       ` Jean-Christophe PLAGNIOL-VILLARD
2015-03-16 12:52       ` Sascha Hauer
  -- strict thread matches above, loose matches on Subject: below --
2015-03-11 13:26 [PATCH 0/8] add sha384/sha512 and hmac support Jean-Christophe PLAGNIOL-VILLARD
2015-03-11 13:41 ` [PATCH 1/8] digest: move digest.c to crypto Jean-Christophe PLAGNIOL-VILLARD
2015-03-11 13:41   ` [PATCH 8/8] command: add hmac sum supportfor md5, sha1, sha224, sha256, sha384, sha512 Jean-Christophe PLAGNIOL-VILLARD

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1426503692.3330.41.camel@pengutronix.de \
    --to=jlu@pengutronix.de \
    --cc=barebox@lists.infradead.org \
    --cc=plagnioj@jcrosoft.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox