You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@httpd.apache.org by wr...@apache.org on 2009/07/16 01:33:16 UTC
svn commit: r794459 - in /httpd/mod_ftp/trunk: CHANGES-FTP STATUS-FTP
modules/ftp/ftp_internal.h modules/ftp/mod_ftp.c
Author: wrowe
Date: Wed Jul 15 23:33:15 2009
New Revision: 794459
URL: http://svn.apache.org/viewvc?rev=794459&view=rev
Log:
Introduce FEAT advertising of UTF8, unless Options NoUTF8Feature is
globally configured.
Modified:
httpd/mod_ftp/trunk/CHANGES-FTP
httpd/mod_ftp/trunk/STATUS-FTP
httpd/mod_ftp/trunk/modules/ftp/ftp_internal.h
httpd/mod_ftp/trunk/modules/ftp/mod_ftp.c
Modified: httpd/mod_ftp/trunk/CHANGES-FTP
URL: http://svn.apache.org/viewvc/httpd/mod_ftp/trunk/CHANGES-FTP?rev=794459&r1=794458&r2=794459&view=diff
==============================================================================
--- httpd/mod_ftp/trunk/CHANGES-FTP (original)
+++ httpd/mod_ftp/trunk/CHANGES-FTP Wed Jul 15 23:33:15 2009
@@ -1,5 +1,10 @@
Changes in 0.9.5:
+ *) Introduce FTPOptions NoUTF8Feature; without this configured in the
+ global context, mod_ftp will report UTF8 in response to FEAT, to
+ indicate that non-ASCII filenames, including UTF8, are ok per RFC2640.
+ [William Rowe]
+
*) Answers HELP and FEAT queries without a prior login. [William Rowe]
*) REST STREAM, EPRT, EPSV added to the FEAT results as required by spec
Modified: httpd/mod_ftp/trunk/STATUS-FTP
URL: http://svn.apache.org/viewvc/httpd/mod_ftp/trunk/STATUS-FTP?rev=794459&r1=794458&r2=794459&view=diff
==============================================================================
--- httpd/mod_ftp/trunk/STATUS-FTP (original)
+++ httpd/mod_ftp/trunk/STATUS-FTP Wed Jul 15 23:33:15 2009
@@ -66,10 +66,10 @@
* For in-tree builds, expanding @@FTPPort@@ / @exp_ftpdocsdir@
and installing conf/extra/ftpd.conf.
- * Review i18n and naming convention issues from
+ * Review remaining UTF-8 support issues and implement LANG command from
"Internationalization of the File Transfer Protocol", Curtin
http://www.ietf.org/rfc/rfc2640.txt
- and perhaps
+ considering errata corrections published in
"UTF-8 Option for FTP", Lundberg
http://www3.ietf.org/proceedings/02nov/I-D/draft-ietf-ftpext-utf-8-option-00.txt
Modified: httpd/mod_ftp/trunk/modules/ftp/ftp_internal.h
URL: http://svn.apache.org/viewvc/httpd/mod_ftp/trunk/modules/ftp/ftp_internal.h?rev=794459&r1=794458&r2=794459&view=diff
==============================================================================
--- httpd/mod_ftp/trunk/modules/ftp/ftp_internal.h (original)
+++ httpd/mod_ftp/trunk/modules/ftp/ftp_internal.h Wed Jul 15 23:33:15 2009
@@ -138,6 +138,7 @@
#define FTP_OPT_ALLOWPROXYPASV (1 << 9) /* Data listens to other than client */
#define FTP_OPT_VHOST_BY_USER (1 << 10) /* Parse USER for @hostname vhost */
#define FTP_OPT_STRIP_HOSTNAME (1 << 11) /* Strip @hostname from username */
+#define FTP_OPT_NO_UTF8_FEAT (1 << 12) /* Hide UTF8 from FEAT results */
/* Supported FTP AUTH mechanisms. */
#define FTP_AUTH_NONE 0
Modified: httpd/mod_ftp/trunk/modules/ftp/mod_ftp.c
URL: http://svn.apache.org/viewvc/httpd/mod_ftp/trunk/modules/ftp/mod_ftp.c?rev=794459&r1=794458&r2=794459&view=diff
==============================================================================
--- httpd/mod_ftp/trunk/modules/ftp/mod_ftp.c (original)
+++ httpd/mod_ftp/trunk/modules/ftp/mod_ftp.c Wed Jul 15 23:33:15 2009
@@ -86,6 +86,13 @@
ap_add_version_component(p, FTP_SERVER_STRING);
+ /*
+ * Unless disabled, advertise that UTF8 filenames are preferred/permitted
+ * RFC2640 never -requires- UTF8 names
+ */
+ if (!(basefsc->options & FTP_OPT_NO_UTF8_FEAT))
+ ftp_feat_advert("UTF8");
+
/* Finalize ftp_cmd_help and ftp_cmd_feat messages */
ftp_cmd_finalize(p, ptemp);
@@ -568,6 +575,9 @@
else if (!strcasecmp(op, "StripHostname")) {
opt_mask = FTP_OPT_STRIP_HOSTNAME;
}
+ else if (!strcasecmp(op, "NoUTF8Feature")) {
+ opt_mask = FTP_OPT_NO_UTF8_FEAT;
+ }
else {
return apr_pstrcat(cmd->pool, "Illegal FTPOption ", op, NULL);
}