pkgsrc-Changes archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
CVS commit: pkgsrc/chat/prosody
Module Name: pkgsrc
Committed By: joerg
Date: Thu Dec 15 23:45:42 UTC 2016
Modified Files:
pkgsrc/chat/prosody: distinfo
Added Files:
pkgsrc/chat/prosody/patches: patch-util-src_hashes.c
Log Message:
Don't conflict with NetBSD's hmac(3).
To generate a diff of this commit:
cvs rdiff -u -r1.12 -r1.13 pkgsrc/chat/prosody/distinfo
cvs rdiff -u -r0 -r1.1 pkgsrc/chat/prosody/patches/patch-util-src_hashes.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: pkgsrc/chat/prosody/distinfo
diff -u pkgsrc/chat/prosody/distinfo:1.12 pkgsrc/chat/prosody/distinfo:1.13
--- pkgsrc/chat/prosody/distinfo:1.12 Mon Feb 1 12:35:33 2016
+++ pkgsrc/chat/prosody/distinfo Thu Dec 15 23:45:42 2016
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.12 2016/02/01 12:35:33 fhajny Exp $
+$NetBSD: distinfo,v 1.13 2016/12/15 23:45:42 joerg Exp $
SHA1 (prosody-0.9.10.tar.gz) = 572b3dc6f29cb304cc7d4c5a2ef570cf0638fe63
RMD160 (prosody-0.9.10.tar.gz) = adee85a03e80b8953c55ec6dc5e89773c342bc5a
@@ -9,3 +9,4 @@ SHA1 (patch-ab) = 755dd6d77689ef56ea4468
SHA1 (patch-ad) = abcae34982fee846c00252be1c0b033a44ad65d0
SHA1 (patch-prosodyctl) = e3e3a8f03c6d7c74b9026cf7ada765ee86c8397e
SHA1 (patch-util-src_Makefile) = be6d7dd7224a56687238a85827756c109d068a96
+SHA1 (patch-util-src_hashes.c) = ddd8a623209def4e7ff923d71a20e0c143f6ebaf
Added files:
Index: pkgsrc/chat/prosody/patches/patch-util-src_hashes.c
diff -u /dev/null pkgsrc/chat/prosody/patches/patch-util-src_hashes.c:1.1
--- /dev/null Thu Dec 15 23:45:42 2016
+++ pkgsrc/chat/prosody/patches/patch-util-src_hashes.c Thu Dec 15 23:45:42 2016
@@ -0,0 +1,40 @@
+$NetBSD: patch-util-src_hashes.c,v 1.1 2016/12/15 23:45:42 joerg Exp $
+
+Avoid conflict with NetBSD's hmac.
+
+--- util-src/hashes.c.orig 2016-12-15 15:20:05.616992510 +0000
++++ util-src/hashes.c
+@@ -70,7 +70,7 @@ struct hash_desc {
+ void *ctx, *ctxo;
+ };
+
+-static void hmac(struct hash_desc *desc, const char *key, size_t key_len,
++static void myhmac(struct hash_desc *desc, const char *key, size_t key_len,
+ const char *msg, size_t msg_len, unsigned char *result)
+ {
+ union xory {
+@@ -124,7 +124,7 @@ static int myFunc(lua_State *L) { \
+ desc.digestLength = size; \
+ desc.ctx = &ctx; \
+ desc.ctxo = &ctxo; \
+- hmac(&desc, key, key_len, msg, msg_len, hash); \
++ myhmac(&desc, key, key_len, msg, msg_len, hash); \
+ if (hex_out) { \
+ toHex(hash, size, result); \
+ lua_pushlstring(L, (char*)result, size*2); \
+@@ -168,13 +168,13 @@ static int LscramHi(lua_State *L) {
+ luaL_error(L, "Out of memory in scramHi");
+ memcpy(salt2, salt, salt_len);
+ memcpy(salt2 + salt_len, "\0\0\0\1", 4);
+- hmac(&desc, str, str_len, salt2, salt_len + 4, Ust);
++ myhmac(&desc, str, str_len, salt2, salt_len + 4, Ust);
+ free(salt2);
+
+ memcpy(res.bytes, Ust, sizeof(res));
+ for (i = 1; i < iter; i++) {
+ int j;
+- hmac(&desc, str, str_len, (char*)Ust, sizeof(Ust), Und.bytes);
++ myhmac(&desc, str, str_len, (char*)Ust, sizeof(Ust), Und.bytes);
+ for (j = 0; j < SHA_DIGEST_LENGTH/4; j++)
+ res.quadbytes[j] ^= Und.quadbytes[j];
+ memcpy(Ust, Und.bytes, sizeof(Ust));
Home |
Main Index |
Thread Index |
Old Index