diff --git a/README.md b/README.md index 198c7cf..ac3655a 100644 --- a/README.md +++ b/README.md @@ -3,7 +3,7 @@ This tool generates vanity ed25519 ([hidden service version 3][v3], formely known as proposal 224) onion addresses. -### Requirements +### Requirements for building * C99 compatible compiler (gcc and clang should work) * libsodium (including headers) @@ -20,23 +20,26 @@ apt install gcc libc6-dev libsodium-dev make autoconf ### Building -`./autogen.sh` to generate configure script, if it's not there already. +Run `./autogen.sh` to generate a configure script, if there isn't one already. -`./configure` to generate makefile; in \*BSD platforms you probably want to use +Run `./configure` to generate a makefile. +On \*BSD platforms you may need to specify extra include/library paths: `./configure CPPFLAGS="-I/usr/local/include" LDFLAGS="-L/usr/local/lib"`. On AMD64 platforms, you probably also want to pass something like -`--enable-amd64-51-30k` to configure script for faster key generation; +`--enable-amd64-51-30k` to the configure script invocation for faster key generation; run `./configure --help` to see all available options. Finally, `make` to start building (`gmake` in \*BSD platforms). ### Usage -Generator needs one or more filters to work. +mkp224o needs one or more filters to work. +You may specify them as command line arguments, +eg `./mkp224o test`, or load them from file with `-f` switch. -It makes directory with secret/public keys and hostname -for each discovered service. By default root is current +It makes directories with secret/public keys and hostnames +for each discovered service. By default, the working directory is the current directory, but that can be overridden with `-d` switch. Use `-s` switch to enable printing of statistics, which may be useful diff --git a/ed25519/amd64-51-30k/consts.S b/ed25519/amd64-51-30k/consts.S index b2ca1ab..5713447 100644 --- a/ed25519/amd64-51-30k/consts.S +++ b/ed25519/amd64-51-30k/consts.S @@ -1,4 +1,8 @@ +#ifndef __APPLE__ .section .rodata +#else +.const +#endif .globl CRYPTO_NAMESPACE(batch_REDMASK51) .globl CRYPTO_NAMESPACE(batch_121666_213) diff --git a/ed25519/amd64-64-24k/consts.S b/ed25519/amd64-64-24k/consts.S index ca9896f..db6bad5 100644 --- a/ed25519/amd64-64-24k/consts.S +++ b/ed25519/amd64-64-24k/consts.S @@ -1,4 +1,8 @@ +#ifndef __APPLE__ .section .rodata +#else +.const +#endif .globl CRYPTO_NAMESPACE(121666) .globl CRYPTO_NAMESPACE(MU0) diff --git a/main.c b/main.c index b244519..b4e447f 100644 --- a/main.c +++ b/main.c @@ -223,7 +223,7 @@ static void savecheckpoint(void) if (syncwrite(checkpointfile,1,checkpoint,SEED_LEN) < 0) { pthread_mutex_lock(&fout_mutex); - fprintf(stderr,"ERROR: could not save checkpoint\n"); + fprintf(stderr,"ERROR: could not save checkpoint to \"%s\"\n",checkpointfile); pthread_mutex_unlock(&fout_mutex); } } diff --git a/worker.c b/worker.c index 2db6ab8..9958be2 100644 --- a/worker.c +++ b/worker.c @@ -103,7 +103,7 @@ static void onionready(char *sname,const u8 *secret,const u8 *pubonion) if (!yamloutput) { if (createdir(sname,1) != 0) { pthread_mutex_lock(&fout_mutex); - fprintf(stderr,"ERROR: could not create directory for key output\n"); + fprintf(stderr,"ERROR: could not create directory \"%s\" for key output\n",sname); pthread_mutex_unlock(&fout_mutex); return; } diff --git a/yaml.c b/yaml.c index c8778a6..56bd10e 100644 --- a/yaml.c +++ b/yaml.c @@ -274,7 +274,7 @@ int yamlin_parseandcreate( sigprocmask(SIG_BLOCK,&nset,&oset); #endif if (createdir(sname,1) != 0) { - fprintf(stderr,"ERROR: could not create directory for key output\n"); + fprintf(stderr,"ERROR: could not create directory \"%s\" for key output\n",sname); return 1; }