Return-Path: Delivered-To: apmail-httpd-dev-archive@httpd.apache.org Received: (qmail 66382 invoked by uid 500); 6 Nov 2001 01:31:25 -0000 Mailing-List: contact dev-help@httpd.apache.org; run by ezmlm Precedence: bulk Reply-To: dev@httpd.apache.org list-help: list-unsubscribe: list-post: Delivered-To: mailing list dev@httpd.apache.org Received: (qmail 66371 invoked from network); 6 Nov 2001 01:31:25 -0000 Message-ID: From: "MATHIHALLI,MADHUSUDAN (HP-Cupertino,ex1)" To: "'dev@httpd.apache.org'" Subject: RE: ssl_var_lookup()... Date: Mon, 5 Nov 2001 17:31:25 -0800 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.2653.19) Content-Type: text/plain; charset="iso-8859-1" X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N That's true. ssl_var_lookup() is really bad in terms of performance (a hash table is probably better).. If you're looking out for only a couple of parameters, it's rather efficient to lookup those variables directly.. -Madhu -----Original Message----- From: Doug MacEachern [mailto:dougm@covalent.net] Sent: Monday, November 05, 2001 4:44 PM To: dev@httpd.apache.org Subject: Re: ssl_var_lookup()... On Mon, 5 Nov 2001, Bill Stoddard wrote: > I have a module that needs access to SSLCIPHER, SSL_CLIENT_CERT and SSL_SESSIONID. What is > the right way for a module to get at this info? I see a couple of methods: > > 1. Use SSL_* calls directly > > 2. Call ssl_var_lookup() > This call looks to be very inefficient. Full of string compares. And the call is not > exported for use on Windows either (which is easy enough to change). it is registered as an optional function. for an example see: httpd-test/perl-framework/c-modules/test_ssl/mod_test_ssl.c as for performance of ssl_var_lookup(), that certainly should be improved.