Git Product home page Git Product logo

cmum's Introduction

CSP MySQL User Manager

A set of PHP-scripts to manage users in CardserverProxy (CSP)

Requirements

  • Web server with PHP support (such as Apache, IIS)
  • MySQL 5.0 or newer
  • PHP 5.3.0 or newer, with session support
  • A web browser with cookies and javascript enabled
  • CardserverProxy (version 0.8.13 or later)

Download

You can download the newest release at http://github.com/dukereborn/cmum/releases/

If you prefer to follow the git repository, the following branch and tag names may be of interest

  • master is the current stable release
  • trunk is the development branch

Installation

  1. Upload all the files to your web server.
  2. Browse to the install-dir to start the installation, http://your.cmum.url/install/
  3. Download the generated config.php and place in the root of you cmum dir
  4. Remove the install dir from the cmum dir
  5. All done!
  6. Setup csp to fetch users from cmum, described bellow

CSP config example for use on a local webserver

<user-manager class="com.bowman.cardserv.XmlUserManager" allow-on-failure="false" log-failures="true">
  <auth-config>
  <update-interval>5</update-interval>
  <user-source name="genxmloutput">
    <user-file-url>http://some.webserver/genxml/genxml.php</user-file-url>
  </user-source>
  </auth-config>
</user-manager>

CSP config example for use on a remote (or local) secure webserver

<user-manager class="com.bowman.cardserv.XmlUserManager" allow-on-failure="false" log-failures="true">
  <auth-config>
  <update-interval>5</update-interval>
  <user-source name="genxmloutput">
    <user-file-url>http://user:[email protected]/genxml/genxml.php</user-file-url>
  </user-source>
  </auth-config>
</user-manager>

Upgrading from version 2.x

Due to a complete rework of the whole system and database, a complete reinstallation is required if you want to upgrade from version 2.x to 3.x.

  1. Export your users to a csv file using the csv export tool in cmum
  2. Follow the installation steps above (note! make sure you install cmum3 into a new clean database)
  3. Import your users using the csv import tool in cmum

Secretkey

The secretkey is used for securing the sessions when browsing cmum, but also when encrypting the admin passwords. So if you move to another server or take a backup of your cmum installation, make sure to include the config.php. Or at least write down the secretkey, without it you won't be able to login to cmum with the admin account in the database.

Genxml options

These options were added to manipulate the output from genxml to fit special builds of csp, or by any other reason that you would like to exclude some data in the genxml output. The usage is just like when using genxml key genxml.php?option=options to use it together with genxml key it should look like this genxml.php?key=genxmlkey&amp;option=options multiple options are separated by semicolon ; like this genxml.php?key=genxmlkey&amp;option=option1;option2;option3

IMPORTANT!!! Remember to use &amp; and not just & between key and option if using both.

Below you will find a list of available options for genxml

nousername
nopassword
nodisplayname
noipmask
noprofiles
nomaxconnections
noadmin
noenabled
nomapexclude
nodebug
noemail
nostartdate
noexpiredate
nocustomvalues

The options simply does what they are called, for example nostartdate will exclude the start-date="dd-mm-yyyy" from the genxml output.

Trouble using cmum with the latest csp version?

This is because some changes where made to the httpd server inside csp. But there is a easy fix for that. Open your csp config-file and check under the <status-web> section. If there is a <ghttpd> section, change it to the one bellow, and if there is none, just add these lines. It's the <ghttpd enabled="false"> that is the important part.

<ghttp enabled="false">
  <alternate-port>8083</alternate-port>
  <log-file>log/ghttp-access.log</log-file>
  <feeder-password>secret1</feeder-password>
  <open-access-password>secret2</open-access-password>
</ghttp>

Full config example for the above part, so you place it correctly

<rmi>
  <display-name>PROXY</display-name>
  <status-web>
    <listen-port>12345</listen-port>
    <ssl enabled="true"> 
      <keystore password="secretpassword">etc/csp_keystore</keystore>
    </ssl>
    <war-file>lib/cs-status.war</war-file>
    <super-users>admin</super-users>
    <ghttp enabled="false">
      <alternate-port>8083</alternate-port>
      <log-file>log/ghttp-access.log</log-file>
      <feeder-password>secret1</feeder-password>
      <open-access-password>secret2</open-access-password>
    </ghttp>
  </status-web>
</rmi>

FAQ - Frequently Asked Questions

Nothing happens when i start the installation?

Check you mysql information and if your user has the correct rights to access the database

How do I get randomized usernames and password?

Double click on the username and/or password field and you will get a random generated username and/or password

CSP stops fetching users when using start-date?

Some versions of csp dont work with start-date. If you need them in cmum, then use genxml options to exclude it from the output to csp.

Expire-date dosnt work in CSP?

Make sure you are using the com.bowman.cardserv.AdvXmlUserManager user-manager class.

Contact me

If you find any bugs, got an idea or just wanna say "Hi!", send me a email on [email protected]. You can also follow me on twitter for updates and news about the development on cmum http://www.twitter.com/dukereborn/

Donations

If you like cmum and all the work I have put into it, consider donating a buck or two :) All donations are welcome through paypal to account [email protected]

Last words

Please use a modern browser like Safari, Google Chrome or Firefox. If it looks like hell in Internet Explorer, well that's just the way it will be.

License

Released under the MIT license

CSP MySQL User Manager includes several third party libraries which come under their respective licenses.

cmum's People

Contributors

dukereborn avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.