Stuart Henderson <[email protected]> writes:
> On 2014/04/21 18:54, Jérémie Courrèges-Anglas wrote:
>> Stuart Henderson <[email protected]> writes:
>>
>> > On 2014/04/20 14:03, Christian Weisgerber wrote:
>> >> I don't know how far ahead or behind sthen@'s and espie@'s builds
>> >> are, but here's some of the current ports breakage I'm seeing:
>> >>
>> >> llvm update:
>> >> www/mozilla-firefox
>> >> www/seamonkey
>> >>
>> >> RAND_egd(_bytes) removal:
>> >> graphics/dcmtk
>> >> lang/pypy
>> >> lang/rubinius
>> >> net/papyon
>> >>
>> >> --
>> >> Christian "naddy" Weisgerber [email protected]
>> >>
>> >
>> > net/papyon is a runtime failure due to py-openssl wanting RAND_egd_bytes
>>
>> I'd happily kill net/papyon:
>>
>> COMMENT= MSN client library for python
>
> I'd rather keep papyon as a canary for py-openssl breakage unless another
> port can be found to take its place..
Make sense.
Speaking of py-openssl, here's a diff to remove the EGD methods.
There's one test that fails, I haven't investigated it.
======================================================================
FAIL: test_digest (__main__.X509Tests)
----------------------------------------------------------------------
Traceback (most recent call last):
File
"/usr/ports/pobj/py-openssl-0.13/pyOpenSSL-0.13/OpenSSL/test/test_crypto.py",
line 1311, in test_digest
b("A8:EB:07:F8:53:25:0A:F2:56:05:C5:A5:C4:C4:C7:15"))
AssertionError: 'C1:B5:90:A4:41:11:C8:30:BF:D4:AA:78:13:46:66:59' !=
'A8:EB:07:F8:53:25:0A:F2:56:05:C5:A5:C4:C4:C7:15'
----------------------------------------------------------------------
Ran 162 tests in 0.875s
FAILED (failures=1)
ok?
Index: Makefile
===================================================================
RCS file: /cvs/ports/security/py-openssl/Makefile,v
retrieving revision 1.19
diff -u -p -r1.19 Makefile
--- Makefile 11 Mar 2013 11:41:28 -0000 1.19
+++ Makefile 21 Apr 2014 18:27:52 -0000
@@ -3,6 +3,7 @@
COMMENT= Python interface to the OpenSSL library
MODPY_EGG_VERSION= 0.13
+REVISION= 0
DISTNAME= pyOpenSSL-${MODPY_EGG_VERSION}
PKGNAME= py-openssl-${MODPY_EGG_VERSION}
CATEGORIES= security devel
@@ -33,7 +34,7 @@ post-install:
TESTDIR=${WRKSRC}/regress
do-test:
- mkdir ${TESTDIR}
+ mkdir -p ${TESTDIR}
cd ${TESTDIR} && ${MODPY_BIN} ${WRKSRC}/OpenSSL/test/test_crypto.py
cd ${TESTDIR} && ${MODPY_BIN} ${WRKSRC}/OpenSSL/test/test_rand.py
cd ${TESTDIR} && ${MODPY_BIN} ${WRKSRC}/OpenSSL/test/test_ssl.py
Index: patches/patch-OpenSSL_rand_rand_c
===================================================================
RCS file: patches/patch-OpenSSL_rand_rand_c
diff -N patches/patch-OpenSSL_rand_rand_c
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ patches/patch-OpenSSL_rand_rand_c 21 Apr 2014 16:57:31 -0000
@@ -0,0 +1,30 @@
+$OpenBSD$
+Disable EGD support.
+--- OpenSSL/rand/rand.c.orig Fri Sep 2 17:46:13 2011
++++ OpenSSL/rand/rand.c Mon Apr 21 18:57:05 2014
+@@ -111,6 +111,7 @@ rand_screen(PyObject *spam, PyObject *args)
+ }
+ #endif
+
++#if 0
+ static char rand_egd_doc[] = "\n\
+ Query an entropy gathering daemon (EGD) for random data and add it to the\n\
+ PRNG. I haven't found any problems when the socket is missing, the function\n\
+@@ -133,6 +134,7 @@ rand_egd(PyObject *spam, PyObject *args)
+
+ return PyLong_FromLong((long)RAND_egd_bytes(path, bytes));
+ }
++#endif
+
+ static char rand_cleanup_doc[] = "\n\
+ Erase the memory used by the PRNG.\n\
+@@ -245,7 +247,9 @@ static PyMethodDef rand_methods[] = {
+ #ifdef MS_WINDOWS
+ { "screen", (PyCFunction)rand_screen, METH_VARARGS,
rand_screen_doc },
+ #endif
++#if 0
+ { "egd", (PyCFunction)rand_egd, METH_VARARGS, rand_egd_doc
},
++#endif
+ { "cleanup", (PyCFunction)rand_cleanup, METH_VARARGS,
rand_cleanup_doc },
+ { "load_file", (PyCFunction)rand_load_file, METH_VARARGS,
rand_load_file_doc },
+ { "write_file",(PyCFunction)rand_write_file, METH_VARARGS,
rand_write_file_doc },
Index: patches/patch-OpenSSL_test_test_rand_py
===================================================================
RCS file: patches/patch-OpenSSL_test_test_rand_py
diff -N patches/patch-OpenSSL_test_test_rand_py
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ patches/patch-OpenSSL_test_test_rand_py 21 Apr 2014 18:32:36 -0000
@@ -0,0 +1,34 @@
+$OpenBSD$
+--- OpenSSL/test/test_rand.py.orig Mon Apr 21 20:27:18 2014
++++ OpenSSL/test/test_rand.py Mon Apr 21 20:27:28 2014
+@@ -95,30 +95,6 @@ class RandTests(TestCase):
+ self.assertTrue(rand.status() in (1, 2))
+
+
+- def test_egd_wrong_args(self):
+- """
+- L{OpenSSL.rand.egd} raises L{TypeError} when called with the wrong
+- number of arguments or with arguments not of type C{str} and C{int}.
+- """
+- self.assertRaises(TypeError, rand.egd)
+- self.assertRaises(TypeError, rand.egd, None)
+- self.assertRaises(TypeError, rand.egd, "foo", None)
+- self.assertRaises(TypeError, rand.egd, None, 3)
+- self.assertRaises(TypeError, rand.egd, "foo", 3, None)
+-
+-
+- def test_egd_missing(self):
+- """
+- L{OpenSSL.rand.egd} returns C{0} or C{-1} if the EGD socket passed
+- to it does not exist.
+- """
+- result = rand.egd(self.mktemp())
+- expected = (-1, 0)
+- self.assertTrue(
+- result in expected,
+- "%r not in %r" % (result, expected))
+-
+-
+ def test_cleanup_wrong_args(self):
+ """
+ L{OpenSSL.rand.cleanup} raises L{TypeError} when called with any
--
jca | PGP : 0x1524E7EE / 5135 92C1 AD36 5293 2BDF DDCC 0DFA 74AE 1524 E7EE