Software /
code /
prosody
Comparison
util-src/hashes.c @ 6413:a552f4170aed
util-src/*.c: Add macro for compiling with Lua 5.2
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Wed, 17 Sep 2014 14:30:29 +0200 |
parent | 6412:0e94f89d0e62 |
child | 6615:8e4572a642cb |
comparison
equal
deleted
inserted
replaced
6412:0e94f89d0e62 | 6413:a552f4170aed |
---|---|
24 | 24 |
25 #include "lua.h" | 25 #include "lua.h" |
26 #include "lauxlib.h" | 26 #include "lauxlib.h" |
27 #include <openssl/sha.h> | 27 #include <openssl/sha.h> |
28 #include <openssl/md5.h> | 28 #include <openssl/md5.h> |
29 | |
30 #if (LUA_VERSION_NUM == 502) | |
31 #define luaL_register(L, N, R) luaL_setfuncs(L, R, 0) | |
32 #endif | |
29 | 33 |
30 #define HMAC_IPAD 0x36363636 | 34 #define HMAC_IPAD 0x36363636 |
31 #define HMAC_OPAD 0x5c5c5c5c | 35 #define HMAC_OPAD 0x5c5c5c5c |
32 | 36 |
33 const char *hex_tab = "0123456789abcdef"; | 37 const char *hex_tab = "0123456789abcdef"; |