[BACK]Return to rand.c CVS log [TXT][DIR] Up to [local] / src / usr.bin / openssl

Diff for /src/usr.bin/openssl/rand.c between version 1.7 and 1.8

version 1.7, 2015/08/22 16:36:05 version 1.8, 2015/09/11 14:30:23
Line 64 
Line 64 
   
 struct {  struct {
         int base64;          int base64;
         char *engine;  
         int hex;          int hex;
         char *outfile;          char *outfile;
 } rand_config;  } rand_config;
Line 76 
Line 75 
                 .type = OPTION_FLAG,                  .type = OPTION_FLAG,
                 .opt.flag = &rand_config.base64,                  .opt.flag = &rand_config.base64,
         },          },
 #ifndef OPENSSL_NO_ENGINE  
         {          {
                 .name = "engine",  
                 .argname = "id",  
                 .desc = "Use the engine specified by the given identifier",  
                 .type = OPTION_ARG,  
                 .opt.arg = &rand_config.engine,  
         },  
 #endif  
         {  
                 .name = "hex",                  .name = "hex",
                 .desc = "Hexadecimal output",                  .desc = "Hexadecimal output",
                 .type = OPTION_FLAG,                  .type = OPTION_FLAG,
Line 105 
Line 95 
 rand_usage()  rand_usage()
 {  {
         fprintf(stderr,          fprintf(stderr,
             "usage: rand [-base64 | -hex] [-engine id] [-out file] num\n");              "usage: rand [-base64 | -hex] [-out file] num\n");
         options_usage(rand_options);          options_usage(rand_options);
 }  }
   
Line 140 
Line 130 
                 rand_usage();                  rand_usage();
                 goto err;                  goto err;
         }          }
   
 #ifndef OPENSSL_NO_ENGINE  
         setup_engine(bio_err, rand_config.engine, 0);  
 #endif  
   
         out = BIO_new(BIO_s_file());          out = BIO_new(BIO_s_file());
         if (out == NULL)          if (out == NULL)

Legend:
Removed from v.1.7  
changed lines
  Added in v.1.8