You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@httpd.apache.org by td...@apache.org on 2018/10/26 11:45:36 UTC

svn commit: r1844895 - /httpd/mod_ftp/trunk/modules/ftp/ftp_protocol.c

Author: tdonovan
Date: Fri Oct 26 11:45:36 2018
New Revision: 1844895

URL: http://svn.apache.org/viewvc?rev=1844895&view=rev
Log:
Set the useragent_addr and useragent_ip values from the connection 
when creating a new request_rec.  This enables use of the
Require ip  authorization directive, which needs useragent_addr.

Modified:
    httpd/mod_ftp/trunk/modules/ftp/ftp_protocol.c

Modified: httpd/mod_ftp/trunk/modules/ftp/ftp_protocol.c
URL: http://svn.apache.org/viewvc/httpd/mod_ftp/trunk/modules/ftp/ftp_protocol.c?rev=1844895&r1=1844894&r2=1844895&view=diff
==============================================================================
--- httpd/mod_ftp/trunk/modules/ftp/ftp_protocol.c (original)
+++ httpd/mod_ftp/trunk/modules/ftp/ftp_protocol.c Fri Oct 26 11:45:36 2018
@@ -455,6 +455,8 @@ request_rec *ftp_read_request(ftp_connec
     r->output_filters = r->proto_output_filters;
     r->proto_input_filters = c->input_filters;
     r->input_filters = r->proto_input_filters;
+    r->useragent_ip = c->client_ip;
+    r->useragent_addr = c->client_addr;
 
 #if ((MODULE_MAGIC_NUMBER_MAJOR == 20051115) \
               && (MODULE_MAGIC_NUMBER_MINOR >= 36)) \