version 1.84, 2001/06/23 15:12:19 |
version 1.85, 2001/06/26 16:15:24 |
|
|
#ifdef KRB4 |
#ifdef KRB4 |
#include <krb.h> |
#include <krb.h> |
#endif |
#endif |
#ifdef AFS |
|
#include <kafs.h> |
|
#endif |
|
|
|
#include "ssh.h" |
#include "ssh.h" |
#include "log.h" |
#include "log.h" |
|
|
options->hostbased_uses_name_from_packet_only = -1; |
options->hostbased_uses_name_from_packet_only = -1; |
options->rsa_authentication = -1; |
options->rsa_authentication = -1; |
options->pubkey_authentication = -1; |
options->pubkey_authentication = -1; |
#ifdef KRB4 |
#if defined(KRB4) || defined(KRB5) |
options->kerberos_authentication = -1; |
options->kerberos_authentication = -1; |
options->kerberos_or_local_passwd = -1; |
options->kerberos_or_local_passwd = -1; |
options->kerberos_ticket_cleanup = -1; |
options->kerberos_ticket_cleanup = -1; |
#endif |
#endif |
#ifdef AFS |
#if defined(AFS) || defined(KRB5) |
options->kerberos_tgt_passing = -1; |
options->kerberos_tgt_passing = -1; |
|
#endif |
|
#ifdef AFS |
options->afs_token_passing = -1; |
options->afs_token_passing = -1; |
#endif |
#endif |
options->password_authentication = -1; |
options->password_authentication = -1; |
|
|
options->rsa_authentication = 1; |
options->rsa_authentication = 1; |
if (options->pubkey_authentication == -1) |
if (options->pubkey_authentication == -1) |
options->pubkey_authentication = 1; |
options->pubkey_authentication = 1; |
#ifdef KRB4 |
#if defined(KRB4) || defined(KRB5) |
if (options->kerberos_authentication == -1) |
if (options->kerberos_authentication == -1) |
options->kerberos_authentication = (access(KEYFILE, R_OK) == 0); |
options->kerberos_authentication = (access(KEYFILE, R_OK) == 0); |
if (options->kerberos_or_local_passwd == -1) |
if (options->kerberos_or_local_passwd == -1) |
options->kerberos_or_local_passwd = 1; |
options->kerberos_or_local_passwd = 1; |
if (options->kerberos_ticket_cleanup == -1) |
if (options->kerberos_ticket_cleanup == -1) |
options->kerberos_ticket_cleanup = 1; |
options->kerberos_ticket_cleanup = 1; |
#endif /* KRB4 */ |
#endif |
#ifdef AFS |
#if defined(AFS) || defined(KRB5) |
if (options->kerberos_tgt_passing == -1) |
if (options->kerberos_tgt_passing == -1) |
options->kerberos_tgt_passing = 0; |
options->kerberos_tgt_passing = 0; |
|
#endif |
|
#ifdef AFS |
if (options->afs_token_passing == -1) |
if (options->afs_token_passing == -1) |
options->afs_token_passing = k_hasafs(); |
options->afs_token_passing = k_hasafs(); |
#endif /* AFS */ |
#endif |
if (options->password_authentication == -1) |
if (options->password_authentication == -1) |
options->password_authentication = 1; |
options->password_authentication = 1; |
if (options->kbd_interactive_authentication == -1) |
if (options->kbd_interactive_authentication == -1) |
|
|
sPort, sHostKeyFile, sServerKeyBits, sLoginGraceTime, sKeyRegenerationTime, |
sPort, sHostKeyFile, sServerKeyBits, sLoginGraceTime, sKeyRegenerationTime, |
sPermitRootLogin, sLogFacility, sLogLevel, |
sPermitRootLogin, sLogFacility, sLogLevel, |
sRhostsAuthentication, sRhostsRSAAuthentication, sRSAAuthentication, |
sRhostsAuthentication, sRhostsRSAAuthentication, sRSAAuthentication, |
#ifdef KRB4 |
#if defined(KRB4) || defined(KRB5) |
sKerberosAuthentication, sKerberosOrLocalPasswd, sKerberosTicketCleanup, |
sKerberosAuthentication, sKerberosOrLocalPasswd, sKerberosTicketCleanup, |
#endif |
#endif |
|
#if defined(AFS) || defined(KRB5) |
|
sKerberosTgtPassing, |
|
#endif |
#ifdef AFS |
#ifdef AFS |
sKerberosTgtPassing, sAFSTokenPassing, |
sAFSTokenPassing, |
#endif |
#endif |
sChallengeResponseAuthentication, |
sChallengeResponseAuthentication, |
sPasswordAuthentication, sKbdInteractiveAuthentication, sListenAddress, |
sPasswordAuthentication, sKbdInteractiveAuthentication, sListenAddress, |
|
|
{ "rsaauthentication", sRSAAuthentication }, |
{ "rsaauthentication", sRSAAuthentication }, |
{ "pubkeyauthentication", sPubkeyAuthentication }, |
{ "pubkeyauthentication", sPubkeyAuthentication }, |
{ "dsaauthentication", sPubkeyAuthentication }, /* alias */ |
{ "dsaauthentication", sPubkeyAuthentication }, /* alias */ |
#ifdef KRB4 |
#if defined(KRB4) || defined(KRB5) |
{ "kerberosauthentication", sKerberosAuthentication }, |
{ "kerberosauthentication", sKerberosAuthentication }, |
{ "kerberosorlocalpasswd", sKerberosOrLocalPasswd }, |
{ "kerberosorlocalpasswd", sKerberosOrLocalPasswd }, |
{ "kerberosticketcleanup", sKerberosTicketCleanup }, |
{ "kerberosticketcleanup", sKerberosTicketCleanup }, |
#endif |
#endif |
#ifdef AFS |
#if defined(AFS) || defined(KRB5) |
{ "kerberostgtpassing", sKerberosTgtPassing }, |
{ "kerberostgtpassing", sKerberosTgtPassing }, |
|
#endif |
|
#ifdef AFS |
{ "afstokenpassing", sAFSTokenPassing }, |
{ "afstokenpassing", sAFSTokenPassing }, |
#endif |
#endif |
{ "passwordauthentication", sPasswordAuthentication }, |
{ "passwordauthentication", sPasswordAuthentication }, |
|
|
case sPubkeyAuthentication: |
case sPubkeyAuthentication: |
intptr = &options->pubkey_authentication; |
intptr = &options->pubkey_authentication; |
goto parse_flag; |
goto parse_flag; |
|
#if defined(KRB4) || defined(KRB5) |
#ifdef KRB4 |
|
case sKerberosAuthentication: |
case sKerberosAuthentication: |
intptr = &options->kerberos_authentication; |
intptr = &options->kerberos_authentication; |
goto parse_flag; |
goto parse_flag; |
|
|
intptr = &options->kerberos_ticket_cleanup; |
intptr = &options->kerberos_ticket_cleanup; |
goto parse_flag; |
goto parse_flag; |
#endif |
#endif |
|
#if defined(AFS) || defined(KRB5) |
#ifdef AFS |
|
case sKerberosTgtPassing: |
case sKerberosTgtPassing: |
intptr = &options->kerberos_tgt_passing; |
intptr = &options->kerberos_tgt_passing; |
goto parse_flag; |
goto parse_flag; |
|
#endif |
|
#ifdef AFS |
case sAFSTokenPassing: |
case sAFSTokenPassing: |
intptr = &options->afs_token_passing; |
intptr = &options->afs_token_passing; |
goto parse_flag; |
goto parse_flag; |