wifidog / wifidog-auth Goto Github PK
View Code? Open in Web Editor NEWRepository for the PHP wifidog captive portal auth server
Repository for the PHP wifidog captive portal auth server
Hi,
Sorry for posting here, I don't know where to ask (mailing list is dead, nobody in IRC channel), consider this is a feature request for document.
I want to implement my our own wifidog-auth which can
I can write the web stuffs (JSP), but I don't know how to communicate with wifi-gateway: What/How should I return to the gateway if login is sucessful or failed?
Hello,
Scenario :- There are 2 hotspots in a network.
Database connection
Trying to open a Postgresql database connection :
Unable to connect to database! Please make sure the server is online and the database "" exists. Also 'postgresql.conf' and 'pg_hba.conf' must allow the user "" to open a connection to it on host "" port 0 to continue. See the error above for clues on what the problem may be.
Please go back and retry with correct values, or fix your server configuration.
Refresh
Database wifidog exists and is at schema version 62. The required schema version is 71. Triggering database schema upgrade ;* @author Max Horváth ;* @copyright 2004-2006 Benoit Grégoire, Technologies Coeus inc.;* @copyright 2005-2006 Max Horváth, Horvath Web Consulting;* @Version Subversion
Hi.
Did anyone try to use hybridauth as authentication method for authpuppy? How did it? I'm trying but there is a lack of documentation , I have many doubts about it. Thanks
Hi,I want to build a public hot spot and everyone could access the Internet after authorization.Since I succeeded on my router based on OpenWRT,using wifidog and authpuppy,could it be used on android?(We also want to integrate the wifidog into our android device.)And how ?
Running the server on a PHP 5.6 installation, on step Database Initialisation we see the following:
Runtime Notice: Declaration of File::getUserUI() should be compatible with Content::getUserUI($subclass_user_interface = NULL) in /var/www/html/classes/Content/File/File.php
Runtime Notice: Declaration of ContentGroupElement::processNewContentUI() should be compatible with Content::processNewContentUI($user_prefix) in /var/www/html/classes/Content/ContentGroup/ContentGroupElement.php
Runtime Notice: Declaration of ContentGroupElement::getUserUI() should be compatible with Content::getUserUI($subclass_user_interface = NULL) in /var/www/html/classes/Content/ContentGroup/ContentGroupElement.php
Runtime Notice: Declaration of Node::freeObject() should be compatible with HotspotGraphElement::freeObject($id, $type) in /var/www/html/classes/Node.php on line 65
Runtime Notice: Declaration of Node::createNewObject() should be compatible with HotspotGraphElement::createNewObject($element_id, $element_type, $parent_element = NULL) in /var/www/html/classes/Node.php on line 65
Runtime Notice: Declaration of EmbeddedContent::getUserUI() should be compatible with Content::getUserUI($subclass_user_interface = NULL) in /var/www/html/classes/Content/EmbeddedContent/EmbeddedContent.php
Runtime Notice: Declaration of Langstring::processNewUI() should be compatible with Content::processNewUI($contentId, $checkOnly = false, $userData = NULL) in /var/www/html/classes/Content/Langstring/Langstring.php
Runtime Notice: Declaration of Langstring::getUserUI() should be compatible with Content::getUserUI($subclass_user_interface = NULL) in /var/www/html/classes/Content/Langstring/Langstring.php
Runtime Notice: Declaration of IFrame::getUserUI() should be compatible with Content::getUserUI($subclass_user_interface = NULL) in /var/www/html/classes/Content/IFrame/IFrame.php
Runtime Notice: Declaration of PatternLanguage::getUserUI() should be compatible with ContentGroup::getUserUI($hide_elements = false) in /var/www/html/classes/Content/PatternLanguage/PatternLanguage.php
Runtime Notice: Declaration of PatternLanguage::getAllContent() should be compatible with Content::getAllContent($content_type = '') in /var/www/html/classes/Content/PatternLanguage/PatternLanguage.php
Runtime Notice: Declaration of RssAggregator::getUserUI() should be compatible with Content::getUserUI($subclass_user_interface = NULL) in /var/www/html/classes/Content/RssAggregator/RssAggregator.php
Runtime Notice: Declaration of ShoutBox::getUserUI() should be compatible with Content::getUserUI($subclass_user_interface = NULL) in /var/www/html/classes/Content/ShoutBox/ShoutBox.php
Runtime Notice: Declaration of SmartyTemplate::getString() should be compatible with Langstring::getString($verbose = true) in /var/www/html/classes/Content/SmartyTemplate/SmartyTemplate.php
Runtime Notice: Declaration of UIAllowedBandwidth::getUserUI() should be compatible with Content::getUserUI($subclass_user_interface = NULL) in /var/www/html/classes/Content/UIAllowedBandwidth/UIAllowedBandwidth.php
Runtime Notice: Declaration of UIUserList::getUserUI() should be compatible with Content::getUserUI($subclass_user_interface = NULL) in /var/www/html/classes/Content/UIUserList/UIUserList.php
Runtime Notice: Declaration of NodeGroup::freeObject() should be compatible with HotspotGraphElement::freeObject($id, $type) in /var/www/html/classes/NodeGroup.php
Runtime Notice: Declaration of NodeGroup::createNewObject() should be compatible with HotspotGraphElement::createNewObject($element_id, $element_type, $parent_element = NULL) in /var/www/html/classes/NodeGroup.php
Runtime Notice: Declaration of Network::freeObject() should be compatible with HotspotGraphElement::freeObject($id, $type) in /var/www/html/classes/Network.php on line 71
Runtime Notice: Declaration of Network::createNewObject() should be compatible with HotspotGraphElement::createNewObject($element_id, $element_type, $parent_element = NULL) in /var/www/html/classes/Network.php on line 71
Notice: Use of undefined constant CONF_DATABASE_NAME - assumed 'CONF_DATABASE_NAME' in /var/www/html/classes/AbstractDb.php on line 91
Notice: Use of undefined constant CONF_DATABASE_HOST - assumed 'CONF_DATABASE_HOST' in /var/www/html/classes/AbstractDb.php on line 94
Notice: Use of undefined constant CONF_DATABASE_PORT - assumed 'CONF_DATABASE_PORT' in /var/www/html/classes/AbstractDb.php on line 94
Notice: Use of undefined constant CONF_DATABASE_USER - assumed 'CONF_DATABASE_USER' in /var/www/html/classes/AbstractDb.php on line 94
Notice: Use of undefined constant CONF_DATABASE_PASSWORD - assumed 'CONF_DATABASE_PASSWORD' in /var/www/html/classes/AbstractDb.php on line 94
Notice: Use of undefined constant CONF_DATABASE_HOST - assumed 'CONF_DATABASE_HOST' in /var/www/html/classes/AbstractDb.php on line 103
Notice: Use of undefined constant CONF_DATABASE_PORT - assumed 'CONF_DATABASE_PORT' in /var/www/html/classes/AbstractDb.php on line 103
Notice: Use of undefined constant CONF_DATABASE_USER - assumed 'CONF_DATABASE_USER' in /var/www/html/classes/AbstractDb.php on line 103
Notice: Use of undefined constant NODE_PUBLIC_STATS_DIR - assumed 'NODE_PUBLIC_STATS_DIR' in /var/www/html/include/path_defines_url_content.php on line 151
Notice: Use of undefined constant CONF_DATABASE_NAME - assumed 'CONF_DATABASE_NAME' in /var/www/html/classes/AbstractDb.php on line 91
Notice: Use of undefined constant CONF_DATABASE_HOST - assumed 'CONF_DATABASE_HOST' in /var/www/html/classes/AbstractDb.php on line 94
Notice: Use of undefined constant CONF_DATABASE_PORT - assumed 'CONF_DATABASE_PORT' in /var/www/html/classes/AbstractDb.php on line 94
Notice: Use of undefined constant CONF_DATABASE_USER - assumed 'CONF_DATABASE_USER' in /var/www/html/classes/AbstractDb.php on line 94
Notice: Use of undefined constant CONF_DATABASE_PASSWORD - assumed 'CONF_DATABASE_PASSWORD' in /var/www/html/classes/AbstractDb.php on line 94
Notice: Use of undefined constant CONF_DATABASE_HOST - assumed 'CONF_DATABASE_HOST' in /var/www/html/classes/AbstractDb.php on line 103
Notice: Use of undefined constant CONF_DATABASE_PORT - assumed 'CONF_DATABASE_PORT' in /var/www/html/classes/AbstractDb.php on line 103
Notice: Use of undefined constant CONF_DATABASE_USER - assumed 'CONF_DATABASE_USER' in /var/www/html/classes/AbstractDb.php on line 103
These runtime notices are due to the subclasses having different method signatures from their parent classes. Disabling the runtime notices on PHP 5.4 seemed to work, but on 5.6 don't.
Unfortunately I can't downgrade PHP. So is there any chance to get these classes updated for PHP 5.4+?
hello,
trying setup with install.php but cant locate dog_cookie.txt in /tmp/ folder, as it is empty, so I cant use password to proceed.
I assume that the /tmp/ should be in my server's /var/www/html/wifidog-auth/wifidog folder.
When the config.php
is saved after the Database Access Configuration step from the install.php
, its content get messed up.
It looks like this:
<?php;;/* vim: set expandtab tabstop=4 shiftwidth=4 softtabstop=4: */;;// +-------------------------------------------------------------------+;// | WiFiDog Authentication Server |;// | ============================= |;// | |;// | The WiFiDog Authentication Server is part of the WiFiDog captive |;// | portal suite. |;// +-------------------------------------------------------------------+;// | PHP version 5 required. |;// +-------------------------------------------------------------------+;// | Homepage: http://www.wifidog.org/ |;// | Source Forge: http://sourceforge.net/projects/wifidog/ |;// +-------------------------------------------------------------------+;// | This program is free software;you can redistribute it and/or |;// | modify it under the terms of the GNU General Public License as |;// | published by the Free Software Foundation;either version 2 of |;// | the License, or (at your option) any later version. |;// | |;// | This program is distributed in the hope that it will be useful, |;// | but WITHOUT ANY WARRANTY;without even the implied warranty of |;// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |;// | GNU General Public License for more details. |;// | |;// | You should have received a copy of the GNU General Public License |;// | along with this program;if not, contact: |;// | |;// | Free Software Foundation Voice: +1-617-542-5942 |;// | 59 Temple Place - Suite 330 Fax: +1-617-542-2652 |;// | Boston, MA 02111-1307, USA [email protected] |;// | |;// +-------------------------------------------------------------------+;;/**;* Configuration file of WiFiDog Authentication Server;*;* The configure the WiFiDOG auth server you can either use this configuration;* file or make a local copy of it named local.config.php.;*;* @package WiFiDogAuthServer;* @author Benoit Grégoire <[email protected]>;* @author Max Horváth <[email protected]>;* @copyright 2004-2006 Benoit Grégoire, Technologies Coeus inc.;* @copyright 2005-2006 Max Horváth, Horvath Web Consulting;* @version Subversion $Id$;* @link http://www.wifidog.org/;*/;;/**;* In case this is the local.config.php you should remove the next lines.;*/;;if (file_exists(dirname(__FILE__) . "/local.config.php")) {;// Use a local copy of the configuration if found instead of the distro's.;require dirname(__FILE__) . "/local.config.php";;} else {;;/**;* In case this is the local.config.php stop removing the lines.;*/;;/********************************************************************\;* DATABASE CONFIGURATION *;\********************************************************************/;;/**;* Configuration values needed to access the database.;* ===================================================;*/;;// Host of the database server.;define('CONF_DATABASE_HOST', 'localhost');
;;;;;;;// Port of the database server.;define('CONF_DATABASE_PORT', '5432');
;;;;;;;// Username for database access.;define('CONF_DATABASE_USER', 'postgres');
;;;;;;;// Password for database access.;define('CONF_DATABASE_PASSWORD', 'dF*/22Ke$%');
;;;;;;;// Name of database used by WiFiDOG auth server.;define('CONF_DATABASE_NAME', 'wifidog');
;;;;;;;/**;* Database cleanup;* ================;*;* Normally, the database cleanup routines will be called everytime a portal;* page is displayed. If you set this to true, you must set a cron job on the;* server which will execute the script "cron/cleanup.php".;*/;define('CONF_USE_CRON_FOR_DB_CLEANUP', false);;;/**;* SQL queries profiling. This will output all SQL queries performed to;* generate the page, as well as the relative time used by each.;*/;;define('LOG_SQL_QUERIES', false);;;/**;* Log content display. If set to true, every piece of content displayed to a user will;* be logged in a log table.;*/;;define('LOG_CONTENT_DISPLAY', false);;;/********************************************************************\;* WEBSERVER CONFIGURATION *;\********************************************************************/;;/**;* Caching;* =======;*;* Experimental: If you installed PEAR::Cache_Lite and set this value to true, additional caching;* will be enabled.;*;* If you haven't installed PEAR::Cache_Lite, caching won't be enabled at all.;*/;define('USE_CACHE_LITE', false);;;/**;* Timezone;* ========;*;* Since PHP 5.1.0 date functions have been rewritten and require to set;* a valid timezone. This is ONLY used on PHP >=5.1;*;* You'll find a list of valid identifiers at:;* http://www.php.net/manual/en/timezones.php;*/;define('DATE_TIMEZONE', 'Canada/Eastern');;;/********************************************************************\;* WIFIDOG BASIC CONFIGURATION *;\********************************************************************/;;/**;* Custom signup system;* ====================;*;* If you wanto to use a custom signup system instead of the built in signup;* page uncomment the next line and enter the URL to the system.;*/;//define("CUSTOM_SIGNUP_URL","https://www.bcwireless.net/hotspot/signup.php");;;/**;* Default language;* ================;*;* Define the default language of the WiFiDOG auth server. The language code;* (the part before the _) must be part of the array above (the country;* subcode may differ, and should be set to your country subcode);*/;define('DEFAULT_LANG', 'fr_CA');;;/********************************************************************\;* WIFIDOG FEATURES CONFIGURATION *;\********************************************************************/;;/**;* Google Maps support;* ===================;*;* Enable Google Maps mapping using "hotspots_map.php".;*/;define('GMAPS_HOTSPOTS_MAP_ENABLED', true);;;/********************************************************************\;* ADVANCED CONFIGURATION *;* *;* You should normally not have to edit anything below this! *;\********************************************************************/;;/**;* Path of WiFiDOG auth server installation;* ========================================;*;* SYSTEM_PATH must be set to the url path needed to reach the wifidog;* directory.;*;* Normally '/' or '/wifidog/', depending on where configure your;* document root.;*;* Gateway configuration must match this as well.;*;* CONFIGURATION FLAG REQUIRED IF PATH DETECTION FAILS, ONLY!;*/;// define('SYSTEM_PATH', '/');;;/**;* WiFiDOG configuration;* =====================;*;* Name and version of the WiFiDOG auth server.;*/;define('WIFIDOG_NAME', 'WiFiDog Authentication server');;define('WIFIDOG_VERSION', '(Development)');;;/**;* WiFiDOG internals configuration;* ===============================;*;* Internal configuration values for WiFiDog - don't touch!;*/;;// Filenames and directories;define('NETWORK_THEME_PACKS_DIR', 'media/network_theme_packs/');;define('STYLESHEET_NAME', 'stylesheet.css');;define('PRINT_STYLESHEET_NAME', 'printer.css');;define('LOGIN_PAGE_NAME', 'login.html');;define('HOTSPOT_STATUS_PAGE', 'hotspot_status.php');;define('NODE_PUBLIC_STATS_DIR', "public_stats/");;;// Source URL for the hotspot status page;define('GMAPS_XML_SOURCE_URL', 'hotspot_status.php?format=XML');;;//Enable logging by the EventLogging class;define('EVENT_LOGGING',false);;// Declare warning/error/notice logging to a file.;// Set this to false to disable logging to a file.;// By default, logging is enabled, to file tmp/wifidog.log.;// define('WIFIDOG_LOGFILE', 'tmp/wifidog.log');;;/**;* Email configuration;* ===============================;*;* Internal configuration values for WiFiDog - don't touch!;*/;;define('EMAIL_MAILER', 'mail');// "mail", "sendmail", or "smtp";;// Valid only for SMTP;define('EMAIL_HOST', '');;define('EMAIL_AUTH', false);;;// Valid if EMAIL_AUTH is true;define('EMAIL_USERNAME', '');;define('EMAIL_PASSWORD', '');;;/**;* In case this is the local.config.php you should remove the next lines.;*/;;};;/**;* In case this is the local.config.php stop removing the lines.;*/;;/*;* Local variables:;* tab-width: 4;* c-basic-offset: 4;* c-hanging-comment-ender-p: nil;* End:;*/;;?>;;;;;;
In reality I only got this step to work after a change on the install.php
itself.
I'm installing wifidog auth server on Ubuntu Server 14.04. At the "Database Access" step I was prompted for postgresql credentials and then on the next step this credentials should be saved, but install.php somehow corrupts caonfig.php and it looks like attached file
config.txt
Hello guys
I need help setting up Wifidog authen-server on my amazon linux server.
I am willing to compensate for the time and effort.
Thank you
Alain Fodjo
I'm using postgresql 9.3, test user/password manually connect successfully but can not update using install.php.
Seems like it's can not get $CONF_DATABASE_NAME, $CONF_DATABASE_PORT, $CONF_DATABASE_USER, $CONF_DATABASE_HOST.
Anyway to manually apply scripts to DB and bring up the site?
Thank you.
Hi all!
The issue i'm trying to resolve is when a guest connect for the first time to a gateway, the auth server has to remember him, so when he come back he will not be redirected to splash page but connected automatically, using this we can optimise UX. I think we should add a verification based on the couple {MAC, GwID} if it returns False then we proceed as a normal, else guest bypass the normal process.
waiting for your thoughts.
Can u make for php7 ?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.