build: Build with system md5.h on OpenIndiana
[bbaumbach/samba-autobuild/.git] / lib / crypto / md5test.c
index 702e0fcf416c3ed36df36cc6e3e1d9179796398d..f58e131b02dc10a135be1e32c94fa7fb14dc6c9d 100644 (file)
    along with this program.  If not, see <http://www.gnu.org/licenses/>.
 */
 
-#include "includes.h"
-#include "lib/crypto/crypto.h"
+#include "replace.h"
+#include "../lib/util/samba_util.h"
+#include "../lib/crypto/crypto.h"
 
 struct torture_context;
 
+bool torture_local_crypto_md5(struct torture_context *torture);
+
 /*
  This uses the test values from rfc1321
 */
@@ -62,7 +65,7 @@ bool torture_local_crypto_md5(struct torture_context *torture)
        };
 
        for (i=0; i < ARRAY_SIZE(testarray); i++) {
-               struct MD5Context ctx;
+               MD5_CTX ctx;
                uint8_t md5[16];
                int e;
 
@@ -70,7 +73,7 @@ bool torture_local_crypto_md5(struct torture_context *torture)
                DATA_BLOB md5blob;
 
                data = data_blob_string_const(testarray[i].data);
-               md5blob  = strhex_to_data_blob(testarray[i].md5);
+               md5blob  = strhex_to_data_blob(NULL, testarray[i].md5);
 
                MD5Init(&ctx);
                MD5Update(&ctx, data.data, data.length);