You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@httpd.apache.org by Ken Parzygnat <kp...@raleigh.ibm.com> on 1998/10/21 17:18:39 UTC

[PATCH] Win32: User directive

PR 2303 states that the User directive
does not work on Win32.  This is true and
I do not believe Apache should change this
because it would minimally mean putting the 
password of the user id somewhere where Apache
could get it.

In order to get this function on NT, you 
should install the server as a service, and
set up the "Startup..." settings to have the
service start under a particular user account.

I'm proposing that we just put a NOTICE in
the error log stating that the User directive
has no affect on Win32.

What do you think?

--- http_core.c.orig	Mon Oct 05 20:35:39 1998
+++ http_core.c	Tue Oct 06 14:09:21 1998
@@ -1665,6 +1665,11 @@

 static const char *set_user(cmd_parms *cmd, void *dummy, char *arg)
 {
+#ifdef WIN32
+    ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE, cmd->server,
+        "User directive has no affect on Win32.");
+    cmd->server->server_uid = ap_user_id = 1;
+#else
     const char *err = ap_check_cmd_context(cmd, NOT_IN_DIR_LOC_FILE|NOT_IN_LIMIT);
     if (err != NULL) {
         return err;
@@ -1700,6 +1705,7 @@
 	exit (1);
     }
 #endif
+#endif /* WIN32 */

     return NULL;
 }

- - - - - - - - - - - - - - - - - -
Ken Parzygnat
email: kparz@raleigh.ibm.com 










--------------------------------------------------------------------------------
Users of the Apache webserver are hereby granted a non-exclusive, irrevocable,
world-wide, royalty-free, non-transferable license to use, execute, prepare
derivative works of, and distribute (internally and externally, and including
derivative works) the code accompanying this license as part of, and
integrated into the Apache webserver.  This code is provided "AS IS" WITHOUT
WARRANTY OF ANY KIND EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO
THE IMPLIED WARRANTY OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
AND ANY WARRANTY OF NON-INFRINGEMENT.  THE ENTIRE RISK ARISING OUT OF THE USE
OR PERFORMANCE OF THIS CODE REMAINS WITH USERS OF THE APACHE WEBSERVER.  The
owner of this code represents and warrants that it is legally entitled to
grant the above license.

Re: [PATCH] Win32: User directive

Posted by Ben Laurie <be...@algroup.co.uk>.
Marc Slemko wrote:
> 
> On Wed, 21 Oct 1998, Ken Parzygnat wrote:
> 
> > PR 2303 states that the User directive
> > does not work on Win32.  This is true and
> > I do not believe Apache should change this
> > because it would minimally mean putting the
> > password of the user id somewhere where Apache
> > could get it.
> >
> > In order to get this function on NT, you
> > should install the server as a service, and
> > set up the "Startup..." settings to have the
> > service start under a particular user account.
> >
> > I'm proposing that we just put a NOTICE in
> > the error log stating that the User directive
> > has no affect on Win32.
> >
> > What do you think?
> 
> Except it does have an effect.  You can use "UserDir /home/*" or something
> like that just fine.

What's that got do do with User?

Cheers,

Ben.

-- 
Ben Laurie            |Phone: +44 (181) 735 0686| Apache Group member
Freelance Consultant  |Fax:   +44 (181) 735 0689|http://www.apache.org/
and Technical Director|Email: ben@algroup.co.uk |
A.L. Digital Ltd,     |Apache-SSL author     http://www.apache-ssl.org/
London, England.      |"Apache: TDG" http://www.ora.com/catalog/apache/

WE'RE RECRUITING! http://www.aldigital.co.uk/

RE: [PATCH] Win32: User directive

Posted by Marc Slemko <ma...@worldgate.com>.
On Wed, 21 Oct 1998, Ken Parzygnat wrote:

> > > PR 2303 states that the User directive
> > > does not work on Win32.  This is true and
> > > I do not believe Apache should change this
> > > because it would minimally mean putting the 
> > > password of the user id somewhere where Apache
> > > could get it.
> > > 
> > > In order to get this function on NT, you 
> > > should install the server as a service, and
> > > set up the "Startup..." settings to have the
> > > service start under a particular user account.
> > > 
> > > I'm proposing that we just put a NOTICE in
> > > the error log stating that the User directive
> > > has no affect on Win32.
> > > 
> > > What do you think?
> > 
> > Except it does have an effect.  You can use "UserDir /home/*" or something
> > like that just fine.
> > 
> 
> Sorry, you lost me.  Are you saying that the UserDir directive 
> inherits something from the User directive, or there is a special
> relationship?

Sorry, my mistake.  I can't read right.  Ignore me.




RE: [PATCH] Win32: User directive

Posted by Ken Parzygnat <kp...@raleigh.ibm.com>.
> > PR 2303 states that the User directive
> > does not work on Win32.  This is true and
> > I do not believe Apache should change this
> > because it would minimally mean putting the 
> > password of the user id somewhere where Apache
> > could get it.
> > 
> > In order to get this function on NT, you 
> > should install the server as a service, and
> > set up the "Startup..." settings to have the
> > service start under a particular user account.
> > 
> > I'm proposing that we just put a NOTICE in
> > the error log stating that the User directive
> > has no affect on Win32.
> > 
> > What do you think?
> 
> Except it does have an effect.  You can use "UserDir /home/*" or something
> like that just fine.
> 

Sorry, you lost me.  Are you saying that the UserDir directive 
inherits something from the User directive, or there is a special
relationship?

- - - - - - - - - - - - - - - - - -
Ken Parzygnat
email: kparz@raleigh.ibm.com 


Re: [PATCH] Win32: User directive

Posted by Marc Slemko <ma...@worldgate.com>.
On Wed, 21 Oct 1998, Ken Parzygnat wrote:

> PR 2303 states that the User directive
> does not work on Win32.  This is true and
> I do not believe Apache should change this
> because it would minimally mean putting the 
> password of the user id somewhere where Apache
> could get it.
> 
> In order to get this function on NT, you 
> should install the server as a service, and
> set up the "Startup..." settings to have the
> service start under a particular user account.
> 
> I'm proposing that we just put a NOTICE in
> the error log stating that the User directive
> has no affect on Win32.
> 
> What do you think?

Except it does have an effect.  You can use "UserDir /home/*" or something
like that just fine.