failed to generate key using window.crypto.generateCRMFRequest() method

2009-05-13 Thread Subrata Mazumdar
Hi, I am not able generate key using window.crypto.generateCRMFRequest() method. I have tried all there possible types : rsa, dsa, and ec. I am attached my test code fragment. I am running the test within an add-on - on Firefox 3.0.10/Fedora8. I am getting NS_ERROR_FAILURE in exception

Re: failed to generate key using window.crypto.generateCRMFRequest() method

2009-05-13 Thread Subrata Mazumdar
On further testing and reading the description of generateCRMFRequest() method doc, I figured out why the key generation was failing. I have to pass keySize as integer type not string type. function testKeyGeneration() { doGenerateCRMFCSRByCryptoTest(cn=xxx,o=abc.com, rsa', parseInt(1024));

Re: failed to generate key using window.crypto.generateCRMFRequest() method

2009-05-13 Thread David Stutzman
Subrata Mazumdar wrote: On further testing and reading the description of generateCRMFRequest() method doc, I figured out why the key generation was failing. I have to pass keySize as integer type not string type. The key genartion now works for RSA and DSA key types but it still fails for

Re: failed to generate key using window.crypto.generateCRMFRequest() method

2009-05-13 Thread Georgi Guninski
On Wed, May 13, 2009 at 08:16:39AM -0400, Subrata Mazumdar wrote: Hi, I am not able generate key using window.crypto.generateCRMFRequest() check: https://developer.mozilla.org/En/JavaScript_crypto/GenerateCRMFRequest this works for me: m=crypto.generateCRMFRequest(CN=vvv, regToken, null,

Re: failed to generate key using window.crypto.generateCRMFRequest() method

2009-05-13 Thread Subrata Mazumdar
Thanks David. For EC, if no curve name is given then the type of keysize is used to pick either P-256 or P-384 curve. I tried with and without curve name - it fails both cases. I also looked into the source code (.../security/manager/ssl/src/nsCrypto.cpp) of PSM for FF3. The support for EC

Re: naive groebner basis preimage attack on md5

2009-05-13 Thread Robert Relyea
Georgi Guninski wrote: spent some time on this. i tried algebraic preimage attack on md5 - working in $GF(2)[x0 .. x_i]$ and using groebner basis with arguments that avoid crashes. to my surprise i got unexpected correct *partial* results that pass the insanity check. You'll probably have

Re: NSPR assertion failure

2009-05-13 Thread ksreedhar74
Hi Wan-Teh, Before I try to get the stack track using gdb on the core file, as I made it to crash with your suggested change, Java crashed with this error. Actually it also stack trace. Can you see anything from it. I appreciate your help. This is a must fix for us. # # An unexpected error has

Re: NSPR assertion failure

2009-05-13 Thread Glen Beasley
hi, Looking at the bottom of this stack trace: J java.lang.ref.Finalizer.invokeFinalizeMethod(Ljava/lang/Object;)V J java.lang.ref.Finalizer.runFinalizer()V J java.lang.ref.Finalizer$FinalizerThread.run()V Called by the garbage collector on an object when garbage collection determines

Re: failed to generate key using window.crypto.generateCRMFRequest() method

2009-05-13 Thread Nelson B Bolyard
Subrata Mazumdar wrote, On 2009-05-13 06:45 PDT: The key genartion now works for RSA and DSA key types but it still fails for EC key type. else if (keyType == dsa) { keyGenAlg = dsa-sign-nonrepudiation; keyParams = null; } That's strange. Your DSA test code should

Re: NSPR assertion failure

2009-05-13 Thread Glen Beasley
Glen Beasley wrote: hi, Looking at the bottom of this stack trace: J java.lang.ref.Finalizer.invokeFinalizeMethod(Ljava/lang/Object;)V J java.lang.ref.Finalizer.runFinalizer()V J java.lang.ref.Finalizer$FinalizerThread.run()V Called by the garbage collector on an object when garbage

Re: Pending roots and EV enablements

2009-05-13 Thread Gervase Markham
On 11/05/09 20:32, Nelson B Bolyard wrote: Ideally, one could tell Tryserver to Take Firefox source from the current branch for FF 3.0.x or FF 3.5 (from CVS or Hg, as appropriate), plus NSS from CVS tag X, plus this small patch, and build it, but presently that does not seem possible. Your

Re: Pending roots and EV enablements

2009-05-13 Thread Nelson B Bolyard
Gervase Markham wrote, On 2009-05-13 14:46: On 11/05/09 20:32, Nelson B Bolyard wrote: Ideally, one could tell Tryserver to Take Firefox source from the current branch for FF 3.0.x or FF 3.5 (from CVS or Hg, as appropriate), plus NSS from CVS tag X, plus this small patch, and build it, but

Re: failed to generate key using window.crypto.generateCRMFRequest() method

2009-05-13 Thread Subrata Mazumdar
Nelson B Bolyard wrote: Subrata Mazumdar wrote, On 2009-05-13 06:45 PDT: The key genartion now works for RSA and DSA key types but it still fails for EC key type. else if (keyType == dsa) { keyGenAlg = dsa-sign-nonrepudiation; keyParams = null; } According to

Finding certificate extension using Object Identifier

2009-05-13 Thread Gaurav Aggarwal
Hi, I was trying to find a custom extension using its object identifier (in decimal) : 1, 3, 6, 1, 5, 5, 7, 1, 100. It seems to me that only CERT_FindCertExtension() function is public. But it takes an integer tag that gets mapped to the actual object identifier. Does it mean that i would

Re: failed to generate key using window.crypto.generateCRMFRequest() method

2009-05-13 Thread Nelson B Bolyard
Subrata Mazumdar wrote, On 2009-05-13 17:58: Nelson B Bolyard wrote: That's strange. Your DSA test code should NOT have worked. I wonder how it could have worked, given that you supplied no params. According to the source code

Re: Finding certificate extension using Object Identifier

2009-05-13 Thread Nelson B Bolyard
Gaurav Aggarwal wrote, On 2009-05-13 20:07 PDT: I was trying to find a custom extension using its object identifier (in decimal) : 1, 3, 6, 1, 5, 5, 7, 1, 100. It seems to me that only CERT_FindCertExtension() function is public. If you would like to see CERT_FindCertExtensionByOID be

Re: failed to generate key using window.crypto.generateCRMFRequest() method

2009-05-13 Thread Kaspar Brand
Subrata Mazumdar wrote: As I have said in the earlier message, I have no problem in generating EC key-pair. I get error when I try to sign the request using the private key. Maybe you're falling prey to this bug? https://bugzilla.mozilla.org/show_bug.cgi?id=367577 Kaspar --