static unsigned minbits = 128, maxbits = UINT_MAX; /* Acceptable entropy */
static unsigned count = 1; /* How many passphrases to make */
-static const char wchars[] = "abcdefghijklmnopqrstuvwxyz'";
+static const char
+ all_wchars[] = "'abcdefghijklmnopqrstuvwxyz",
+ *wchars = all_wchars;
typedef struct ppgen_ops {
const char *name; /* Name of the generator */
{ "help", 0, 0, 'h' },
{ "version", 0, 0, 'v' },
{ "usage", 0, 0, 'u' },
+ { "no-apostrophe", 0, 0, 'A' },
{ "bits", OPTF_ARGREQ, 0, 'b' },
{ "generator", OPTF_ARGREQ, 0, 'g' },
{ "count", OPTF_ARGREQ, 0, 'n' },
{ "range", OPTF_ARGREQ, 0, 'r' },
{ 0, 0, 0, 0 }
};
- int i = mdwopt(argc, argv, "hvu b:g:n:pr:", opts, 0, 0, 0);
+ int i = mdwopt(argc, argv, "hvu Ab:g:n:pr:", opts, 0, 0, 0);
if (i < 0)
break;
case 'u':
usage(stdout);
exit(0);
+ case 'A':
+ wchars = all_wchars + 1;
+ break;
case 'b': {
char *p;
minbits = strtoul(optarg, &p, 0);