mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-11-24 12:23:32 +01:00
Merge remote-tracking branch 'tor-gitlab/mr/248'
This commit is contained in:
commit
dbbd603313
5
changes/bug40235
Normal file
5
changes/bug40235
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
o Minor bugfixes (key generation):
|
||||||
|
- Do not require a valid torrc when using the `--keygen` argument
|
||||||
|
to generate a signing key. This allows us to generate keys on
|
||||||
|
systems or users which may not run Tor. Fixes bug 40235; bugfix
|
||||||
|
on 0.2.7.2-alpha. Patch by Neel Chauhan.
|
@ -4321,6 +4321,7 @@ find_torrc_filename(const config_line_t *cmd_arg,
|
|||||||
const config_line_t *p_index;
|
const config_line_t *p_index;
|
||||||
const char *fname_opt = defaults_file ? "--defaults-torrc" : "-f";
|
const char *fname_opt = defaults_file ? "--defaults-torrc" : "-f";
|
||||||
const char *ignore_opt = defaults_file ? NULL : "--ignore-missing-torrc";
|
const char *ignore_opt = defaults_file ? NULL : "--ignore-missing-torrc";
|
||||||
|
const char *keygen_opt = "--keygen";
|
||||||
|
|
||||||
if (defaults_file)
|
if (defaults_file)
|
||||||
*ignore_missing_torrc = 1;
|
*ignore_missing_torrc = 1;
|
||||||
@ -4342,7 +4343,8 @@ find_torrc_filename(const config_line_t *cmd_arg,
|
|||||||
}
|
}
|
||||||
|
|
||||||
*using_default_fname = 0;
|
*using_default_fname = 0;
|
||||||
} else if (ignore_opt && !strcmp(p_index->key,ignore_opt)) {
|
} else if ((ignore_opt && !strcmp(p_index->key, ignore_opt)) ||
|
||||||
|
(keygen_opt && !strcmp(p_index->key, keygen_opt))) {
|
||||||
*ignore_missing_torrc = 1;
|
*ignore_missing_torrc = 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user