From bear at code-bear.com Wed Oct 5 17:28:57 2005 From: bear at code-bear.com (Mike Taylor) Date: Wed, 5 Oct 2005 11:28:57 -0400 Subject: [pyOpenSSL] win32 python2.4 Vc7 binary Message-ID: <7d554281a1ec85e40ddeac592e66182c@code-bear.com> Using the patch that Robert Cheung provided in message http://sourceforge.net/mailarchive/message.php?msg_id=13125731 I've created a win32 exe using Python 2.4 and Vc7. Would this be useful to the pyOpenSSL team? thanks, --- Bear Build and Release Engineer Open Source Applications Foundation (OSAF) bear at osafoundation.org http://www.osafoundation.org bear at code-bear.com http://code-bear.com PGP Fingerprint = 9996 719F 973D B11B E111 D770 9331 E822 40B3 CD29 -------------- next part -------------- A non-text attachment was scrubbed... Name: PGP.sig Type: application/pgp-signature Size: 186 bytes Desc: This is a digitally signed message part URL: From mike at pcblokes.com Thu Oct 6 21:57:40 2005 From: mike at pcblokes.com (Michael Foord) Date: Thu, 6 Oct 2005 20:57:40 +0100 Subject: [pyOpenSSL] win32 python2.4 Vc7 binary Message-ID: -----Original Message----- From: "Mike Taylor" Sent: 05/10/05 16:28:57 To: "pyopenssl-list at lists.sourceforge.net" Subject: [pyOpenSSL] win32 python2.4 Vc7 binary Using the patch that Robert Cheung provided in message http://sourceforge.net/mailarchive/message.php?msg_id=13125731 I've created a win32 exe using Python 2.4 and Vc7. Would this be useful to the pyOpenSSL team? It would be useful to me (and others). I'm happy to host it on Voidspace if you want ? Thanks Fuzzyman Http://www.voidspace.org.uk/python thanks, --- Bear Build and Release Engineer Open Source Applications Foundation (OSAF) bear at osafoundation.org http://www.osafoundation.org bear at code-bear.com http://code-bear.com PGP Fingerprint = 9996 719F 973D B11B E111 D770 9331 E822 40B3 CD29 [Message truncated. Tap Edit->Mark for Download to get remaining portion.] From bear at code-bear.com Thu Oct 6 22:17:06 2005 From: bear at code-bear.com (Mike Taylor) Date: Thu, 6 Oct 2005 16:17:06 -0400 Subject: [pyOpenSSL] win32 python2.4 Vc7 binary In-Reply-To: References: Message-ID: On Oct 6, 2005, at 3:57 PM, Michael Foord wrote: > Would this be useful to the pyOpenSSL team? > > It would be useful to me (and others). > > I'm happy to host it on Voidspace if you want ? I don't mind hosting it at all - just was wondering if anyone else would find it useful. You can get it http://code-bear.com/pyopenssl/ I would appreciate any feedback on if it works - I used setup.py install to install mine and generated this using setup.py bdist_win32inst enjoy! --- Bear Build and Release Engineer Open Source Applications Foundation (OSAF) bear at osafoundation.org http://www.osafoundation.org bear at code-bear.com http://code-bear.com PGP Fingerprint = 9996 719F 973D B11B E111 D770 9331 E822 40B3 CD29 -------------- next part -------------- A non-text attachment was scrubbed... Name: PGP.sig Type: application/pgp-signature Size: 186 bytes Desc: This is a digitally signed message part URL: From manishrjain at gmail.com Mon Oct 17 19:01:28 2005 From: manishrjain at gmail.com (Manish Rai Jain) Date: Tue, 18 Oct 2005 01:01:28 +0800 Subject: [pyOpenSSL] Help with ssl connection using X.509 objects Message-ID: Hi I am trying to connect to an JAVA based SSL server, which is using X.509certificates. Here is the java code: ******************************************************************************* > SSLContext ctx; > KeyManagerFactory kmf; > KeyStore ks; > char[] passphrase = pass.toCharArray(); > ctx = SSLContext.getInstance("TLS"); > kmf = KeyManagerFactory.getInstance("SunX509"); > ks = KeyStore.getInstance("PKCS12"); > File keyFile = new File(keyfile); > if (keyFile.canRead()) { > ks.load(new FileInputStream(keyFile), passphrase); > System.out.println("Key file loaded..."); > kmf.init(ks, passphrase); > ctx.init(kmf.getKeyManagers(), null, null); > factory = ctx.getSocketFactory(); > } ********************************************************************* Here is my implementation of python code: ############################ > ctx = SSL.Context(SSL.TLSv1_METHOD) > # ctx.set_verify(SSL.VERIFY_PEER, verify_cb) > > #Get X509 certificate and the private key from the > #initial .p12 file provided to network client > f = open(pkey) > > pkcs12Obj = crypto.load_pkcs12(f.read(), passPhrase) > x509Obj = pkcs12Obj.get_certificate() > pkeyObj = pkcs12Obj.get_privatekey() > > ctx.use_privatekey(pkeyObj) > ctx.use_certificate(x509Obj) > > self.sock = SSL.Connection(ctx, socket.socket(socket.AF_INET, > socket.SOCK_STREAM)) > ################################################### But, the code doesn't seem to work. Apparently it can connect, and do the handshake w/o raising any interrupt, but, it is unable to gain any response from the server. However, on similar conditions, the java code does get response. Any thing I am missing/ any suggestions? Thanks Regards Manish -------------- next part -------------- An HTML attachment was scrubbed... URL: