mirror of
git://anongit.mindrot.org/openssh.git
synced 2025-01-03 16:22:05 +00:00
- (dtucker) [contrib/cygwin/ssh-host-config] Simplify host key generation:
rather than testing and generating each key, call ssh-keygen -A. Patch from vinschen at redhat.com.
This commit is contained in:
parent
882abfd3fb
commit
aff7ef1bb8
@ -27,8 +27,11 @@
|
|||||||
- (dtucker) [openbsd-compat/bsd-poll.c] Add headers to prevent compile
|
- (dtucker) [openbsd-compat/bsd-poll.c] Add headers to prevent compile
|
||||||
warnings.
|
warnings.
|
||||||
- (dtucker) [Makefile.in configure.ac] Set MALLOC_OPTIONS per platform
|
- (dtucker) [Makefile.in configure.ac] Set MALLOC_OPTIONS per platform
|
||||||
and pass in TEST_ENV. Unknown options cause stderr to get polluted
|
and pass in TEST_ENV. use stderr to get polluted
|
||||||
and the stderr-data test to fail.
|
and the stderr-data test to fail.
|
||||||
|
- (dtucker) [contrib/cygwin/ssh-host-config] Simplify host key generation:
|
||||||
|
rather than testing and generating each key, call ssh-keygen -A.
|
||||||
|
Patch from vinschen at redhat.com.
|
||||||
|
|
||||||
20131107
|
20131107
|
||||||
- (djm) [ssh-pkcs11.c] Bring back "non-constant initialiser" fix (rev 1.5)
|
- (djm) [ssh-pkcs11.c] Bring back "non-constant initialiser" fix (rev 1.5)
|
||||||
|
@ -67,54 +67,6 @@ user_account=
|
|||||||
password_value=
|
password_value=
|
||||||
opt_force=no
|
opt_force=no
|
||||||
|
|
||||||
# ======================================================================
|
|
||||||
# Routine: create_host_keys
|
|
||||||
# ======================================================================
|
|
||||||
create_host_keys() {
|
|
||||||
local ret=0
|
|
||||||
|
|
||||||
if [ ! -f "${SYSCONFDIR}/ssh_host_key" ]
|
|
||||||
then
|
|
||||||
csih_inform "Generating ${SYSCONFDIR}/ssh_host_key"
|
|
||||||
if ! /usr/bin/ssh-keygen -t rsa1 -f ${SYSCONFDIR}/ssh_host_key -N '' > /dev/null
|
|
||||||
then
|
|
||||||
csih_warning "Generating ${SYSCONFDIR}/ssh_host_key failed!"
|
|
||||||
let ++ret
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [ ! -f "${SYSCONFDIR}/ssh_host_rsa_key" ]
|
|
||||||
then
|
|
||||||
csih_inform "Generating ${SYSCONFDIR}/ssh_host_rsa_key"
|
|
||||||
if ! /usr/bin/ssh-keygen -t rsa -f ${SYSCONFDIR}/ssh_host_rsa_key -N '' > /dev/null
|
|
||||||
then
|
|
||||||
csih_warning "Generating ${SYSCONFDIR}/ssh_host_key failed!"
|
|
||||||
let ++ret
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [ ! -f "${SYSCONFDIR}/ssh_host_dsa_key" ]
|
|
||||||
then
|
|
||||||
csih_inform "Generating ${SYSCONFDIR}/ssh_host_dsa_key"
|
|
||||||
if ! /usr/bin/ssh-keygen -t dsa -f ${SYSCONFDIR}/ssh_host_dsa_key -N '' > /dev/null
|
|
||||||
then
|
|
||||||
csih_warning "Generating ${SYSCONFDIR}/ssh_host_key failed!"
|
|
||||||
let ++ret
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [ ! -f "${SYSCONFDIR}/ssh_host_ecdsa_key" ]
|
|
||||||
then
|
|
||||||
csih_inform "Generating ${SYSCONFDIR}/ssh_host_ecdsa_key"
|
|
||||||
if ! /usr/bin/ssh-keygen -t ecdsa -f ${SYSCONFDIR}/ssh_host_ecdsa_key -N '' > /dev/null
|
|
||||||
then
|
|
||||||
csih_warning "Generating ${SYSCONFDIR}/ssh_host_key failed!"
|
|
||||||
let ++ret
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
return $ret
|
|
||||||
} # --- End of create_host_keys --- #
|
|
||||||
|
|
||||||
# ======================================================================
|
# ======================================================================
|
||||||
# Routine: update_services_file
|
# Routine: update_services_file
|
||||||
# ======================================================================
|
# ======================================================================
|
||||||
@ -719,8 +671,8 @@ then
|
|||||||
let ++warning_cnt
|
let ++warning_cnt
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# host keys
|
# generate missing host keys
|
||||||
create_host_keys || let warning_cnt+=$?
|
/usr/bin/ssh-keygen -A || let warning_cnt+=$?
|
||||||
|
|
||||||
# handle ssh_config
|
# handle ssh_config
|
||||||
csih_install_config "${SYSCONFDIR}/ssh_config" "${SYSCONFDIR}/defaults" || let ++warning_cnt
|
csih_install_config "${SYSCONFDIR}/ssh_config" "${SYSCONFDIR}/defaults" || let ++warning_cnt
|
||||||
|
Loading…
Reference in New Issue
Block a user