1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<TITLE> [pycrypto] Freezing pycrypto
</TITLE>
<LINK REL="Index" HREF="index.html" >
<LINK REL="made" HREF="mailto:pycrypto%40lists.dlitz.net?Subject=%5Bpycrypto%5D%20Freezing%20pycrypto&In-Reply-To=">
<META NAME="robots" CONTENT="index,nofollow">
<META http-equiv="Content-Type" content="text/html; charset=us-ascii">
<LINK REL="Previous" HREF="000147.html">
<LINK REL="Next" HREF="000151.html">
</HEAD>
<BODY BGCOLOR="#ffffff">
<H1>[pycrypto] Freezing pycrypto</H1>
<B>Marcin Krol</B>
<A HREF="mailto:pycrypto%40lists.dlitz.net?Subject=%5Bpycrypto%5D%20Freezing%20pycrypto&In-Reply-To="
TITLE="[pycrypto] Freezing pycrypto">mrkafk at gmail.com
</A><BR>
<I>Wed Oct 28 06:02:40 CST 2009</I>
<P><UL>
<LI>Previous message: <A HREF="000147.html">[pycrypto] Elliptic curve cryptography and group signature
</A></li>
<LI>Next message: <A HREF="000151.html">[pycrypto] Freezing pycrypto
</A></li>
<LI> <B>Messages sorted by:</B>
<a href="date.html#150">[ date ]</a>
<a href="thread.html#150">[ thread ]</a>
<a href="subject.html#150">[ subject ]</a>
<a href="author.html#150">[ author ]</a>
</LI>
</UL>
<HR>
<!--beginarticle-->
<PRE>Hello everyone,
I'm trying to freeze PyCrypto on Linux (using freeze.py) and having
trouble with it, can you help me? PyCrypto is used by paramiko (ssh
client module).
I have added following in the Modules/Setup while building Python (This
has to be done because freeze.py requires that all compiled extension
modules are compiled statically into Python, otherwise it can't import
them into frozen binary):
*static*
# ... lots of other modules
Crypto.Cipher.DES3 DES3.c
But this produces:
[<A HREF="http://lists.dlitz.net/cgi-bin/mailman/listinfo/pycrypto">root at localhost</A> Python-2.6.2]# make
/bin/sh ./Modules/makesetup -c ./Modules/config.c.in \
-s Modules \
Modules/Setup.config \
Modules/Setup.local \
Modules/Setup
bad word Crypto.Cipher.DES3 in Crypto.Cipher.DES3 DES3.c
make: *** [Makefile] Error 1
If I change that to:
DES3 DES3.c
Python compiles, but then I can't import this module and neither can
PyCrypto in a frozen binary:
[<A HREF="http://lists.dlitz.net/cgi-bin/mailman/listinfo/pycrypto">root at localhost</A> tmp2]# ./cssh
<frozen>:6: DeprecationWarning: the sha module is deprecated; use the
hashlib module instead
<frozen>:6: DeprecationWarning: the md5 module is deprecated; use
hashlib instead
Traceback (most recent call last):
File "cssh.py", line 7, in <module>
import paramiko
File "/usr/local/lib/python2.6/site-packages/paramiko/__init__.py",
line 69, in <module>
from transport import randpool, SecurityOptions, Transport
File "/usr/local/lib/python2.6/site-packages/paramiko/transport.py",
line 37, in <module>
from paramiko.dsskey import DSSKey
File "/usr/local/lib/python2.6/site-packages/paramiko/dsskey.py",
line 31, in <module>
from paramiko.pkey import PKey
File "/usr/local/lib/python2.6/site-packages/paramiko/pkey.py", line
28, in <module>
from Crypto.Cipher import DES3
ImportError: cannot import name DES3
Regards,
mk
</PRE>
<!--endarticle-->
<HR>
<P><UL>
<!--threads-->
<LI>Previous message: <A HREF="000147.html">[pycrypto] Elliptic curve cryptography and group signature
</A></li>
<LI>Next message: <A HREF="000151.html">[pycrypto] Freezing pycrypto
</A></li>
<LI> <B>Messages sorted by:</B>
<a href="date.html#150">[ date ]</a>
<a href="thread.html#150">[ thread ]</a>
<a href="subject.html#150">[ subject ]</a>
<a href="author.html#150">[ author ]</a>
</LI>
</UL>
<hr>
<a href="http://lists.dlitz.net/cgi-bin/mailman/listinfo/pycrypto">More information about the pycrypto
mailing list</a><br>
</body></html>
|