mirror of
https://git.FreeBSD.org/ports.git
synced 2024-10-31 21:57:12 +00:00
2cf9350a4e
No longer build or install the included libcom_err and compile_et. = ftpd now uses IP_PORTRANGE* in the same fashion as the system ftpd. By default, ftpd will now use high port numbers for serving clients in passive mode. = Fix segmentation fault in kadmin. A null pointer dereference that was only tickled when using kadmin with a kdc that uses LDAP as the backend. = Fix a search filter in hdb-ldap.c. A lookup was failing to fetch operational attributes such as modifiersName. = Bump PORTREVISION for above changes.
37 lines
1.5 KiB
Plaintext
37 lines
1.5 KiB
Plaintext
--- appl/ftp/ftpd/ftpd.c.orig Thu Aug 31 01:08:49 2000
|
|
+++ appl/ftp/ftpd/ftpd.c Fri Nov 3 12:01:17 2000
|
|
@@ -68,6 +68,7 @@
|
|
int debug = 0;
|
|
int ftpd_timeout = 900; /* timeout after 15 minutes of inactivity */
|
|
int maxtimeout = 7200;/* don't allow idle time to be set beyond 2 hours */
|
|
+int restricted_data_ports = 1;
|
|
int logging;
|
|
int guest;
|
|
int dochroot;
|
|
@@ -215,6 +216,7 @@
|
|
{ NULL, 't', arg_integer, &ftpd_timeout, "initial timeout" },
|
|
{ NULL, 'T', arg_integer, &maxtimeout, "max timeout" },
|
|
{ NULL, 'u', arg_string, &umask_string, "umask for user logins" },
|
|
+ { NULL, 'U', arg_negative_flag, &restricted_data_ports, "don't use high data ports" },
|
|
{ NULL, 'd', arg_flag, &debug, "enable debugging" },
|
|
{ NULL, 'v', arg_flag, &debug, "enable debugging" },
|
|
{ "builtin-ls", 'B', arg_flag, &use_builtin_ls, "use built-in ls to list files" },
|
|
@@ -1942,6 +1944,8 @@
|
|
socket_set_address_and_port (pasv_addr,
|
|
socket_get_address (ctrl_addr),
|
|
0);
|
|
+ socket_set_portrange(pdata, restricted_data_ports,
|
|
+ pasv_addr->sa_family);
|
|
seteuid(0);
|
|
if (bind(pdata, pasv_addr, socket_sockaddr_size (pasv_addr)) < 0) {
|
|
seteuid(pw->pw_uid);
|
|
@@ -1984,6 +1988,8 @@
|
|
socket_set_address_and_port (pasv_addr,
|
|
socket_get_address (ctrl_addr),
|
|
0);
|
|
+ socket_set_portrange(pdata, restricted_data_ports,
|
|
+ pasv_addr->sa_family);
|
|
seteuid(0);
|
|
if (bind(pdata, pasv_addr, socket_sockaddr_size (pasv_addr)) < 0) {
|
|
seteuid(pw->pw_uid);
|