Thank you for this useful informations.
You're right for the WSGIScriptAlias but I'm currently testing
implementation of Trac and this is a place-holder.
About the logs, I increased the logs verbosity to 'debug' yet, but there
were exactly the same (few) informations.
I investigated in the MySQL module way and found that I actually not use
it on this server.
So, I deactivated it and it works as intended. The more annoying is that
I reactivated MySQL module... and it works.
I'm 200% sure that I restarted the server yesterday, with 'graceful' and
'restart'.
For my personal knowledge, does someone have an idea of what happened ?
As a summary, there is an installation of Apache built yesterday,
and I have the MySQL module installed but not used at any level of the
Apache configuration (I don't use .htaccess files).
# httpd -v
Server version: Apache/2.2.21 (FreeBSD)
Server built: Nov 17 2011 16:09:46
# apachectl -M
Loaded Modules:
core_module (static)
mpm_prefork_module (static)
http_module (static)
so_module (static)
authn_file_module (shared)
authn_dbm_module (shared)
authn_anon_module (shared)
authn_default_module (shared)
authn_alias_module (shared)
authz_host_module (shared)
authz_groupfile_module (shared)
authz_user_module (shared)
authz_dbm_module (shared)
authz_owner_module (shared)
authnz_ldap_module (shared)
authz_default_module (shared)
auth_basic_module (shared)
auth_digest_module (shared)
file_cache_module (shared)
cache_module (shared)
disk_cache_module (shared)
dumpio_module (shared)
include_module (shared)
filter_module (shared)
charset_lite_module (shared)
deflate_module (shared)
ldap_module (shared)
log_config_module (shared)
logio_module (shared)
env_module (shared)
mime_magic_module (shared)
cern_meta_module (shared)
expires_module (shared)
headers_module (shared)
usertrack_module (shared)
unique_id_module (shared)
setenvif_module (shared)
version_module (shared)
ssl_module (shared)
mime_module (shared)
dav_module (shared)
status_module (shared)
autoindex_module (shared)
asis_module (shared)
info_module (shared)
cgi_module (shared)
dav_fs_module (shared)
vhost_alias_module (shared)
negotiation_module (shared)
dir_module (shared)
imagemap_module (shared)
actions_module (shared)
speling_module (shared)
userdir_module (shared)
alias_module (shared)
rewrite_module (shared)
php5_module (shared)
dav_svn_module (shared)
authz_svn_module (shared)
wsgi_module (shared)
Syntax OK
Le 17/11/2011 23:43, Graham Dumpleton a écrit :
At what scope in the Apache configuration is the authn configuration
related to MySQL defined. At global scope, another VirtualHost and is
it constrained to a Directory block and if so what.
BTW, setting:
DocumentRoot /usr/local/www/trac
may not be a good idea. You certainly don't want to do that if your
Trac instance is located under that directory.
If it is and you comment out WSGIScriptAlias, then your Trac project
becomes downloadable.
So, never point DocumenRoot at directories containing code or sensitive data.
You might also wide up LogLevel to 'info'. Usually it defaults to
'warn' and not 'error', so you are already restricting what messages
are being logged. Using 'info' makes it more verbose again than 'warn'
and may be lucky and an Apache module logs more detail which is
relevant.
Graham
On 18 November 2011 03:09, Admin Cyanide<[email protected]> wrote:
Hi everyone,
I'm trying to authenticate against my own wsgi script with this vhost config
:
<VirtualHost *:80>
ServerName trac.cyanide-studio.com
ServerAdmin [email protected]
DocumentRoot /usr/local/www/trac
WSGIScriptAlias / /usr/local/www/trac/trac.wsgi
<Directory /usr/local/www/trac>
AuthType Basic
AuthName "Cyanide's Trac"
AuthBasicAuthoritative On
AuthBasicProvider wsgi
WSGIAuthUserScript /usr/local/www/trac/authz.wsgi
Require valid-user
Order deny,allow
Allow from all
</Directory>
ErrorLog /var/log/apache/trac-errors.log
LogLevel error
</VirtualHost>
For tests purposes I made the following function :
def check_password(environ, user, user_password):
return True
But each time I try to authn it doesn't work and I have the following log
lines :
[Thu Nov 17 16:29:58 2011] [error] [client 10.1.8.96] MySQL ERROR: Can't
connect to local MySQL server through socket '/tmp/mysql.sock' (2)
[Thu Nov 17 16:29:58 2011] [error] [client 10.1.8.96] MySQL user ddc not
found: /
MySQL is used as authn provider for some others services.
I don't understand why the wsgi script doesn't work.
And with the AuthBasicAuthoritative explicitly set to "On" I don't
understand why MySQL provider is asked at all.
I tried with AuthBasicAuthoritativedirective set to Off, same issue.
I checked the file name/path, it's ok.
If someone have an idea, it would be great.
Thanks,
Bastien Semene
--
You received this message because you are subscribed to the Google Groups
"modwsgi" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/modwsgi?hl=en.
--
You received this message because you are subscribed to the Google Groups
"modwsgi" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/modwsgi?hl=en.