Details

    • Type: Improvement
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 1.6.11
    • Component/s: Build-System
    • Security Level: public
    • Labels:
      None
    • Environment:
      BSDs, Solaris, and derivatives
    • CPU Architecture:
      SPARC
    • Kernel:
      Solaris
    • Userland:
      Solaris
    • Distribution:
      Solaris
    • Compiler:
      gcc
    • FreeSWITCH GIT Revision:
      160e8f12c09394a288b88a682bdafe5df6ebda7d
    • GIT Master Revision hash::
      160e8f12c09394a288b88a682bdafe5df6ebda7d
    • Target Version:

      Description

      Solaris, FreeBSD, NetBSD and OpenBSD include system MD5 functions. Specifically the Solaris implementations are highly optimized on SPARC platforms.

      FreeBSD has these in libmd, Solaris in libmd5, and they are in libc on OpenBSD and NetBSD all with compatible prototypes in md5.h

      1. md5_test.c
        1 kB
        Spencer Thomason

        Activity

        Hide
        sjthomason Spencer Thomason added a comment -
        Hey Mike,
        I wrote a simple test program to compare APR/system/openssl MD5 implementations and the results are below.

        $ time ./system-md5-test test.domain.com
        Input: test.domain.com
        output: 382072648d247f830cc7c4bfae579a45

        real 0m1.263s
        user 0m1.253s
        sys 0m0.009s

        $ time ./apache-md5-test test.domain.com
        Input: test.domain.com
        output: 382072648d247f830cc7c4bfae579a45

        real 0m6.171s
        user 0m6.162s
        sys 0m0.009s

        $ time ./openssl-md5-test test.domain.com
        Input: test.domain.com
        output: 382072648d247f830cc7c4bfae579a45

        real 0m1.408s
        user 0m1.398s
        sys 0m0.009s
        Show
        sjthomason Spencer Thomason added a comment - Hey Mike, I wrote a simple test program to compare APR/system/openssl MD5 implementations and the results are below. $ time ./system-md5-test test.domain.com Input: test.domain.com output: 382072648d247f830cc7c4bfae579a45 real 0m1.263s user 0m1.253s sys 0m0.009s $ time ./apache-md5-test test.domain.com Input: test.domain.com output: 382072648d247f830cc7c4bfae579a45 real 0m6.171s user 0m6.162s sys 0m0.009s $ time ./openssl-md5-test test.domain.com Input: test.domain.com output: 382072648d247f830cc7c4bfae579a45 real 0m1.408s user 0m1.398s sys 0m0.009s
        Hide
        mikej Mike Jerris added a comment -
        do we do md5 enough in the code for this to even make a performance difference? maybe just switch it to use OpenSSL md5 and call it a day?
        Show
        mikej Mike Jerris added a comment - do we do md5 enough in the code for this to even make a performance difference? maybe just switch it to use OpenSSL md5 and call it a day?
        Hide
        sjthomason Spencer Thomason added a comment -
        Your are right.. this is a little excessive lol. If you are ok with the PR, there are autoconf checks to determine the best one for each platform. I've tested on Linux and Solaris and we're running it in production on Solaris, but granted I agree that in 2016, md5 hashes aren't a bottleneck.
        Show
        sjthomason Spencer Thomason added a comment - Your are right.. this is a little excessive lol. If you are ok with the PR, there are autoconf checks to determine the best one for each platform. I've tested on Linux and Solaris and we're running it in production on Solaris, but granted I agree that in 2016, md5 hashes aren't a bottleneck.

          People

          • Assignee:
            mikej Mike Jerris
            Reporter:
            sjthomason Spencer Thomason
          • Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development