--- src/tools/pkcs11-tool.c 2008-12-27 17:15:30.000000000 +0100 +++ src/tools/pkcs11-tool.c.oden 2009-05-10 12:57:53.000000000 +0200 @@ -1036,7 +1036,7 @@ static int gen_keypair(CK_SLOT_ID slot, { CK_MECHANISM mechanism = {CKM_RSA_PKCS_KEY_PAIR_GEN, NULL_PTR, 0}; CK_ULONG modulusBits = 1024; - CK_BYTE publicExponent[] = { 65537 }; + CK_BYTE publicExponent[] = { 0x01, 0x00, 0x01 }; /* 65537 in bytes */ CK_BBOOL _true = TRUE; CK_OBJECT_CLASS pubkey_class = CKO_PUBLIC_KEY; CK_OBJECT_CLASS privkey_class = CKO_PRIVATE_KEY;