On 5/24/2013 7:02 AM, Rahul Godbole wrote:

Hi,

Is there a way in which I get have all OpenSSL error messages being
printed in the syslog instead of console? Can I set some option or
something else in OpenSSL for that?

I am using OpenSSL 1.0.1c with fips 2.0.2.


If you are using the OpenSSL Libraries in your own code, you have
full control over the output of error messages, since your code will
get them as strings through various APIs.

If you are using the openssl command line tool, just pipe its stderr
(and stdout for some commands) to the logger(1) program.

For example:

$ ( ( openssl whatever -whatever 1>&3 ) 2>&1 |
    logger -p local4.err ) 3>&1

This redirects openssl stdout to temporary handle 3, then redirects
openssl stderr to stdout and pipes it to logger.  Finally the temporary
handle 3 is redirected back to stdout of the whole thing.

Another example:

$ openssl whatever -whatever 2>&1 | logger -p local4.info

This redirects both openssl stderr and stdout to stdout then pipes it
to logger which will pass it to syslog.

Enjoy

Jakob
--
Jakob Bohm, CIO, Partner, WiseMo A/S.  http://www.wisemo.com
Transformervej 29, 2730 Herlev, Denmark.  Direct +45 31 13 16 10
This public discussion message is non-binding and may contain errors.
WiseMo - Remote Service Management for PCs, Phones and Embedded
______________________________________________________________________
OpenSSL Project                                 http://www.openssl.org
User Support Mailing List                    [email protected]
Automated List Manager                           [email protected]

Reply via email to