ourMD5.hh 1.8 KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. /**********
  2. This library is free software; you can redistribute it and/or modify it under
  3. the terms of the GNU Lesser General Public License as published by the
  4. Free Software Foundation; either version 3 of the License, or (at your
  5. option) any later version. (See <http://www.gnu.org/copyleft/lesser.html>.)
  6. This library is distributed in the hope that it will be useful, but WITHOUT
  7. ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
  8. FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for
  9. more details.
  10. You should have received a copy of the GNU Lesser General Public License
  11. along with this library; if not, write to the Free Software Foundation, Inc.,
  12. 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  13. **********/
  14. // "liveMedia"
  15. // Copyright (c) 1996-2019 Live Networks, Inc. All rights reserved.
  16. // Because MD5 may not be implemented (at least, with the same interface) on all systems,
  17. // we have our own implementation.
  18. // C++ header
  19. #ifndef _OUR_MD5_HH
  20. #define _OUR_MD5_HH
  21. extern char* our_MD5Data(unsigned char const* data, unsigned dataSize, char* outputDigest);
  22. // "outputDigest" must be either NULL (in which case this function returns a heap-allocated
  23. // buffer, which should be later delete[]d by the caller), or else it must point to
  24. // a (>=)33-byte buffer (which this function will also return).
  25. extern unsigned char* our_MD5DataRaw(unsigned char const* data, unsigned dataSize,
  26. unsigned char* outputDigest);
  27. // Like "ourMD5Data()", except that it returns the digest in 'raw' binary form, rather than
  28. // as an ASCII hex string.
  29. // "outputDigest" must be either NULL (in which case this function returns a heap-allocated
  30. // buffer, which should be later delete[]d by the caller), or else it must point to
  31. // a (>=)16-byte buffer (which this function will also return).
  32. #endif