Lines Matching defs:options
156 /* Server configuration options. */
157 ServerOptions options;
253 /* options.max_startup sized array of fd ints */
300 for (i = 0; i < options.max_startups; i++)
405 sensitive_data.server_key ? "new " : "", options.server_key_bits);
409 options.server_key_bits);
437 if ((options.protocol & SSH_PROTO_1) &&
438 (options.protocol & SSH_PROTO_2)) {
441 } else if (options.protocol & SSH_PROTO_2) {
452 options.hpn_disabled ? "" : SSH_VERSION_HPN,
453 *options.version_addendum == '\0' ? "" : " ",
454 options.version_addendum, newline);
531 if (options.protocol & SSH_PROTO_2)
537 if (!(options.protocol & SSH_PROTO_1)) {
550 if (options.protocol & SSH_PROTO_2) {
584 for (i = 0; i < options.num_host_key_files; i++) {
611 for (i = 0; i < options.num_host_key_files; i++) {
636 if (options.gss_authentication)
745 if (authctxt->pw->pw_uid == 0 || options.use_login) {
804 for (i = 0; i < options.num_host_key_files; i++) {
852 for (i = 0; i < options.num_host_key_files; i++) {
890 if (ind < 0 || ind >= options.num_host_key_files)
898 if (ind < 0 || ind >= options.num_host_key_files)
908 for (i = 0; i < options.num_host_key_files; i++) {
933 if (startups < options.max_startups_begin)
935 if (startups >= options.max_startups)
937 if (options.max_startups_rate == 100)
940 p = 100 - options.max_startups_rate;
941 p *= startups - options.max_startups_begin;
942 p /= options.max_startups - options.max_startups_begin;
943 p += options.max_startups_rate;
953 if (options.version_addendum && *options.version_addendum != '\0')
955 SSH_RELEASE, options.hpn_disabled ? "" : SSH_VERSION_HPN,
956 options.version_addendum, SSLeay_version(SSLEAY_VERSION));
959 SSH_RELEASE, options.hpn_disabled ? "" : SSH_VERSION_HPN,
1107 for (ai = options.listen_addrs; ai; ai = ai->ai_next) {
1133 * Set socket options.
1149 debug("HPN Buffer Size: %d", options.hpn_buffer_size);
1167 freeaddrinfo(options.listen_addrs);
1196 startup_pipes = xcalloc(options.max_startups, sizeof(int));
1197 for (i = 0; i < options.max_startups; i++)
1214 for (i = 0; i < options.max_startups; i++)
1226 unlink(options.pid_file);
1237 for (i = 0; i < options.max_startups; i++)
1289 for (j = 0; j < options.max_startups; j++)
1346 options.log_level,
1347 options.log_facility,
1373 if ((options.protocol & SSH_PROTO_1) &&
1377 alarm(options.key_regeneration_time);
1448 /* Initialize configuration options to their default values. */
1449 initialize_server_options(&options);
1455 options.address_family = AF_INET;
1458 options.address_family = AF_INET6;
1464 if (options.num_host_cert_files >= MAX_HOSTCERTS) {
1468 options.host_cert_files[options.num_host_cert_files++] =
1474 options.log_level = SYSLOG_LEVEL_DEBUG1;
1475 } else if (options.log_level < SYSLOG_LEVEL_DEBUG3)
1476 options.log_level++;
1501 options.log_level = SYSLOG_LEVEL_QUIET;
1504 options.server_key_bits = (int)strtonum(optarg, 256,
1508 options.ports_from_cmdline = 1;
1509 if (options.num_ports >= MAX_PORTS) {
1513 options.ports[options.num_ports++] = a2port(optarg);
1514 if (options.ports[options.num_ports-1] <= 0) {
1520 if ((options.login_grace_time = convtime(optarg)) == -1) {
1526 if ((options.key_regeneration_time = convtime(optarg)) == -1) {
1532 if (options.num_host_key_files >= MAX_HOSTKEYS) {
1536 options.host_key_files[options.num_host_key_files++] =
1559 if (process_server_config_line(&options, line,
1591 options.log_level == SYSLOG_LEVEL_NOT_SET ?
1592 SYSLOG_LEVEL_INFO : options.log_level,
1593 options.log_facility == SYSLOG_FACILITY_NOT_SET ?
1594 SYSLOG_FACILITY_AUTH : options.log_facility,
1635 parse_server_config(&options, rexeced_flag ? "rexec" : config_file_name,
1640 /* Fill in default values for those options not explicitly set. */
1641 fill_default_server_options(&options);
1644 if (options.challenge_response_authentication)
1645 options.kbd_interactive_authentication = 1;
1647 /* Check that options are sensible */
1648 if (options.authorized_keys_command_user == NULL &&
1649 (options.authorized_keys_command != NULL &&
1650 strcasecmp(options.authorized_keys_command, "none") != 0))
1660 if (options.num_auth_methods != 0) {
1661 if ((options.protocol & SSH_PROTO_1))
1664 for (n = 0; n < options.num_auth_methods; n++) {
1665 if (auth2_methods_valid(options.auth_methods[n],
1669 if (n >= options.num_auth_methods)
1675 channel_set_af(options.address_family);
1685 options.hpn_disabled ? "" : SSH_VERSION_HPN,
1686 *options.version_addendum == '\0' ? "" : " ",
1687 options.version_addendum,
1692 if (use_privsep || options.kerberos_authentication)
1705 sensitive_data.host_keys = xcalloc(options.num_host_key_files,
1707 sensitive_data.host_pubkeys = xcalloc(options.num_host_key_files,
1709 for (i = 0; i < options.num_host_key_files; i++) {
1714 if (options.host_key_agent) {
1715 if (strcmp(options.host_key_agent, SSH_AUTHSOCKET_ENV_NAME))
1717 options.host_key_agent, 1);
1721 for (i = 0; i < options.num_host_key_files; i++) {
1722 key = key_load_private(options.host_key_files[i], "", NULL);
1723 pubkey = key_load_public(options.host_key_files[i], NULL);
1730 options.host_key_files[i]);
1736 options.host_key_files[i]);
1757 if ((options.protocol & SSH_PROTO_1) && !sensitive_data.have_ssh1_key) {
1759 options.protocol &= ~SSH_PROTO_1;
1761 if ((options.protocol & SSH_PROTO_2) && !sensitive_data.have_ssh2_key) {
1763 options.protocol &= ~SSH_PROTO_2;
1765 if (!(options.protocol & (SSH_PROTO_1|SSH_PROTO_2))) {
1774 sensitive_data.host_certificates = xcalloc(options.num_host_key_files,
1776 for (i = 0; i < options.num_host_key_files; i++)
1779 for (i = 0; i < options.num_host_cert_files; i++) {
1780 key = key_load_public(options.host_cert_files[i], NULL);
1783 options.host_cert_files[i]);
1788 options.host_cert_files[i]);
1793 for (j = 0; j < options.num_host_key_files; j++) {
1800 if (j >= options.num_host_key_files) {
1802 options.host_cert_files[i]);
1811 if (options.protocol & SSH_PROTO_1) {
1812 if (options.server_key_bits < 512 ||
1813 options.server_key_bits > 32768) {
1822 if (options.server_key_bits >
1824 SSH_KEY_BITS_RESERVED && options.server_key_bits <
1827 options.server_key_bits =
1831 options.server_key_bits);
1856 parse_server_match_config(&options, connection_info);
1857 dump_config(&options);
1891 log_init(__progname, options.log_level, options.log_facility, log_stderr);
1915 log_init(__progname, options.log_level, options.log_facility, log_stderr);
1936 if (options.protocol & SSH_PROTO_1)
1949 FILE *f = fopen(options.pid_file, "w");
1953 options.pid_file, strerror(errno));
2006 log_init(__progname, options.log_level,
2007 options.log_facility, log_stderr);
2044 if ((_res.options & RES_INIT) == 0) {
2070 if (options.tcp_keep_alive && packet_connection_is_on_socket() &&
2081 * get_remote_ipaddr here so IP options will be checked.
2095 allow_severity = options.log_facility|LOG_INFO;
2096 deny_severity = options.log_facility|LOG_WARNING;
2118 /* Set HPN options for the child. */
2119 channel_set_hpn(options.hpn_disabled, options.hpn_buffer_size);
2131 alarm(options.login_grace_time);
2195 if (options.gss_authentication) {
2202 if (options.use_pam) {
2219 packet_set_timeout(options.client_alive_interval,
2220 options.client_alive_count_max);
2234 if (options.use_pam)
2350 if (options.rhosts_rsa_authentication)
2352 if (options.rsa_authentication)
2354 if (options.challenge_response_authentication == 1)
2356 if (options.password_authentication)
2502 if (options.ciphers != NULL) {
2504 myproposal[PROPOSAL_ENC_ALGS_STOC] = options.ciphers;
2506 } else if (options.none_enabled == 1) {
2517 if (options.macs != NULL) {
2519 myproposal[PROPOSAL_MAC_ALGS_STOC] = options.macs;
2521 if (options.compression == COMP_NONE) {
2524 } else if (options.compression == COMP_DELAYED) {
2528 if (options.kex_algorithms != NULL)
2529 myproposal[PROPOSAL_KEX_ALGS] = options.kex_algorithms;
2534 if (options.rekey_limit || options.rekey_interval)
2535 packet_set_rekey_limits((u_int32_t)options.rekey_limit,
2536 (time_t)options.rekey_interval);