[Mapbender-users] MB 2.7.x: Can't save wms application settings
lukas.bollack
lukas.bollack at naturnetz.ch
Tue Mar 1 02:02:36 PST 2016
Ok so now my proxy.conf looks like this:
<IfModule mod_proxy.c>
# If you want to use apache2 as a forward proxy, uncomment the
# 'ProxyRequests On' line and the <Proxy *> block below.
# WARNING: Be careful to restrict access inside the <Proxy *> block.
# Open proxy servers are dangerous both to your network and to the
# Internet at large.
#
# If you only want to use apache2 as a reverse proxy/gateway in
# front of some web application server, you DON'T need
# 'ProxyRequests On'.
ProxyRequests Off
<Proxy *>
AddDefaultCharset off
Order deny,allow
Deny from all
Allow from localhost
</Proxy>
# Enable/disable the handling of HTTP/1.1 "Via:" headers.
# ("Full" adds the server version; "Block" removes all outgoing Via:
headers)
# Set to one of: Off | On | Full | Block
#ProxyVia Off
</IfModule>
my httpd.conf is empty
my /etc/apache2/sites-available/default looks like this:
<VirtualHost *:80>
ServerAdmin webmaster at localhost
DocumentRoot /var/www
<Directory />
Options FollowSymLinks
AllowOverride None
</Directory>
<Directory /var/www/>
Options Indexes FollowSymLinks MultiViews
AllowOverride None
Order allow,deny
allow from all
</Directory>
ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/
<Directory "/usr/lib/cgi-bin">
AllowOverride None
Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
Order allow,deny
Allow from all
</Directory>
ErrorLog ${APACHE_LOG_DIR}/error.log
# Possible values include: debug, info, notice, warn, error, crit,
# alert, emerg.
LogLevel warn
CustomLog ${APACHE_LOG_DIR}/access.log combined
Alias /doc/ "/usr/share/doc/"
<Directory "/usr/share/doc/">
Options Indexes MultiViews FollowSymLinks
AllowOverride None
Order deny,allow
Deny from all
Allow from 127.0.0.0/255.0.0.0 ::1/128
</Directory>
Alias /owsproxy /var/www/naturnetz.com/mapbender/owsproxy
<Directory /var/www/naturnetz.com/mapbender/owsproxy/>
Options +FollowSymLinks
ReWriteEngine On
RewriteBase /owsproxy
RewriteRule ^([\w\d]+)\/([\w\d]+)\/?$
http://127.0.0.1/owsproxy/http/index.php?sid=$1\&wms=$2\& [P,L,QSA,NE]
Options +Indexes
Allow from all
</Directory>
Alias /cors_proxy /var/www/naturnetz.com/mapbender/cors_proxy
<Directory /var/www/naturnetz.com/mapbender/cors_proxy/>
Options +FollowSymLinks
ReWriteEngine On
RewriteBase /cors_proxy
RewriteRule ^([\d]+)?$
http://127.0.0.1/cors_proxy/http/index.php?wmsid=$1\& [P,L,QSA,NE]
Options +Indexes
Allow from all
</Directory>
Alias /http_auth /var/www/naturnetz.com/mapbender/http_auth
<Directory /var/www/naturnetz.com/mapbender/http_auth/>
Options +FollowSymLinks +Indexes
ReWriteEngine On
RewriteBase /http_auth
RewriteRule ^([\d]+)\/?$
http://127.0.0.1/http_auth/http/index.php?layer_id=$1 [P,L,QSA,NE]
Order allow,deny
Allow from all
</Directory>
</VirtualHost>
My Mapbender.conf looks like this (just the parts we discussed):
# --------------------------------------------
# URL to owsproxy
# (no terminating slash)
# OWSPROXY_USE_LOCALHOST - use 127.0.0.1 and http for the requests if
possible
# --------------------------------------------
define("OWSPROXY", "http://".$_SERVER['HTTP_HOST']."/owsproxy");
define("OWSPROXY_USE_LOCALHOST", false);
# --------------------------------------------
# Definitions for HTTP Authentication
# --------------------------------------------
define('REALM', 'mapbender_registry');
define('NONCEKEY', 'mapbender');
$nonceLife = 300;
define('HTTP_AUTH_PROXY',"http://".$_SERVER['HTTP_HOST']."/http_auth");
//Problem - behind a rewrite rule - define it hardcoded?
# --------------------------------------------
# type of server-connection
# curl, socket, http
# --------------------------------------------
define("CONNECTION", "curl");
#define("CONNECTION", "http");
#define("CONNECTION", "socket");
define("CONNECTION_PROXY", ""); // ip
define("CONNECTION_PORT", ""); // port
define("CONNECTION_USER", "<user>"); // user
define("CONNECTION_PASSWORD", "<password>"); // password
define("CONNECTION_USERAGENT", "Mapbender");
Now when I put naturnetz.com/owsproxy into my browsers address bar, it says
"The requested URL /owsproxy was not found on this server." Shouldn't it
lead to the /var/www/naturnetz.com/mapbender/owsproxy folder?
Also, I have a wms-layer which is password protected in my mapbender
installation. I registered it once in this form:
http://user:password@url/wms?GetCapabilities&SERVICE=WMS&VERSION=1.1.0 and
once in this form: http://url/wms?GetCapabilities&SERVICE=WMS&VERSION=1.1.0.
Both times I also saved username and password in the field below and chose
"basic" as authentification method. In my GUI i added both wms variants. I
also added the owsproxy module to the gui. Now when I display the gui, the
wms variant where I entered username and password directly in the request
URL is displayed, but Mapbender still creates a popup asking me for the
credentials. When I enter the correct credentials, the layer is displayed no
problems. The other layer is never displayed and I am not asked for
credentials.
Now when I click the getURL button in the GUI I get a URL like this:
http://naturnetz.com/owsproxy/ks3p3ae2a3svhf3n7ugqj9sf06/45bcd5bfc8bc7f7ba12cb40981304185?.
When I enter this URL in the browser it says: "The requested URL
/owsproxy/ks3p3ae2a3svhf3n7ugqj9sf06/45bcd5bfc8bc7f7ba12cb40981304185 was
not found on this server."
Where could the error be? Did I miss anything?
--
View this message in context: http://osgeo-org.1560.x6.nabble.com/MB-2-7-x-Can-t-save-wms-application-settings-tp5244512p5253561.html
Sent from the mapbender-users mailing list archive at Nabble.com.
More information about the Mapbender_users
mailing list