Commit Graph

20 Commits

Author SHA1 Message Date
Clément Bœsch 90fe0800fb Merge commit '00b6a765430e5c5cacf0bd1be8b318d631cd4e14'
* commit '00b6a765430e5c5cacf0bd1be8b318d631cd4e14':
  hmac: Explicitly convert types at function pointer assignment

Merged-by: Clément Bœsch <cboesch@gopro.com>
2017-05-05 13:27:03 +02:00
Diego Biurrun 00b6a76543 hmac: Explicitly convert types at function pointer assignment
Fixes a number of warnings of the type
libavutil/hmac.c:61:21: warning: assignment from incompatible pointer type
2017-01-09 15:18:16 +01:00
Derek Buitenhuis 96d616052b Merge commit 'd12b5b2f135aade4099f4b26b0fe678656158c13'
* commit 'd12b5b2f135aade4099f4b26b0fe678656158c13':
  build: Split test programs off into separate files

Some conversions done by: James Almer <jamrial@gmail.com>
Merged-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
2016-05-11 19:13:03 +01:00
Diego Biurrun d12b5b2f13 build: Split test programs off into separate files
This avoids spurious library rebuilds when only the test program
code is changed and simplifies the build system.
2016-04-07 16:14:42 +02:00
Hendrik Leppkes 137f075993 lavu/hmac: remove deprecated type ids 2015-09-05 18:07:20 +02:00
James Almer bc397246aa avutil/hmac: fix API/ABI compatibility with the fork
The test code is updated with some cosmetics to avoid the loop
using undefined AVHMACType values.
The old enum values will be removed in the next major bump, effectively
making both projects synced and without API or ABI issues.

Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: James Almer <jamrial@gmail.com>
2015-07-29 21:32:05 -03:00
James Almer e59f7cd89e fate: add test vectors for HMAC SHA and SHA-2
Also replace custom tests for MD5 with those published in RFC 2202

Signed-off-by: James Almer <jamrial@gmail.com>
Signed-off-by: Martin Storsjö <martin@martin.st>
2015-07-29 22:09:16 +03:00
James Almer 7e38340b83 hmac: add support for SHA-2
Signed-off-by: James Almer <jamrial@gmail.com>
Signed-off-by: Martin Storsjö <martin@martin.st>
2015-07-29 22:09:16 +03:00
Michael Niedermayer 21ee6da70c avutil/hmac: Check av_hmac_alloc() return code
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2015-03-30 23:24:33 +02:00
Michael Niedermayer 05e74ac2f3 avutil/hmac: use av_freep() to avoid leaving stale pointers in memory
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-12-27 15:50:01 +01:00
Michael Niedermayer a68b6ec7f5 avutil/hmac: make const tables static const
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-08-06 20:30:55 +02:00
James Almer 1163910a00 fate: Add test vectors for HMAC SHA and SHA-2
Also replace custom tests for MD5 with those published in RFC 2202

Signed-off-by: James Almer <jamrial@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-06-12 01:48:23 +02:00
James Almer 82ef67016e lavu/hmac: Add support for SHA-2
Includes HMAC-SHA-224, HMAC-SHA-256, HMAC-SHA-384, and HMAC-SHA-512.
Tested using test vectors from https://tools.ietf.org/html/rfc4231

Signed-off-by: James Almer <jamrial@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-06-12 01:47:42 +02:00
Michael Niedermayer 9c49d5908d avutil/hmac: silence pointer type warnings
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-05-20 14:48:55 +02:00
Michael Niedermayer 3c200aa693 Merge commit '1fda184a85178cfd7b98d9e308d18e1ded76a511'
* commit '1fda184a85178cfd7b98d9e308d18e1ded76a511':
  avutil: Add av_cold attributes to init functions missing them

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-05-05 12:53:50 +02:00
Diego Biurrun 1fda184a85 avutil: Add av_cold attributes to init functions missing them 2013-05-04 22:48:05 +02:00
Michael Niedermayer 9ea65c65f7 Merge commit '0eecafc948b74c247ebbc59f18f508db5d590d0b'
* commit '0eecafc948b74c247ebbc59f18f508db5d590d0b':
  configure: Make the new srtp protocol depend on the rtp protocol
  lavf: Add a fate test for the SRTP functions
  lavu: Add a fate test for the HMAC API

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-01-16 12:07:27 +01:00
Martin Storsjö 3130fa51a5 lavu: Add a fate test for the HMAC API
Signed-off-by: Martin Storsjö <martin@martin.st>
2013-01-15 23:18:07 +02:00
Michael Niedermayer e7e0186eeb Merge commit 'ab2ad8bd56882c0ea160b154e8b836eb71abc49d'
* commit 'ab2ad8bd56882c0ea160b154e8b836eb71abc49d':
  lavf: Add functions for SRTP decryption/encryption
  lavu: Add an API for calculating HMAC (RFC 2104)

Conflicts:
	doc/APIchanges
	libavutil/version.h

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2013-01-15 15:57:33 +01:00
Martin Storsjö 8ee288d258 lavu: Add an API for calculating HMAC (RFC 2104)
This supports HMAC-MD5 and HMAC-SHA1 for now, other hashes are
simple to add.

Signed-off-by: Martin Storsjö <martin@martin.st>
2013-01-15 11:54:19 +02:00