Phamm errors Ubuntu 14.04

Discussion in 'HOWTO-Related Questions' started by luksch, Dec 14, 2014.

  1. luksch

    luksch New Member

    Hi,

    thanks for the great tutorial called Postfix Virtual Hosting With LDAP Backend And With Dovecot As IMAP/POP3 Server On Ubuntu Trusty Tahr 14.04.

    Having strictly followed the instructions I am facing a serious issue now. Although Phamm (version 0.6.2) allows me to login via the Phamm LDAP user or via the LDAP administrator it only allows me to select a language and to logout. However, I've successfully imported the additional LDAP schemes (Jxplorer shows them under cn=scheme, cn=config), both Postfix and Dovecot start without errors or warnings using the LDAP configuration and I think I've installed all required PHP packages (I've followed the guide explaining how to set up Lighttpd with PHP5-FPM on Ubuntu 14.04).

    Here is my "global" configuration:

    Base DN: dc=hakwaidhofen-ybbs,dc=ac,dc=at
    LDAP administrator: cn=admin,dc=hakwaidhofen-ybbs,dc=ac,dc=at
    DN for the virtual users: o=email,dc=hakwaidhofen-ybbs,dc=ac,dc=at
    LDAP Phamm user: cn=phamm,o=email,dc=hakwaidhofen-ybbs,dc=ac,dc=at
    Virtual mail system user: vmail (UID=1002, GID=1002) /* I've taken care of the different UID and GID*/

    You can see my Phamm configuration down below:


    /**
    * The main Phamm config file
    *
    * @package Phamm
    * @subpackage configuration
    * @author Alessandro De Zorzi <adezorzi AT rhx DOT it>
    **/

    // *============================*
    // *=== LDAP Server Settings ===*
    // *============================*

    // The server address (To use ldapssl change to ldaps://localhost)
    define ('LDAP_HOST_NAME','127.0.0.1');

    // The protocol version [2,3]
    define ('LDAP_PROTOCOL_VERSION','3');

    // The server port (To use ldapssl change to 636)
    define ('LDAP_PORT','389');

    // Set LDAP_TLS to 1 if you want to use TLS
    define ('LDAP_TLS',0);

    // The container
    define ('SUFFIX','dc=hakwaidhofen-ybbs,dc=ac,dc=at');

    // The admin bind dn (could be rootdn)
    define ('BINDDN','cn=admin,dc=hakwaidhofen-ybbs,dc=ac,dc=at');

    // The Phamm container
    define ('LDAP_BASE','o=email,dc=hakwaidhofen-ybbs,dc=ac,dc=at');


    // *============================*
    // *=== Layout Settings ===*
    // *============================*

    // Page title
    define('ORG_TITLE','Phamm');

    // URL
    define('ORG_URL','http://www.phamm.org');

    // Logo
    define('ORG_LOGO', './img/phamm_logo.svg');

    // CSS Style
    $style = 'phamm';

    // Default language
    define ('DEFAULT_LANGUAGE','en_GB');

    // The languages available
    $supported_languages = array();
    $supported_languages["de_DE"] = "Deutsch";
    $supported_languages["en_GB"] = "English";
    $supported_languages["es_ES"] = "Español";
    $supported_languages["fr_FR"] = "French";
    $supported_languages["hu_HU"] = "Hungarian";
    $supported_languages["it_IT"] = "Italiano";
    $supported_languages["pl_PL"] = "Polish";
    $supported_languages["ru_RU"] = "Russian";
    $supported_languages["vi_VN"] = "Tiếng Việt"; // Vietnamese
    $supported_languages["da_DK"] = "Dansk"; // Danish
    $supported_languages["pt_BR"] = "Portuguese";
    // $supported_languages["ll_CC"] = "Your language here";

    // This TLDs menu
    $tld = array();
    $tld[] = ".com";
    $tld[] = ".ac.at";
    $tld[] = ".at";
    $tld[] = ".org";
    $tld[] = ".net";
    // $tld[] = ".biz";
    // $tld[] = ".info";
    // $tld[] = ".eu";
    // $tld[] = ".it";
    // $tld[] = ".fr";
    // $tld[] = ".de";


    // *============================*
    // *=== Plugins Settings ===*
    // *============================*

    // The default plugin
    define ('DEFAULT_PLUGIN','mail');

    // This array contains the active plugins
    // NOTE the display order reflect this order
    $plugins = array();
    $plugins[] = "mail";
    $plugins[] = "alias";
    //$plugins[] = "dns";
    //$plugins[] = "ftp";
    //$plugins[] = "proxy";
    //$plugins[] = "radius";
    //$plugins[] = "radius_stats";
    //$plugins[] = "rates";
    $plugins[] = "person";
    //$plugins[] = "jabber";
    //$plugins[] = "davical";

    // Account can be mail OR alias
    $plugins_exclusion = array("mail","alias");


    // *============================*
    // *=== System Settings ===*
    // *============================*

    // Phamm Version (+ indicate a SVN version)
    define ('VERSION','0.6.2');

    // Useful if you want hide the version [0,1]
    define ('HIDE_VERSION',0);

    // Useful if you wish force SSL through PHP [0,1]
    define ('FORCE_SSL',0);

    // Min password length
    define ('PASSWORD_MIN_LENGHT',3);

    // Seconds after refresh page
    define ('REFRESH_TIME',1);

    // A Domain administrator (example: postmaster)
    define ('PHAMM_DOMAIN_ADMIN_NAME','postmaster');

    // Welcome message
    define ('SEND_WELCOME',1);
    $welcome_msg = '../welcome_message.txt';
    $welcome_subject = 'Welcome!';
    # $welcome_sender = 'postmaster@localhost';
    $welcome_bcc = 'postmaster@localhost';

    // *============================*
    // *=== Advanced Settings ===*
    // *============================*

    // Debug level [0,1]
    define ('DEBUG',0);

    // PHP Error Level [0,1,2,10]
    define ('ERROR_LEVEL',2);

    // Log level 0->don't log [0,1,2]
    define ('PHAMM_LOG',0);

    // Log file path
    define ('LOG_FILE','/var/log/phamm.log');

    // Standard LDAP encryption type [CRYPT,MD5,CLEAR]
    define ('ENC_TYPE','MD5');

    // Phamm autogenerate UID from e-mail
    // set char used instead @ (default=.)
    // i.e. info@example.com produce UID=info.example.com
    define ('CHR_UID_ACCOUNT','.');

    // Permit login without @domain (use it with carefull)
    // define ('DEFAULT_DOMAIN','example.tld');

    Here is my mail plug-in configuration file:

    cat mail.xml
    <?xml version="1.0" encoding="UTF-8" standalone="no"?>
    <!DOCTYPE plugin SYSTEM "http://www.phamm.org/DTD/phamm-plugins.dtd">

    <plugin name="mail">
    <label>MAIL</label>
    <version>
    <number>0.0.4</number>
    <creationDate>2005-02-19</creationDate>
    <updatedDate>2008-09-08</updatedDate>
    <status>stable</status>
    </version>
    <author>
    <firstName>Alessandro De Zorzi</firstName>
    <lastName>De Zorzi</lastName>
    <mail>team@phamm.org</mail>
    <web>http://www.phamm.org</web>
    </author>
    <license>GPL</license>
    <shortDescription>Plugin to manage Virtual Domain, e-mail account and aliases</shortDescription>
    <longDescription>Plugin to manage Virtual Domain, e-mail account and aliases</longDescription>
    <parent>top</parent>
    <color>FF4455</color>
    <minAuthLevel>2</minAuthLevel>
    <isDomainRelated>1</isDomainRelated>
    <isPostmasterRelated>1</isPostmasterRelated>
    <isAccountRelated>1</isAccountRelated>

    <domain>
    <attributes>
    <attribute name="maxMail">
    <prettyName>Max number of Mail</prettyName>
    <size>4</size>
    <hidden>1</hidden>
    <maxlength>4</maxlength>
    <default>100</default>
    </attribute>
    <attribute name="maxAlias">
    <prettyName>Max number of Alias</prettyName>
    <hidden>1</hidden>
    <size>4</size>
    <maxlength>4</maxlength>
    <default>100</default>
    </attribute>
    <attribute name="maxQuota">
    <prettyName>Max Quota</prettyName>
    <size>4</size>
    <hidden>1</hidden>
    <maxlength>4</maxlength>
    <default>100</default>
    </attribute>
    <attribute name="accountActive">
    <prettyName>Active</prettyName>
    <bool>1</bool>
    <hidden>1</hidden>
    <table>1</table>
    <default>TRUE</default>
    </attribute>
    <attribute name="editAV">
    <prettyName>Can edit Anti-Virus</prettyName>
    <bool>1</bool>
    <hidden>1</hidden>
    <default>TRUE</default>
    </attribute>
    <attribute name="delete">
    <prettyName>Delete</prettyName>
    <bool>1</bool>
    <table>1</table>
    <hidden>1</hidden>
    <cron>1</cron>
    <required>1</required>
    <default>FALSE</default>
    </attribute>
    <attribute name="postfixTransport">
    <prettyName>Postfix Transport</prettyName>
    <default>dovecot:</default>
    <hidden>1</hidden>
    </attribute>
    </attributes>
    </domain>

    <postmaster>
    <attributes>
    <attribute name="editAccounts">
    <prettyName>Can edit Accounts</prettyName>
    <bool>1</bool>
    <table>1</table>
    <default>TRUE</default>
    <minAuthLevel>6</minAuthLevel>
    </attribute>
    </attributes>
    </postmaster>

    <account>
    <objectClasses>
    <objectClass name="VirtualMailAccount">
    <bug>0</bug>
    </objectClass>
    <objectClass name="Vacation">
    <bug>0</bug>
    </objectClass>
    <objectClass name="VirtualForward">
    <bug>0</bug>
    </objectClass>
    <objectClass name="amavisAccount">
    <bug>0</bug>
    </objectClass>
    </objectClasses>
    <attributes>
    <attribute name="smtpAuth">
    <prettyName>SMTP Auth</prettyName>
    <bool>1</bool>
    <table>1</table>
    <default>FALSE</default>
    <minAuthLevel>4</minAuthLevel>
    </attribute>
    <attribute name="quota">
    <prettyName>Quota</prettyName>
    <table>1</table>
    <default>1000</default>
    <multiplier>1048576</multiplier>
    <suffix>S</suffix>
    <minAuthLevel>4</minAuthLevel>
    </attribute>
    <attribute name="accountActive">
    <prettyName>Active</prettyName>
    <bool>1</bool>
    <table>1</table>
    <required>1</required>
    <default>TRUE</default>
    <minAuthLevel>4</minAuthLevel>
    </attribute>
    <attribute name="vdHome">
    <prettyName>Virtual Home</prettyName>
    <hidden>1</hidden>
    <required>1</required>
    <default>/home/vmail/domains</default>
    <minAuthLevel>4</minAuthLevel>
    </attribute>
    <attribute name="mailbox">
    <prettyName>Mailbox</prettyName>
    <hidden>1</hidden>
    <required>1</required>
    <!--<default>=php.Value(%domain%,/,+account_new+,/)</default>-->
    <default>=php.Value(%domain%,/,+account_new+,@,%domain%/)</default>
    <minAuthLevel>4</minAuthLevel>
    </attribute>
    <attribute name="uid">
    <prettyName>UID</prettyName>
    <required>1</required>
    <default>=php.Value(+account_new+,.,%domain%)</default>
    <minAuthLevel>4</minAuthLevel>
    <hidden>1</hidden>
    <hideCreation>1</hideCreation>
    </attribute>
    <attribute name="mailAutoreply">
    <prettyName>Mail Autoreply</prettyName>
    <hidden>1</hidden>
    <default>=php.Value(+account_new+,@,%domain%,.autoreply)</default>
    <minAuthLevel>4</minAuthLevel>
    </attribute>
    <attribute name="delete">
    <prettyName>Delete</prettyName>
    <bool>1</bool>
    <hidden>1</hidden>
    <table>1</table>
    <default>FALSE</default>
    <minAuthLevel>4</minAuthLevel>
    <cron>1</cron>
    </attribute>
    <attribute name="otherTransport">
    <prettyName>Other Transport</prettyName>
    <hidden>1</hidden>
    <default>phamm:</default>
    <minAuthLevel>4</minAuthLevel>
    </attribute>
    <attribute name="vacationActive">
    <prettyName>Vacation</prettyName>
    <default>FALSE</default>
    <bool>1</bool>
    <hidecreation>1</hidecreation>
    </attribute>
    <attribute name="vacationInfo">
    <prettyName>Vacation Info</prettyName>
    <subordinated>vacationActive</subordinated>
    <textarea>1</textarea>
    </attribute>
    <attribute name="vacationForward">
    <prettyName>Vacation Forward</prettyName>
    <subordinated>vacationActive</subordinated>
    <subordinateddelete>1</subordinateddelete>
    </attribute>
    <attribute name="vacationStart">
    <prettyName>Vacation Start</prettyName>
    <subordinated>vacationActive</subordinated>
    <default>201001010000</default>
    <date>1</date>
    </attribute>
    <attribute name="vacationEnd">
    <prettyName>Vacation End</prettyName>
    <subordinated>vacationActive</subordinated>
    <default>201001010000</default>
    <date>1</date>
    </attribute>
    <attribute name="forwardActive">
    <prettyName>Forward Active</prettyName>
    <bool>1</bool>
    <default>FALSE</default>
    <hidecreation>1</hidecreation>
    <table>1</table>
    </attribute>
    <attribute name="maildrop">
    <prettyName>Maildrop</prettyName>
    <subordinated>forwardActive</subordinated>
    </attribute>
    <attribute name="amavisBypassVirusChecks">
    <prettyName>Virus Check</prettyName>
    <bool>1</bool>
    <table>1</table>
    <reverse>1</reverse>
    <default>TRUE</default>
    <minAuthLevel>4</minAuthLevel>
    </attribute>
    <attribute name="amavisBypassSpamChecks">
    <prettyName>SPAM Check</prettyName>
    <bool>1</bool>
    <table>1</table>
    <reverse>1</reverse>
    <default>FALSE</default>
    <minAuthLevel>4</minAuthLevel>
    </attribute>
    <attribute name="amavisSpamKillLevel">
    <prettyName>Spam Kill Level</prettyName>
    <subordinatedReverse>amavisBypassSpamChecks</subordinatedReverse>
    <minAuthLevel>4</minAuthLevel>
    <default>6.0</default>
    <options>
    <option name="low">
    <value>10.0</value>
    </option>
    <option name="medium">
    <value>6.0</value>
    </option>
    <option name="high">
    <value>4.5</value>
    </option>
    <option name="very_high">
    <value>3.0</value>
    </option>
    </options>
    </attribute>
    <attribute name="amavisSpamTag2Level">
    <prettyName>Spam Tag2 Level</prettyName>
    <subordinatedReverse>amavisBypassSpamChecks</subordinatedReverse>
    <minAuthLevel>4</minAuthLevel>
    <default>5.5</default>
    <options>
    <option name="low">
    <value>9.5</value>
    </option>
    <option name="medium">
    <value>5.5</value>
    </option>
    <option name="high">
    <value>4.0</value>
    </option>
    <option name="very_high">
    <value>2.5</value>
    </option>
    </options>
    </attribute>
    <attribute name="amavisSpamTagLevel">
    <prettyName>Spam Tag Level</prettyName>
    <subordinatedReverse>amavisBypassSpamChecks</subordinatedReverse>
    <default>3.0</default>
    <options>
    <option name="low">
    <value>7.0</value>
    </option>
    <option name="medium">
    <value>3.0</value>
    </option>
    <option name="high">
    <value>1.5</value>
    </option>
    <option name="very_high">
    <value>0.0</value>
    </option>
    </options>
    <minAuthLevel>4</minAuthLevel>
    </attribute>
    <attribute name="creationDate">
    <prettyName>Creation Date</prettyName>
    <table>1</table>
    <hidden>1</hidden>
    </attribute>
    </attributes>
    </account>
    </plugin>
     
    Last edited: Dec 14, 2014

Share This Page