1/*
2 * Part of Very Secure FTPd
3 * Licence: GPL v2
4 * Author: Chris Evans
5 * tunables.c
6 */
7
8#include "tunables.h"
9
10int tunable_anonymous_enable = 1;
11int tunable_local_enable = 0;
12int tunable_pasv_enable = 1;
13int tunable_port_enable = 1;
14int tunable_chroot_local_user = 0;
15int tunable_write_enable = 0;
16int tunable_anon_upload_enable = 0;
17int tunable_anon_mkdir_write_enable = 0;
18int tunable_anon_other_write_enable = 0;
19int tunable_chown_uploads = 0;
20int tunable_connect_from_port_20 = 0;
21int tunable_xferlog_enable = 0;
22int tunable_dirmessage_enable = 0;
23int tunable_anon_world_readable_only = 1;
24int tunable_async_abor_enable = 0;
25int tunable_ascii_upload_enable = 0;
26int tunable_ascii_download_enable = 0;
27int tunable_one_process_model = 0;
28int tunable_xferlog_std_format = 0;
29int tunable_pasv_promiscuous = 0;
30int tunable_deny_email_enable = 0;
31int tunable_chroot_list_enable = 0;
32int tunable_setproctitle_enable = 0;
33int tunable_text_userdb_names = 0;
34int tunable_ls_recurse_enable = 0;
35int tunable_log_ftp_protocol = 0;
36int tunable_guest_enable = 0;
37int tunable_userlist_enable = 0;
38int tunable_userlist_deny = 1;
39int tunable_use_localtime = 0;
40int tunable_check_shell = 1;
41int tunable_hide_ids = 0;
42int tunable_listen = 0;
43int tunable_port_promiscuous = 0;
44int tunable_passwd_chroot_enable = 0;
45int tunable_no_anon_password = 0;
46int tunable_tcp_wrappers = 0;
47int tunable_use_sendfile = 1;
48int tunable_force_dot_files = 0;
49int tunable_listen_ipv6 = 0;
50int tunable_dual_log_enable = 0;
51int tunable_syslog_enable = 0;
52int tunable_background = 0;
53int tunable_virtual_use_local_privs = 0;
54int tunable_session_support = 0;
55int tunable_download_enable = 1;
56int tunable_dirlist_enable = 1;
57int tunable_chmod_enable = 1;
58int tunable_secure_email_list_enable = 0;
59int tunable_run_as_launching_user = 0;
60int tunable_no_log_lock = 0;
61int tunable_ssl_enable = 0;
62int tunable_allow_anon_ssl = 0;
63int tunable_force_local_logins_ssl = 1;
64int tunable_force_local_data_ssl = 1;
65int tunable_sslv2 = 0;
66int tunable_sslv3 = 0;
67int tunable_tlsv1 = 1;
68int tunable_tilde_user_enable = 0;
69int tunable_enable_iconv = 0;	// Jiahao
70int tunable_force_anon_logins_ssl = 0;
71int tunable_force_anon_data_ssl = 0;
72int tunable_mdtm_write = 1;
73int tunable_lock_upload_files = 1;
74int tunable_pasv_addr_resolve = 0;
75
76unsigned int tunable_accept_timeout = 60;
77unsigned int tunable_connect_timeout = 60;
78// 2008.05 James. {
79/*unsigned int tunable_local_umask = 077;
80unsigned int tunable_anon_umask = 077;//*/
81unsigned int tunable_local_umask = 000;
82unsigned int tunable_anon_umask = 000;//*/
83// 2008.05 James. }
84unsigned int tunable_ftp_data_port = 20;
85unsigned int tunable_idle_session_timeout = 300;
86unsigned int tunable_data_connection_timeout = 300;
87/* IPPORT_USERRESERVED + 1 */
88unsigned int tunable_pasv_min_port = 5001;
89unsigned int tunable_pasv_max_port = 0;
90unsigned int tunable_anon_max_rate = 0;
91unsigned int tunable_local_max_rate = 0;
92/* IPPORT_FTP */
93unsigned int tunable_listen_port = 21;
94unsigned int tunable_max_clients = 0;
95/* -rw-rw-rw- */
96unsigned int tunable_file_open_mode = 0666;
97unsigned int tunable_max_per_ip = 0;
98unsigned int tunable_trans_chunk_size = 0;
99
100const char* tunable_secure_chroot_dir = "/tmp";	//Yen
101const char* tunable_ftp_username = "ftp";
102const char* tunable_chown_username = "root";
103const char* tunable_xferlog_file = "/var/log/xferlog";
104const char* tunable_vsftpd_log_file = "/var/log/vsftpd.log";
105const char* tunable_message_file = ".message";
106const char* tunable_nopriv_user = "nobody";
107const char* tunable_ftpd_banner = 0;
108const char* tunable_banned_email_file = "/etc/vsftpd.banned_emails";
109const char* tunable_chroot_list_file = "/etc/vsftpd.chroot_list";
110const char* tunable_pam_service_name = "ftp";
111const char* tunable_guest_username = "ftp";
112const char* tunable_userlist_file = "/etc/vsftpd.user_list";
113const char* tunable_anon_root = 0;
114const char* tunable_local_root = 0;
115const char* tunable_banner_file = 0;
116const char* tunable_pasv_address = 0;
117const char* tunable_listen_address = 0;
118const char* tunable_user_config_dir = 0;
119const char* tunable_listen_address6 = 0;
120const char* tunable_cmds_allowed = 0;
121const char* tunable_hide_file = 0;
122const char* tunable_deny_file = 0;
123const char* tunable_user_sub_token = 0;
124const char* tunable_email_password_file = "/etc/vsftpd.email_passwords";
125const char* tunable_rsa_cert_file = "/usr/share/ssl/certs/vsftpd.pem";
126const char* tunable_dsa_cert_file = 0;
127const char* tunable_ssl_ciphers = "DES-CBC3-SHA";
128const char* tunable_local_charset = "utf8";	// Jiahao
129const char* tunable_remote_charset = "cp950";
130const char* tunable_rsa_private_key_file = 0;
131const char* tunable_dsa_private_key_file = 0;
132
133