Changeset 410

Show
Ignore:
Timestamp:
04/27/06 14:48:35
Author:
rachel
Message:

Various changes to allow codebase to compile:
- some char* casts to unsigned in function calls
- use #ifndef OPENSSL_NO_IDEA to hide IDEA-only code
- Remove create_signed_key from Examples/Makefile because of missing function
Refs #41

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • openpgpsdk/trunk/examples/Makefile.template

    r384 r410  
    77LIBDEPS=common.o ../src/libops.a 
    88LIBS=$(LIBDEPS) %CRYPTO_LIBS% %ZLIB% $(DM_LIB) %LIBS% 
    9 EXES=packet-dump verify create-key create-signed-key verify2 sign-detached \ 
     9EXES=packet-dump verify create-key verify2 sign-detached \ 
    1010     sign-inline decrypt 
     11# create-signed-key  
    1112 
    1213all: Makefile .depend $(EXES) 
  • openpgpsdk/trunk/examples/packet-dump.c

    r397 r410  
    188188    { 
    189189    print_name(name); 
    190     print_escaped(str,strlen(str)); 
     190    print_escaped((unsigned char *)str,strlen(str)); 
    191191    putchar('\n'); 
    192192    } 
  • openpgpsdk/trunk/src/packet-parse.c

    r404 r410  
    19931993            // preload hashes with zeroes... 
    19941994            for(i=0 ; i < n ; ++i) 
    1995                 hashes[n].add(&hashes[n],"",1); 
     1995                hashes[n].add(&hashes[n],(unsigned char *)"",1); 
    19961996            } 
    19971997 
     
    20082008                // flow through... 
    20092009            case OPS_S2KS_SIMPLE: 
    2010                 hashes[n].add(&hashes[n],passphrase,l); 
     2010                hashes[n].add(&hashes[n],(unsigned char*)passphrase,l); 
    20112011                break; 
    20122012 
     
    20222022                                  j > OPS_SALT_SIZE ? OPS_SALT_SIZE : j); 
    20232023                    if(j > OPS_SALT_SIZE) 
    2024                         hashes[n].add(&hashes[n],passphrase,j-OPS_SALT_SIZE); 
     2024                        hashes[n].add(&hashes[n],(unsigned char *)passphrase,j-OPS_SALT_SIZE); 
    20252025                    } 
    20262026                         
  • openpgpsdk/trunk/src/symmetric.c

    r409 r410  
    33#include <assert.h> 
    44#include <openssl/cast.h> 
    5 #ifdef OPENSSL_IDEA 
     5#ifndef OPENSSL_NO_IDEA 
    66#include <openssl/idea.h> 
    77#endif 
     
    185185    }; 
    186186 
     187#ifndef OPENSSL_NO_IDEA 
    187188static void idea_init(ops_decrypt_t *decrypt) 
    188189    { 
     
    212213    TRAILER 
    213214    }; 
     215#endif /* OPENSSL_NO_IDEA */ 
    214216 
    215217static void aes256_init(ops_decrypt_t *decrypt) 
     
    278280        return &cast5; 
    279281 
     282#ifndef OPENSSL_NO_IDEA 
    280283    case OPS_SA_IDEA: 
    281284        return &idea; 
     285#endif /* OPENSSL_NO_IDEA */ 
    282286 
    283287    case OPS_SA_AES_256: