mirror of
https://github.com/curl/curl.git
synced 2024-11-27 05:50:21 +08:00
Abort if attempting to run as root.
This commit is contained in:
parent
3d5a8515a6
commit
f776c1d2eb
@ -76,6 +76,11 @@ if ($verbose) {
|
||||
print STDERR "SFTP server plugin found at $sftp\n";
|
||||
}
|
||||
|
||||
if ($username eq "root") {
|
||||
print "Will not run ssh daemon as root to mitigate security risks\n";
|
||||
exit 1;
|
||||
}
|
||||
|
||||
if (! -e "curl_client_key.pub") {
|
||||
if ($verbose) {
|
||||
print STDERR "Generating host and client keys...\n";
|
||||
|
Loading…
Reference in New Issue
Block a user