000019355 - Using RSA BSAFE SSL-C with an 'Microsoft Foundation Class' (MFC) Library

Document created by RSA Customer Support Employee on Jun 14, 2016Last modified by RSA Customer Support Employee on Apr 22, 2017
Version 2Show Document
  • View in full screen mode

Article Content

Article Number000019355
Applies ToRSA BSAFE SSL-C
Microsoft Foundation Class (MFC) Library
IssueUsing RSA BSAFE SSL-C with an "Microsoft Foundation Class" (MFC) Library
ResolutionWhen compiling SSL-C using MFC, there are two settings that are required to be made in the MSVC project:
1. On the "C/C++" tab, under "[Code Generation]" select "Multi-threaded DLL" or "Debug Multi-threaded DLL".  Depending on which of these you select, your application will require either the 'msvcrt' or 'msvcrtd' libraries - you should ensure that these are not explicitly ignored by your project settings.
2. Also on the "C/C++" tab, under "[Preprocessor]", the SSL-C preprocessor definitions must be included.  The SSL-C preprocessor definitions for your build of the SSL-C product can be seen by running the 'version' utility bundled in the 'sslc' application as such:

                c:\>sslc version -a
                VERSION: SSL-C 2.1.0 06-Mar-2001
                VERSION_NUMBER: 2100
                BUILT_ON: May 10 2001 07:27:08
                PLATFORM: vc-win32-nocrt
                BUILD_ID: 2_1_0-20010510
                ID: vc-win32-nocrt-2_1_0-20010510
                CFLAGS: /MT /W3 /WX /G6 /Ox /O2 /Gs /GF /GY /nologo -DWINDOWS -DNO_UNISTD_H -DWIN32 -DCPU_X86 -DFLAT_INC -DNO_RIPEMD                 -DNO_IDEA -DNO_WINCE -DNO_MC2 -NO_BF -DNO_PKCS7 -DNO_LIBCRL -DNO_RC5 -DNO_CAST -DNO_PALMOS -DMFUNC
                EVAL: 0
                OPTIONS: bn(32,w,ll,mc,sc) md2(int) rc4(i) des(idx,cisc,4,long)DES part of RCOM 1.1.0 06-Mar-2001

The required preprocessor definitions are shown in the CFLAGS line, and have the prefix '-D'.  In this example, the preprocessor definitions are:

                -DWINDOWS -DNO_UNISTD_H -DWIN32 -DCPU_X86 -DFLAT_INC -DNO_RIPEMD -DNO_IDEA -DNO_WINCE
                -DNO_MC2 -NO_BF -DNO_PKCS7 -DNO_LIBCRL -DNO_RC5 -DNO_CAST -DNO_PALMOS -DMFUNC

These preprocessor definitions must be copied and added to the "Preprocessor Definitions" textbox in your MSVC project.

Your MSVC project will now be able to use the RSA BSAFE SSL-C library successfully with MFC libraries now.
Legacy Article IDa8586

Attachments

    Outcomes