Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 17 Sep 2008 10:06:51 +0200
From:      "Ian Freislich" <ianf@clue.co.za>
To:        current@freebsd.org
Subject:   PATCH: crypto/openssl/crypto/engine/eng_table.c
Message-ID:  <E1Kfs3n-0001CB-EC@clue.co.za>

next in thread | raw e-mail | index | archive | help
Hi

I had to apply the following patch to fix the engine cache in openssl
so that it will actually use the padlock driver for accelleration.
It appears that the original logic was reversed.

RCS file: /home/ncvs/src/crypto/openssl/crypto/engine/eng_table.c,v
retrieving revision 1.1.1.2
diff -u -d -r1.1.1.2 eng_table.c
--- eng_table.c 29 Jul 2006 19:10:18 -0000      1.1.1.2
+++ eng_table.c 12 Jun 2008 07:52:52 -0000
@@ -135,7 +135,7 @@
                        {
                        fnd = OPENSSL_malloc(sizeof(ENGINE_PILE));
                        if(!fnd) goto end;
-                       fnd->uptodate = 0;
+                       fnd->uptodate = 1;
                        fnd->nid = *nids;
                        fnd->sk = sk_ENGINE_new_null();
                        if(!fnd->sk)
@@ -152,7 +152,7 @@
                if(!sk_ENGINE_push(fnd->sk, e))
                        goto end;
                /* "touch" this ENGINE_PILE */
-               fnd->uptodate = 1;
+               fnd->uptodate = 0;
                if(setdefault)
                        {
                        if(!engine_unlocked_init(e))
@@ -180,7 +180,7 @@
                {
                sk_ENGINE_delete(pile->sk, n);
                /* "touch" this ENGINE_CIPHER */
-               pile->uptodate = 1;
+               pile->uptodate = 0;
                }
        if(pile->funct == e)
                {


--
Ian Freislich




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?E1Kfs3n-0001CB-EC>