You can subscribe to this list here.
2007 |
Jan
|
Feb
|
Mar
|
Apr
(23) |
May
(11) |
Jun
(24) |
Jul
(18) |
Aug
(7) |
Sep
(6) |
Oct
(34) |
Nov
(6) |
Dec
(23) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2008 |
Jan
(3) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
(1) |
Aug
(16) |
Sep
(12) |
Oct
(2) |
Nov
|
Dec
(6) |
2009 |
Jan
|
Feb
|
Mar
(1) |
Apr
|
May
|
Jun
(4) |
Jul
(1) |
Aug
(2) |
Sep
(1) |
Oct
|
Nov
(4) |
Dec
|
From: <tux...@us...> - 2007-05-15 18:12:09
|
Revision: 79 http://elma.svn.sourceforge.net/elma/?rev=79&view=rev Author: tuxevara Date: 2007-05-15 11:11:53 -0700 (Tue, 15 May 2007) Log Message: ----------- admin dn now configurable in config file Modified Paths: -------------- trunk/doc/exim4/exim4.conf.dist trunk/includes/config.inc.php.dist trunk/login.php Modified: trunk/doc/exim4/exim4.conf.dist =================================================================== --- trunk/doc/exim4/exim4.conf.dist 2007-05-11 08:15:14 UTC (rev 78) +++ trunk/doc/exim4/exim4.conf.dist 2007-05-15 18:11:53 UTC (rev 79) @@ -26,7 +26,7 @@ LDAP_DOMAINS_ROOT_DN = ou=domains,LDAP_BASEDN LDAP_USERS_ROOT_DN = ou=users,LDAP_BASEDN LDAP_USER = cn=exim,LDAP_USERS_ROOT_DN -LDAP_PASS = eximusersldappass +LDAP_PASS = exim4pass LDAP_DEFAULT_SERVERS = 127.0.0.1::389 MAILHOME = /var/mailhome Modified: trunk/includes/config.inc.php.dist =================================================================== --- trunk/includes/config.inc.php.dist 2007-05-11 08:15:14 UTC (rev 78) +++ trunk/includes/config.inc.php.dist 2007-05-15 18:11:53 UTC (rev 79) @@ -40,7 +40,7 @@ define ("LDAP_USE_TLS","0"); // LDAP Servers Base DN -define ("LDAP_BASEDN","o=mybase"); +define ("LDAP_BASEDN","o=mybasedn"); // LDAP Servers Base DN for domains define ("LDAP_DOMAINS_ROOT_DN","ou=domains,".LDAP_BASEDN); @@ -48,6 +48,9 @@ // LDAP Servers Base DN for system user (e.g. admin) define ("LDAP_USERS_ROOT_DN","ou=users,".LDAP_BASEDN); +// DN for LDAP admin user with access to the complete tree +define ("LDAP_ADMIN_DN","uid=admin,".LDAP_USERS_ROOT_DN); + /* ######## Language Settings #### */ // Set the default language Modified: trunk/login.php =================================================================== --- trunk/login.php 2007-05-11 08:15:14 UTC (rev 78) +++ trunk/login.php 2007-05-15 18:11:53 UTC (rev 79) @@ -44,7 +44,7 @@ $LDAP_BINDDN = "uid=$local_part,dc=$domain,".LDAP_DOMAINDN; $LDAP_BINDPASS = $_POST["password"]; } else if (preg_match('/^admin$/',$_SESSION["username"])) { - $LDAP_BINDDN = "cn=admin,".LDAP_USERS_ROOT_DN; + $LDAP_BINDDN = LDAP_ADMIN_DN; $LDAP_BINDPASS = $_POST["password"]; } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <tux...@us...> - 2007-05-11 08:15:20
|
Revision: 78 http://elma.svn.sourceforge.net/elma/?rev=78&view=rev Author: tuxevara Date: 2007-05-11 01:15:14 -0700 (Fri, 11 May 2007) Log Message: ----------- fixed bug id 1712690: inconsistence in slapd.conf Modified Paths: -------------- trunk/doc/ldap/slapd.conf Modified: trunk/doc/ldap/slapd.conf =================================================================== --- trunk/doc/ldap/slapd.conf 2007-05-05 15:53:58 UTC (rev 77) +++ trunk/doc/ldap/slapd.conf 2007-05-11 08:15:14 UTC (rev 78) @@ -67,6 +67,6 @@ # The admin dn has full write access, everyone else # can read everything. access to attrs=userPassword - by dn="cn=admin,ou=users,o=megabit" write - by dn="cn=exim4,ou=users,o=megabit" read + by dn="cn=admin,ou=users,o=mybasedn" write + by dn="cn=exim4,ou=users,o=mybasedn" read by * none This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <tux...@us...> - 2007-05-05 15:54:02
|
Revision: 77 http://elma.svn.sourceforge.net/elma/?rev=77&view=rev Author: tuxevara Date: 2007-05-05 08:53:58 -0700 (Sat, 05 May 2007) Log Message: ----------- renamed slap.conf.dist file, dist should only be used for elma own config files Added Paths: ----------- trunk/doc/ldap/slapd.conf Removed Paths: ------------- trunk/doc/ldap/slapd.conf.dist Copied: trunk/doc/ldap/slapd.conf (from rev 76, trunk/doc/ldap/slapd.conf.dist) =================================================================== --- trunk/doc/ldap/slapd.conf (rev 0) +++ trunk/doc/ldap/slapd.conf 2007-05-05 15:53:58 UTC (rev 77) @@ -0,0 +1,72 @@ +# This is the main slapd configuration file. See slapd.conf(5) for more +# info on the configuration options. + +####################################################################### +# Global Directives: + +# Features to permit +#allow bind_v2 + +# Schema and objectClass definitions +include /etc/ldap/schema/core.schema +include /etc/ldap/schema/cosine.schema +include /etc/ldap/schema/nis.schema +include /etc/ldap/schema/inetorgperson.schema +include /etc/ldap/schema/elma-0.1.schema + +# Where the pid file is put. The init.d script +# will not stop the server if you change this. +pidfile /var/run/slapd/slapd.pid + +# List of arguments that were passed to the server +argsfile /var/run/slapd/slapd.args + +# Read slapd.conf(5) for possible values +loglevel 0 + +# Where the dynamically loaded modules are stored +modulepath /usr/lib/ldap +moduleload back_bdb + +####################################################################### +# Specific Backend Directives for bdb: +# Backend specific directives apply to this backend until another +# 'backend' directive occurs +backend bdb + +####################################################################### +# Specific Directives for database #1, of type bdb: +# Database specific directives apply to this databasse until another +# 'database' directive occurs +database bdb + +# The base of your directory in database #1 +suffix "o=mybasedn" + +# Where the database file are physically stored for database #1 +directory "/var/lib/slapd/" + +# Indexing options for database #1 +index objectClass eq + +# Save the time that the entry gets modified, for database #1 +lastmod on + +# The userPassword by default can be changed +# by the entry owning it if they are authenticated. +# Others should not be able to see it, except the +# admin entry below +# These access lines apply to database #1 only +access to attrs=userPassword,shadowLastChange + by dn="uid=admin,ou=users,o=mybasedn" write + by dn="uid=exim4,ou=users,o=mybasedn" read + by anonymous auth + by self write + by * none + +# The admin dn has full write access, everyone else +# can read everything. +access to attrs=userPassword + by dn="cn=admin,ou=users,o=megabit" write + by dn="cn=exim4,ou=users,o=megabit" read + by * none Deleted: trunk/doc/ldap/slapd.conf.dist =================================================================== --- trunk/doc/ldap/slapd.conf.dist 2007-05-05 15:52:38 UTC (rev 76) +++ trunk/doc/ldap/slapd.conf.dist 2007-05-05 15:53:58 UTC (rev 77) @@ -1,72 +0,0 @@ -# This is the main slapd configuration file. See slapd.conf(5) for more -# info on the configuration options. - -####################################################################### -# Global Directives: - -# Features to permit -#allow bind_v2 - -# Schema and objectClass definitions -include /etc/ldap/schema/core.schema -include /etc/ldap/schema/cosine.schema -include /etc/ldap/schema/nis.schema -include /etc/ldap/schema/inetorgperson.schema -include /etc/ldap/schema/elma-0.1.schema - -# Where the pid file is put. The init.d script -# will not stop the server if you change this. -pidfile /var/run/slapd/slapd.pid - -# List of arguments that were passed to the server -argsfile /var/run/slapd/slapd.args - -# Read slapd.conf(5) for possible values -loglevel 0 - -# Where the dynamically loaded modules are stored -modulepath /usr/lib/ldap -moduleload back_bdb - -####################################################################### -# Specific Backend Directives for bdb: -# Backend specific directives apply to this backend until another -# 'backend' directive occurs -backend bdb - -####################################################################### -# Specific Directives for database #1, of type bdb: -# Database specific directives apply to this databasse until another -# 'database' directive occurs -database bdb - -# The base of your directory in database #1 -suffix "o=mybasedn" - -# Where the database file are physically stored for database #1 -directory "/var/lib/slapd/" - -# Indexing options for database #1 -index objectClass eq - -# Save the time that the entry gets modified, for database #1 -lastmod on - -# The userPassword by default can be changed -# by the entry owning it if they are authenticated. -# Others should not be able to see it, except the -# admin entry below -# These access lines apply to database #1 only -access to attrs=userPassword,shadowLastChange - by dn="uid=admin,ou=users,o=mybasedn" write - by dn="uid=exim4,ou=users,o=mybasedn" read - by anonymous auth - by self write - by * none - -# The admin dn has full write access, everyone else -# can read everything. -access to attrs=userPassword - by dn="cn=admin,ou=users,o=megabit" write - by dn="cn=exim4,ou=users,o=megabit" read - by * none This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <tux...@us...> - 2007-05-05 15:52:48
|
Revision: 76 http://elma.svn.sourceforge.net/elma/?rev=76&view=rev Author: tuxevara Date: 2007-05-05 08:52:38 -0700 (Sat, 05 May 2007) Log Message: ----------- added example ldif file changed slapd.conf Modified Paths: -------------- trunk/doc/ldap/slapd.conf.dist Added Paths: ----------- trunk/doc/ldap/example.ldif Added: trunk/doc/ldap/example.ldif =================================================================== --- trunk/doc/ldap/example.ldif (rev 0) +++ trunk/doc/ldap/example.ldif 2007-05-05 15:52:38 UTC (rev 76) @@ -0,0 +1,33 @@ +dn: o=mybasedn +objectClass: top +objectClass: organization +o: mybasedn +structuralObjectClass: organization + +dn: ou=users,o=mybasedn +objectClass: top +objectClass: organizationalUnit +ou: users +structuralObjectClass: organizationalUnit + +dn: uid=admin,ou=users,o=mybasedn +uid: admin +userPassword:: e01ENX1KZVR1VHBJcE9YdHJGM2RyL09yNDV3PT0= +objectClass: account +objectClass: simpleSecurityObject +objectClass: top +structuralObjectClass: account + +dn: uid=exim4,ou=users,o=mybasedn +uid: exim4 +userPassword:: e01ENX1iNFJMbXJZL3NxUGpURmN3V2g3c1FnPT0= +objectClass: account +objectClass: simpleSecurityObject +objectClass: top +structuralObjectClass: account + +dn: ou=domains,o=mybasedn +ou: domains +objectClass: top +objectClass: organizationalUnit +structuralObjectClass: organizationalUnit Modified: trunk/doc/ldap/slapd.conf.dist =================================================================== --- trunk/doc/ldap/slapd.conf.dist 2007-05-01 21:17:43 UTC (rev 75) +++ trunk/doc/ldap/slapd.conf.dist 2007-05-05 15:52:38 UTC (rev 76) @@ -1,43 +1,72 @@ -# global config -################ +# This is the main slapd configuration file. See slapd.conf(5) for more +# info on the configuration options. +####################################################################### +# Global Directives: + +# Features to permit +#allow bind_v2 + +# Schema and objectClass definitions include /etc/ldap/schema/core.schema include /etc/ldap/schema/cosine.schema +include /etc/ldap/schema/nis.schema include /etc/ldap/schema/inetorgperson.schema include /etc/ldap/schema/elma-0.1.schema -schemacheck on +# Where the pid file is put. The init.d script +# will not stop the server if you change this. pidfile /var/run/slapd/slapd.pid + +# List of arguments that were passed to the server argsfile /var/run/slapd/slapd.args -modulepath /usr/lib/ldap -moduleload back_bdb -TLSCACertificateFile /etc/ssl/certs/cacert.pem -TLSCertificateFile /etc/ldap/slapd_cert.pem -TLSCertificateKeyFile /etc/ldap/slapd_key.pem +# Read slapd.conf(5) for possible values +loglevel 0 -TLSVerifyClient never +# Where the dynamically loaded modules are stored +modulepath /usr/lib/ldap +moduleload back_bdb -# first database -################# -backend bdb -database bdb -directory "/var/lib/slapd/" +####################################################################### +# Specific Backend Directives for bdb: +# Backend specific directives apply to this backend until another +# 'backend' directive occurs +backend bdb + +####################################################################### +# Specific Directives for database #1, of type bdb: +# Database specific directives apply to this databasse until another +# 'database' directive occurs +database bdb + +# The base of your directory in database #1 suffix "o=mybasedn" + +# Where the database file are physically stored for database #1 +directory "/var/lib/slapd/" + +# Indexing options for database #1 index objectClass eq + +# Save the time that the entry gets modified, for database #1 lastmod on - -access to attrs=userPassword - by dn="cn=admin,ou=users,o=megabit" write - by dn="cn=exim4,ou=users,o=megabit" read +# The userPassword by default can be changed +# by the entry owning it if they are authenticated. +# Others should not be able to see it, except the +# admin entry below +# These access lines apply to database #1 only +access to attrs=userPassword,shadowLastChange + by dn="uid=admin,ou=users,o=mybasedn" write + by dn="uid=exim4,ou=users,o=mybasedn" read by anonymous auth by self write by * none - -access to * +# The admin dn has full write access, everyone else +# can read everything. +access to attrs=userPassword by dn="cn=admin,ou=users,o=megabit" write by dn="cn=exim4,ou=users,o=megabit" read - by * none - + by * none This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <tux...@us...> - 2007-05-01 21:17:46
|
Revision: 75 http://elma.svn.sourceforge.net/elma/?rev=75&view=rev Author: tuxevara Date: 2007-05-01 14:17:43 -0700 (Tue, 01 May 2007) Log Message: ----------- added openldap server example config Added Paths: ----------- trunk/doc/ldap/slapd.conf.dist Added: trunk/doc/ldap/slapd.conf.dist =================================================================== --- trunk/doc/ldap/slapd.conf.dist (rev 0) +++ trunk/doc/ldap/slapd.conf.dist 2007-05-01 21:17:43 UTC (rev 75) @@ -0,0 +1,43 @@ +# global config +################ + +include /etc/ldap/schema/core.schema +include /etc/ldap/schema/cosine.schema +include /etc/ldap/schema/inetorgperson.schema +include /etc/ldap/schema/elma-0.1.schema + +schemacheck on +pidfile /var/run/slapd/slapd.pid +argsfile /var/run/slapd/slapd.args +modulepath /usr/lib/ldap +moduleload back_bdb + +TLSCACertificateFile /etc/ssl/certs/cacert.pem +TLSCertificateFile /etc/ldap/slapd_cert.pem +TLSCertificateKeyFile /etc/ldap/slapd_key.pem + +TLSVerifyClient never + +# first database +################# +backend bdb +database bdb +directory "/var/lib/slapd/" +suffix "o=mybasedn" +index objectClass eq +lastmod on + + +access to attrs=userPassword + by dn="cn=admin,ou=users,o=megabit" write + by dn="cn=exim4,ou=users,o=megabit" read + by anonymous auth + by self write + by * none + + +access to * + by dn="cn=admin,ou=users,o=megabit" write + by dn="cn=exim4,ou=users,o=megabit" read + by * none + This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <tux...@us...> - 2007-05-01 21:13:23
|
Revision: 74 http://elma.svn.sourceforge.net/elma/?rev=74&view=rev Author: tuxevara Date: 2007-05-01 14:13:21 -0700 (Tue, 01 May 2007) Log Message: ----------- complete German translation added mode parameter for gen_po.sh script Modified Paths: -------------- trunk/bin/gen_po.sh trunk/templates/simple/content_alias_delete.tpl trunk/templates/simple/content_domain_delete.tpl trunk/templates/simple/content_domain_edit.tpl trunk/templates/simple/content_user_delete.tpl trunk/templates/simple/locale/de_DE/LC_MESSAGES/messages.c trunk/templates/simple/locale/de_DE/LC_MESSAGES/messages.mo trunk/templates/simple/locale/de_DE/LC_MESSAGES/messages.po Removed Paths: ------------- trunk/templates/simple/locale/en_US/ Modified: trunk/bin/gen_po.sh =================================================================== --- trunk/bin/gen_po.sh 2007-05-01 20:44:46 UTC (rev 73) +++ trunk/bin/gen_po.sh 2007-05-01 21:13:21 UTC (rev 74) @@ -2,6 +2,7 @@ TEMPLATE=$1 LOCALE=$2 +MODE=$3 tsmarty2c.php ../templates/$TEMPLATE/*.tpl > ../templates/$TEMPLATE/locale/$LOCALE/LC_MESSAGES/messages.c -xgettext -j -C ../templates/$TEMPLATE/locale/$LOCALE/LC_MESSAGES/messages.c -o ../templates/$TEMPLATE/locale/$LOCALE/LC_MESSAGES/messages.po --keyword=_ --add-comments --from-code=utf-8 +xgettext $MODE -C ../templates/$TEMPLATE/locale/$LOCALE/LC_MESSAGES/messages.c -o ../templates/$TEMPLATE/locale/$LOCALE/LC_MESSAGES/messages.po --keyword=_ --add-comments --from-code=utf-8 Modified: trunk/templates/simple/content_alias_delete.tpl =================================================================== --- trunk/templates/simple/content_alias_delete.tpl 2007-05-01 20:44:46 UTC (rev 73) +++ trunk/templates/simple/content_alias_delete.tpl 2007-05-01 21:13:21 UTC (rev 74) @@ -1,5 +1,5 @@ <div id="Content"> - <h2>{t}Delete Alias{/t}</h2> + <h2>{t}Delete alias{/t} {$alias.uid.0}@{$domain}</h2> {if $smarty.post.submit} {include file="print_submit_status.tpl"} {else} Modified: trunk/templates/simple/content_domain_delete.tpl =================================================================== --- trunk/templates/simple/content_domain_delete.tpl 2007-05-01 20:44:46 UTC (rev 73) +++ trunk/templates/simple/content_domain_delete.tpl 2007-05-01 21:13:21 UTC (rev 74) @@ -1,5 +1,5 @@ <div id="Content"> - <h2>{t}Delete Domain{/t}</h2> + <h2>{t}Delete domain{/t} {$domain}</h2> {if $smarty.post.submit} {include file="print_submit_status.tpl"} {else} Modified: trunk/templates/simple/content_domain_edit.tpl =================================================================== --- trunk/templates/simple/content_domain_edit.tpl 2007-05-01 20:44:46 UTC (rev 73) +++ trunk/templates/simple/content_domain_edit.tpl 2007-05-01 21:13:21 UTC (rev 74) @@ -20,7 +20,7 @@ <table> {else} <fieldset> - <legend>{t}new Domain{/t}</legend> + <legend>{t}new domain{/t}</legend> <table> <tr> <td> Modified: trunk/templates/simple/content_user_delete.tpl =================================================================== --- trunk/templates/simple/content_user_delete.tpl 2007-05-01 20:44:46 UTC (rev 73) +++ trunk/templates/simple/content_user_delete.tpl 2007-05-01 21:13:21 UTC (rev 74) @@ -1,5 +1,5 @@ <div id="Content"> - <h2>{t}Delete User{/t}</h2> + <h2>{t}Delete user{/t} {$user.uid.0}@{$domain}</h2> {if $smarty.post.submit} {include file="print_submit_status.tpl"} {else} Modified: trunk/templates/simple/locale/de_DE/LC_MESSAGES/messages.c =================================================================== --- trunk/templates/simple/locale/de_DE/LC_MESSAGES/messages.c 2007-05-01 20:44:46 UTC (rev 73) +++ trunk/templates/simple/locale/de_DE/LC_MESSAGES/messages.c 2007-05-01 21:13:21 UTC (rev 74) @@ -2,66 +2,75 @@ gettext("Delete Alias"); /* ../templates/simple/content_alias_delete.tpl */ -gettext("Data saved successfully."); +gettext("Are you sure you want to delete alias %1@%2?"); /* ../templates/simple/content_alias_delete.tpl */ -gettext("Sorry, your data could not be saved. The following LDAP error occured:"); +gettext("Yes"); /* ../templates/simple/content_alias_delete.tpl */ -gettext("Are you sure you want to delete alias"); +gettext("No"); /* ../templates/simple/content_alias_edit.tpl */ -gettext("Edit Alias"); +gettext("Edit alias"); /* ../templates/simple/content_alias_edit.tpl */ -gettext("Data saved successfully."); +gettext("New alias"); /* ../templates/simple/content_alias_edit.tpl */ -gettext("Sorry, your data could not be saved. The following LDAP error occured:"); +gettext("new alias"); /* ../templates/simple/content_alias_edit.tpl */ -gettext("new Alias"); - -/* ../templates/simple/content_alias_edit.tpl */ gettext("Alias"); /* ../templates/simple/content_alias_edit.tpl */ gettext("Alias for"); +/* ../templates/simple/content_alias_edit.tpl */ +gettext("Is active?"); + +/* ../templates/simple/content_alias_edit.tpl */ +gettext("Save"); + /* ../templates/simple/content_domain_delete.tpl */ gettext("Delete Domain"); /* ../templates/simple/content_domain_delete.tpl */ -gettext("Data saved successfully."); +gettext("Are you sure you want to delete domain %1?"); /* ../templates/simple/content_domain_delete.tpl */ -gettext("Sorry, your data could not be saved. The following LDAP error occured:"); +gettext("Yes"); /* ../templates/simple/content_domain_delete.tpl */ -gettext("Are you sure you want to delete domain %1?"); +gettext("No"); /* ../templates/simple/content_domain_edit.tpl */ -gettext("Edit Domain"); +gettext("Edit domain"); /* ../templates/simple/content_domain_edit.tpl */ -gettext("Data saved successfully."); +gettext("New domain"); /* ../templates/simple/content_domain_edit.tpl */ -gettext("Sorry, your data could not be saved. The following LDAP error occured:"); +gettext("new Domain"); /* ../templates/simple/content_domain_edit.tpl */ -gettext("Status"); +gettext("Domain"); /* ../templates/simple/content_domain_edit.tpl */ -gettext("new Domain"); +gettext("Is active?"); /* ../templates/simple/content_domain_edit.tpl */ +gettext("Save"); + +/* ../templates/simple/content_domains_list.tpl */ gettext("Domain"); -/* ../templates/simple/content_domain_edit.tpl */ -gettext("Status"); +/* ../templates/simple/content_domains_list.tpl */ +gettext("Active"); /* ../templates/simple/content_domains_list.tpl */ +gettext("Command"); + +/* ../templates/simple/content_domains_list.tpl */ gettext("edit"); /* ../templates/simple/content_domains_list.tpl */ @@ -70,49 +79,64 @@ /* ../templates/simple/content_domains_list.tpl */ gettext("new domain"); +/* ../templates/simple/content_main.tpl */ +gettext("Welcome to your Exim LDAP Mail Administrator Frontend"); + +/* ../templates/simple/content_main.tpl */ +gettext("Click on the Domains link at the left navigation bar to get an overview of your email domains. When you click on the domain name you will see all users and aliases for that domain. Everything else should be pretty self explaining. Have fun ;-)"); + /* ../templates/simple/content_user_delete.tpl */ gettext("Delete User"); /* ../templates/simple/content_user_delete.tpl */ -gettext("Data saved successfully."); +gettext("Are you sure you want to delete user %1@%2?"); /* ../templates/simple/content_user_delete.tpl */ -gettext("Sorry, your data could not be saved. The following LDAP error occured:"); +gettext("Yes"); /* ../templates/simple/content_user_delete.tpl */ -gettext("Are you sure you want to delete user"); +gettext("No"); /* ../templates/simple/content_user_edit.tpl */ -gettext("Edit User"); +gettext("Edit user"); /* ../templates/simple/content_user_edit.tpl */ -gettext("Data saved successfully."); +gettext("New user"); /* ../templates/simple/content_user_edit.tpl */ -gettext("Sorry, your data could not be saved. The following LDAP error occured:"); +gettext("new user"); /* ../templates/simple/content_user_edit.tpl */ -gettext("new User"); +gettext("Username"); /* ../templates/simple/content_user_edit.tpl */ -gettext("User"); +gettext("First name"); /* ../templates/simple/content_user_edit.tpl */ -gettext("First Name"); +gettext("Last name"); /* ../templates/simple/content_user_edit.tpl */ -gettext("Last Name"); +gettext("Is active?"); /* ../templates/simple/content_user_edit.tpl */ -gettext("Status"); +gettext("Password"); /* ../templates/simple/content_user_edit.tpl */ -gettext("Password"); +gettext("Save"); /* ../templates/simple/content_users_list.tpl */ -gettext("Users for domain"); +gettext("Users and aliases for domain"); /* ../templates/simple/content_users_list.tpl */ +gettext("Username"); + +/* ../templates/simple/content_users_list.tpl */ +gettext("Active"); + +/* ../templates/simple/content_users_list.tpl */ +gettext("Command"); + +/* ../templates/simple/content_users_list.tpl */ gettext("edit"); /* ../templates/simple/content_users_list.tpl */ @@ -122,6 +146,18 @@ gettext("new user"); /* ../templates/simple/content_users_list.tpl */ +gettext("Alias"); + +/* ../templates/simple/content_users_list.tpl */ +gettext("Alias for"); + +/* ../templates/simple/content_users_list.tpl */ +gettext("Active"); + +/* ../templates/simple/content_users_list.tpl */ +gettext("Command"); + +/* ../templates/simple/content_users_list.tpl */ gettext("edit"); /* ../templates/simple/content_users_list.tpl */ @@ -131,6 +167,9 @@ gettext("new alias"); /* ../templates/simple/login.tpl */ +gettext("Invalid username and/or password."); + +/* ../templates/simple/login.tpl */ gettext("Username"); /* ../templates/simple/login.tpl */ @@ -151,3 +190,9 @@ /* ../templates/simple/navigation.tpl */ gettext("Logout"); +/* ../templates/simple/print_submit_status.tpl */ +gettext("Data has been saved."); + +/* ../templates/simple/print_submit_status.tpl */ +gettext("Sorry, your data could not be saved. The following error occured:"); + Modified: trunk/templates/simple/locale/de_DE/LC_MESSAGES/messages.mo =================================================================== (Binary files differ) Modified: trunk/templates/simple/locale/de_DE/LC_MESSAGES/messages.po =================================================================== --- trunk/templates/simple/locale/de_DE/LC_MESSAGES/messages.po 2007-05-01 20:44:46 UTC (rev 73) +++ trunk/templates/simple/locale/de_DE/LC_MESSAGES/messages.po 2007-05-01 21:13:21 UTC (rev 74) @@ -1,218 +1,264 @@ # SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the PACKAGE package. -# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR. +# Copyright (C) 2007 Daniel Weuthen +# This file is distributed under the same license as the elma package. +# Daniel Weuthen <da...@we...>, 2007. # #, fuzzy msgid "" msgstr "" -"Project-Id-Version: PACKAGE VERSION\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2007-04-22 22:58+0200\n" -"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" -"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" -"Language-Team: LANGUAGE <LL...@li...>\n" +"Project-Id-Version: 0.1\n" +"Report-Msgid-Bugs-To: da...@we...\n" +"POT-Creation-Date: 2007-05-01 16:51+0200\n" +"PO-Revision-Date: 2007-05-01 16:51+0200\n" +"Last-Translator: Daniel Weuthen <da...@we...>\n" +"Language-Team: de_DE <da...@we...>\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" #. ../templates/simple/content_alias_delete.tpl #: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:2 -msgid "Delete Alias" -msgstr "" +msgid "Delete alias" +msgstr "Lösche Alias" #. ../templates/simple/content_alias_delete.tpl -#. ../templates/simple/content_alias_edit.tpl -#. ../templates/simple/content_domain_delete.tpl -#. ../templates/simple/content_domain_edit.tpl -#. ../templates/simple/content_user_delete.tpl -#. ../templates/simple/content_user_edit.tpl #: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:5 -#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:17 -#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:35 -#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:47 -#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:77 -#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:89 -msgid "Data saved successfully." -msgstr "" +msgid "Are you sure you want to delete alias %1@%2?" +msgstr "Sind Sie sicher, daß Sie den Alias %1@%2 löschen wollen?" #. ../templates/simple/content_alias_delete.tpl -#. ../templates/simple/content_alias_edit.tpl #. ../templates/simple/content_domain_delete.tpl -#. ../templates/simple/content_domain_edit.tpl #. ../templates/simple/content_user_delete.tpl -#. ../templates/simple/content_user_edit.tpl #: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:8 -#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:20 -#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:38 -#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:50 -#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:80 -#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:92 -msgid "Sorry, your data could not be saved. The following LDAP error occured:" -msgstr "" +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:41 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:95 +msgid "Yes" +msgstr "Ja" #. ../templates/simple/content_alias_delete.tpl +#. ../templates/simple/content_domain_delete.tpl +#. ../templates/simple/content_user_delete.tpl #: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:11 -msgid "Are you sure you want to delete alias" -msgstr "" +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:44 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:98 +msgid "No" +msgstr "Nein" #. ../templates/simple/content_alias_edit.tpl #: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:14 -msgid "Edit Alias" -msgstr "" +msgid "Edit alias" +msgstr "Bearbeite Alias" #. ../templates/simple/content_alias_edit.tpl +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:17 +msgid "New alias" +msgstr "Neuer Alias" + +#. ../templates/simple/content_alias_edit.tpl +#. ../templates/simple/content_users_list.tpl +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:20 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:167 +msgid "new alias" +msgstr "neuer Alias" + +#. ../templates/simple/content_alias_edit.tpl +#. ../templates/simple/content_users_list.tpl #: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:23 -msgid "new Alias" -msgstr "" +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:149 +msgid "Alias" +msgstr "Alias" #. ../templates/simple/content_alias_edit.tpl +#. ../templates/simple/content_users_list.tpl #: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:26 -msgid "Alias" -msgstr "" +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:152 +msgid "Alias for" +msgstr "Alias für" #. ../templates/simple/content_alias_edit.tpl +#. ../templates/simple/content_domain_edit.tpl +#. ../templates/simple/content_user_edit.tpl #: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:29 -msgid "Alias for" -msgstr "" +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:59 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:119 +msgid "Is active?" +msgstr "Akitiviert?" -#. ../templates/simple/content_domain_delete.tpl +#. ../templates/simple/content_alias_edit.tpl +#. ../templates/simple/content_domain_edit.tpl +#. ../templates/simple/content_user_edit.tpl #: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:32 -msgid "Delete Domain" -msgstr "" +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:62 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:125 +msgid "Save" +msgstr "Speichern" #. ../templates/simple/content_domain_delete.tpl -#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:41 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:35 +msgid "Delete domain" +msgstr "Domäne löschen" + +#. ../templates/simple/content_domain_delete.tpl +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:38 msgid "Are you sure you want to delete domain %1?" -msgstr "Sind sie Sicher, dass Sie die Domaene %1 loeschen wollen?" +msgstr "Sind Sie sicher, daß Sie die Domäne %1 löschen wollen?" #. ../templates/simple/content_domain_edit.tpl -#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:44 -msgid "Edit Domain" -msgstr "" +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:47 +msgid "Edit domain" +msgstr "Domäne bearbeiten" #. ../templates/simple/content_domain_edit.tpl -#. ../templates/simple/content_user_edit.tpl #: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:53 -#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:62 -#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:107 -msgid "Status" -msgstr "" +msgid "new domain" +msgstr "neue Domäne" #. ../templates/simple/content_domain_edit.tpl +#. ../templates/simple/content_domains_list.tpl #: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:56 -msgid "new Domain" -msgstr "" - -#. ../templates/simple/content_domain_edit.tpl -#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:59 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:65 msgid "Domain" -msgstr "" +msgstr "Domäne" #. ../templates/simple/content_domains_list.tpl #. ../templates/simple/content_users_list.tpl -#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:65 -#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:116 -#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:125 -msgid "edit" -msgstr "" +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:68 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:134 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:155 +msgid "Active" +msgstr "Aktiviert" #. ../templates/simple/content_domains_list.tpl #. ../templates/simple/content_users_list.tpl -#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:68 -#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:119 -#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:128 -msgid "delete" -msgstr "" +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:71 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:137 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:158 +msgid "Command" +msgstr "Befehl" #. ../templates/simple/content_domains_list.tpl -#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:71 -msgid "new domain" -msgstr "" - -#. ../templates/simple/content_user_delete.tpl +#. ../templates/simple/content_users_list.tpl #: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:74 -msgid "Delete User" -msgstr "" +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:140 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:161 +msgid "edit" +msgstr "bearbeiten" -#. ../templates/simple/content_user_delete.tpl +#. ../templates/simple/content_domains_list.tpl +#. ../templates/simple/content_users_list.tpl +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:77 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:143 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:164 +msgid "delete" +msgstr "löschen" + +#. ../templates/simple/content_main.tpl #: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:83 -msgid "Are you sure you want to delete user" -msgstr "" +msgid "Welcome to your Exim LDAP Mail Administrator Frontend" +msgstr "Willkommen zu Ihrem Exim LDAP Mail Administrator" -#. ../templates/simple/content_user_edit.tpl +#. ../templates/simple/content_main.tpl #: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:86 -msgid "Edit User" +msgid "" +"Click on the Domains link at the left navigation bar to get an overview of " +"your email domains. When you click on the domain name you will see all users " +"and aliases for that domain. Everything else should be pretty self " +"explaining. Have fun ;-)" msgstr "" +"Klicken Sie auf den Link Domänen in der linken Navigationsleiste um einen" +"Überblick Ihrer Domänen yu erhalten. Klicken Sie dann auf den Domänennamen" +"um eine Benutzerübersicht zu erhalten. Alles andere sollte relativ" +"selbsterklärend sein. Viel Spaß ;-)" -#. ../templates/simple/content_user_edit.tpl -#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:95 -msgid "new User" -msgstr "" +#. ../templates/simple/content_user_delete.tpl +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:92 +msgid "Are you sure you want to delete user %1@%2?" +msgstr "Sind Sie sicher, daß Sie den Benutzer %1@%2 löschen wollen?" #. ../templates/simple/content_user_edit.tpl -#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:98 -msgid "User" -msgstr "" - -#. ../templates/simple/content_user_edit.tpl #: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:101 -msgid "First Name" -msgstr "" +msgid "Edit user" +msgstr "Bearbeite Benutzer" #. ../templates/simple/content_user_edit.tpl #: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:104 -msgid "Last Name" -msgstr "" +msgid "New user" +msgstr "Neuer Benutzer" #. ../templates/simple/content_user_edit.tpl +#. ../templates/simple/content_users_list.tpl +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:107 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:146 +msgid "new user" +msgstr "neuer Benutzer" + +#. ../templates/simple/content_user_edit.tpl +#. ../templates/simple/content_users_list.tpl #. ../templates/simple/login.tpl #: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:110 -#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:137 -msgid "Password" -msgstr "" +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:131 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:173 +msgid "Username" +msgstr "Benutzername" -#. ../templates/simple/content_users_list.tpl +#. ../templates/simple/content_user_edit.tpl #: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:113 -msgid "Users for domain" -msgstr "" +msgid "First name" +msgstr "Vorname" -#. ../templates/simple/content_users_list.tpl +#. ../templates/simple/content_user_edit.tpl +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:116 +msgid "Last name" +msgstr "Nachname" + +#. ../templates/simple/content_user_edit.tpl +#. ../templates/simple/login.tpl #: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:122 -msgid "new user" -msgstr "" +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:176 +msgid "Password" +msgstr "Passwort" #. ../templates/simple/content_users_list.tpl -#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:131 -msgid "new alias" -msgstr "" +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:128 +msgid "Users and aliases for domain" +msgstr "Benutzer und Aliase für Domäne" #. ../templates/simple/login.tpl -#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:134 -msgid "Username" -msgstr "" +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:170 +msgid "Invalid username and/or password." +msgstr "Ungültiger Benutzername und/oder Passwort." #. ../templates/simple/login.tpl -#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:140 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:179 msgid "Language" -msgstr "" +msgstr "Sprache" #. ../templates/simple/login.tpl -#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:143 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:182 msgid "Login" -msgstr "" +msgstr "Anmelden" #. ../templates/simple/navigation.tpl -#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:146 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:185 msgid "Home" -msgstr "" +msgstr "Übersicht" #. ../templates/simple/navigation.tpl -#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:149 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:188 msgid "Domains" -msgstr "" +msgstr "Domänen" #. ../templates/simple/navigation.tpl -#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:152 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:191 msgid "Logout" -msgstr "" +msgstr "Abmelden" + +#. ../templates/simple/print_submit_status.tpl +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:194 +msgid "Data has been saved." +msgstr "Daten wurden gespeichert." + +#. ../templates/simple/print_submit_status.tpl +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:197 +msgid "Sorry, your data could not be saved. The following error occured:" +msgstr "Leider konnten Ihre Daten nicht gespeichert werden. Folgender Fehler ist aufgetreten:" This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <tux...@us...> - 2007-05-01 20:44:48
|
Revision: 73 http://elma.svn.sourceforge.net/elma/?rev=73&view=rev Author: tuxevara Date: 2007-05-01 13:44:46 -0700 (Tue, 01 May 2007) Log Message: ----------- text work Modified Paths: -------------- trunk/templates/simple/content_alias_edit.tpl trunk/templates/simple/content_domain_edit.tpl trunk/templates/simple/content_domains_list.tpl trunk/templates/simple/content_main.tpl trunk/templates/simple/content_user_edit.tpl Modified: trunk/templates/simple/content_alias_edit.tpl =================================================================== --- trunk/templates/simple/content_alias_edit.tpl 2007-04-30 22:10:20 UTC (rev 72) +++ trunk/templates/simple/content_alias_edit.tpl 2007-05-01 20:44:46 UTC (rev 73) @@ -1,8 +1,8 @@ <div id="Content"> {if $mode == "modify"} - <h2>{t}Edit Alias{/t}</h2> + <h2>{t}Edit alias{/t} {$alias.uid.0}@{$domain}</h2> {else} - <h2>{t}New Alias{/t}</h2> + <h2>{t}New alias{/t}</h2> {/if} {if $smarty.post.submit} {include file="print_submit_status.tpl"} @@ -21,7 +21,7 @@ </td> </tr> {else} - <legend>{t}new Alias{/t}</legend> + <legend>{t}new alias{/t}</legend> <table> <tr> <td> Modified: trunk/templates/simple/content_domain_edit.tpl =================================================================== --- trunk/templates/simple/content_domain_edit.tpl 2007-04-30 22:10:20 UTC (rev 72) +++ trunk/templates/simple/content_domain_edit.tpl 2007-05-01 20:44:46 UTC (rev 73) @@ -1,8 +1,8 @@ <div id="Content"> {if $mode == "modify"} - <h2>{t}Edit Domain{/t}</h2> + <h2>{t }Edit domain{/t} {$domain.dc.0}</h2> {else} - <h2>{t}New Domain{/t}</h2> + <h2>{t}New domain{/t}</h2> {/if} {if $smarty.post.submit} {include file="print_submit_status.tpl"} @@ -18,20 +18,6 @@ <fieldset> <legend>{$domain.dc.0}</legend> <table> - <tr> - <td> - {t}Is active?{/t} - </td> - <td> - <input type="checkbox" name="mailstatus" {if $domain.mailstatus.0 eq "TRUE"}checked="checked"{/if} /> - </td> - </tr> - <tr> - <td> </td> - <td><input type="submit" name="submit" value="{t}Save{/t}" /></td> - </tr> - </table> - </fieldset> {else} <fieldset> <legend>{t}new Domain{/t}</legend> @@ -44,23 +30,21 @@ <input type="text" name="dc" /> </td> </tr> - <tr> - <td> - {t}Status{/t} - </td> - <td> - <input type="checkbox" name="mailstatus" checked="checked" /> - </td> - </tr> - <tr> - <td> </td> - <td> - <input type="submit" name="submit" value="{t}Save{/t}"/> - </td> - </tr> - </table> - </fieldset> {/if} + <tr> + <td> + {t}Is active?{/t} + </td> + <td> + <input type="checkbox" name="mailstatus" {if $domain.mailstatus.0 eq "FALSE"}{else}checked="checked"{/if} /> + </td> + </tr> + <tr> + <td> </td> + <td><input type="submit" name="submit" value="{t}Save{/t}" /></td> + </tr> + </table> + </fieldset> </form> </div> Modified: trunk/templates/simple/content_domains_list.tpl =================================================================== --- trunk/templates/simple/content_domains_list.tpl 2007-04-30 22:10:20 UTC (rev 72) +++ trunk/templates/simple/content_domains_list.tpl 2007-05-01 20:44:46 UTC (rev 73) @@ -1,5 +1,5 @@ <div id="Content"> - <h2>Domains</h2> + <h2>Domain overview</h2> <table> <tr> <th>{t}Domain{/t}</th> Modified: trunk/templates/simple/content_main.tpl =================================================================== --- trunk/templates/simple/content_main.tpl 2007-04-30 22:10:20 UTC (rev 72) +++ trunk/templates/simple/content_main.tpl 2007-05-01 20:44:46 UTC (rev 73) @@ -1,5 +1,5 @@ <div id="Content"> <h2>{t}Welcome to your Exim LDAP Mail Administrator Frontend{/t}</h2> - <p>{t}Click on the Domain link at the left navigation bar to get an overview of your email domains. Wehen you click on the domain name you will see all users and aliases for that domain. everything else should be pretty self explaining. Have fun.{/t}</p> + <p>{t}Click on the Domains link at the left navigation bar to get an overview of your email domains. When you click on the domain name you will see all users and aliases for that domain. Everything else should be pretty self explaining. Have fun ;-){/t}</p> </div> Modified: trunk/templates/simple/content_user_edit.tpl =================================================================== --- trunk/templates/simple/content_user_edit.tpl 2007-04-30 22:10:20 UTC (rev 72) +++ trunk/templates/simple/content_user_edit.tpl 2007-05-01 20:44:46 UTC (rev 73) @@ -1,8 +1,8 @@ <div id="Content"> {if $mode == "modify"} - <h2>{t}Edit User{/t}</h2> + <h2>{t}Edit user{/t} {$user.uid.0}@{$domain}</h2> {else} - <h2>{t}New User{/t}</h2> + <h2>{t}New user{/t}</h2> {/if} {if $smarty.post.submit} {include file="print_submit_status.tpl"} @@ -21,11 +21,11 @@ </td> </tr> {else} - <legend>{t}new User{/t}</legend> + <legend>{t}new user{/t}</legend> <table> <tr> <td> - {t}User{/t} + {t}Username{/t} </td> <td> <input type="text" name="uid" value="{$user.uid.0}" />@{$domain} @@ -34,7 +34,7 @@ {/if} <tr> <td> - {t}First Name{/t} + {t}First name{/t} </td> <td> <input type="text" name="cn" value="{$user.cn.0}" /> @@ -42,7 +42,7 @@ </tr> <tr> <td> - {t}Last Name{/t} + {t}Last name{/t} </td> <td> <input type="text" name="sn" value="{$user.sn.0}" /> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <tux...@us...> - 2007-04-30 22:10:22
|
Revision: 72 http://elma.svn.sourceforge.net/elma/?rev=72&view=rev Author: tuxevara Date: 2007-04-30 15:10:20 -0700 (Mon, 30 Apr 2007) Log Message: ----------- updated version counter Modified Paths: -------------- trunk/VERSION Modified: trunk/VERSION =================================================================== --- trunk/VERSION 2007-04-30 22:08:34 UTC (rev 71) +++ trunk/VERSION 2007-04-30 22:10:20 UTC (rev 72) @@ -1 +1 @@ -0.1-beta +0.1 This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <tux...@us...> - 2007-04-30 22:08:42
|
Revision: 71 http://elma.svn.sourceforge.net/elma/?rev=71&view=rev Author: tuxevara Date: 2007-04-30 15:08:34 -0700 (Mon, 30 Apr 2007) Log Message: ----------- Changelog added to make elma ready on its way to 0.1 Added Paths: ----------- trunk/changelog Added: trunk/changelog =================================================================== --- trunk/changelog (rev 0) +++ trunk/changelog 2007-04-30 22:08:34 UTC (rev 71) @@ -0,0 +1,7 @@ +2007-05-01 Daniel Weuthen <da...@we...> + * Initial release: consider this software to be in alpha stadium + +# vim: et ts=4 sw=4 sts=4 +# vim: ft=changelog fenc=utf-8 encoding=utf-8 +# vim: fde=getline(v\:lnum-1)=~'^\\s*$'&&getline(v\:lnum)=~'\\S'?'>1'\:1&&v\:lnum>8&&getline(v\:lnum)!~'^#' +# vim: fdn=1 fdm=expr This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <tux...@us...> - 2007-04-30 21:52:17
|
Revision: 70 http://elma.svn.sourceforge.net/elma/?rev=70&view=rev Author: tuxevara Date: 2007-04-30 14:52:11 -0700 (Mon, 30 Apr 2007) Log Message: ----------- based on a quick tested config Modified Paths: -------------- trunk/doc/exim4/exim4.conf.dist Modified: trunk/doc/exim4/exim4.conf.dist =================================================================== --- trunk/doc/exim4/exim4.conf.dist 2007-04-30 15:55:31 UTC (rev 69) +++ trunk/doc/exim4/exim4.conf.dist 2007-04-30 21:52:11 UTC (rev 70) @@ -49,46 +49,6 @@ domainlist relay_to_domains = hostlist relay_from_hosts = 127.0.0.1 -# Most straightforward access control requirements can be obtained by -# appropriate settings of the above options. In more complicated situations, -# you may need to modify the Access Control List (ACL) which appears later in -# this file. - -# The first setting specifies your local domains, for example: -# -# domainlist local_domains = my.first.domain : my.second.domain -# -# You can use "@" to mean "the name of the local host", as in the default -# setting above. This is the name that is specified by primary_hostname, -# as specified above (or defaulted). If you do not want to do any local -# deliveries, remove the "@" from the setting above. If you want to accept mail -# addressed to your host's literal IP address, for example, mail addressed to -# "user@[192.168.23.44]", you can add "@[]" as an item in the local domains -# list. You also need to uncomment "allow_domain_literals" below. This is not -# recommended for today's Internet. - -# The second setting specifies domains for which your host is an incoming relay. -# If you are not doing any relaying, you should leave the list empty. However, -# if your host is an MX backup or gateway of some kind for some domains, you -# must set relay_to_domains to match those domains. For example: -# -# domainlist relay_to_domains = *.myco.com : my.friend.org -# -# This will allow any host to relay through your host to those domains. -# See the section of the manual entitled "Control of relaying" for more -# information. - -# The third setting specifies hosts that can use your host as an outgoing relay -# to any other host on the Internet. Such a setting commonly refers to a -# complete local network as well as the localhost. For example: -# -# hostlist relay_from_hosts = 127.0.0.1 : 192.168.0.0/16 -# -# The "/16" is a bit mask (CIDR notation), not a number of hosts. Note that you -# have to include 127.0.0.1 if you want to allow processes on your host to send -# SMTP mail by using the loopback address. A number of MUAs use this method of -# sending mail. - # All three of these lists may contain many different kinds of item, including # wildcarded names, regular expressions, and file lookups. See the reference # manual for details. The lists above are used in the access control lists for @@ -623,14 +583,14 @@ driver = plaintext public_name = PLAIN server_prompts = : - server_condition = ${if ldapauth {user="uid=${extract{1}{@}{$2}},dc=${extract{2}{@}{$2}},LDAP_DOMAINS_ROOT_DN" pass=${quote:$3} ldap://LDAP_HOSTNAME/}{yes}{no}} + server_condition = ${if ldapauth {user="uid=${quote_ldap_dn:${extract{1}{@}{$2}}},dc=${quote_ldap_dn:${extract{2}{@}{$2}}},LDAP_DOMAINS_ROOT_DN" pass=${quote_ldap_dn::$3} ldap://LDAP_HOSTNAME/}{yes}{no}} server_set_id = $2 login: driver = plaintext public_name = LOGIN server_prompts = Username:: : Password:: - server_condition = ${if ldapauth {user="uid=${extract{1}{@}{$1}},dc=${extract{2}{@}{$1}},LDAP_DOMAINS_ROOT_DN" pass=${quote:$2} ldap://LDAP_HOSTNAME/}{yes}{no}} + server_condition = ${if ldapauth {user="uid=${quote_ldap_dn:${extract{1}{@}{$1}}},dc=${quote_ldap_dn:${extract{2}{@}{$1}}},LDAP_DOMAINS_ROOT_DN" pass=${quote_ldap_dn:$2} ldap://LDAP_HOSTNAME/}{yes}{no}} server_set_id = $1 cram: This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <tux...@us...> - 2007-04-30 15:55:32
|
Revision: 69 http://elma.svn.sourceforge.net/elma/?rev=69&view=rev Author: tuxevara Date: 2007-04-30 08:55:31 -0700 (Mon, 30 Apr 2007) Log Message: ----------- ignore local exim4.conf files in that directory Property Changed: ---------------- trunk/doc/exim4/ Property changes on: trunk/doc/exim4 ___________________________________________________________________ Name: svn:ignore + exim4.conf This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <tux...@us...> - 2007-04-30 15:51:32
|
Revision: 68 http://elma.svn.sourceforge.net/elma/?rev=68&view=rev Author: tuxevara Date: 2007-04-30 08:51:29 -0700 (Mon, 30 Apr 2007) Log Message: ----------- added exim4.conf.dist Added Paths: ----------- trunk/doc/exim4/ trunk/doc/exim4/exim4.conf.dist Added: trunk/doc/exim4/exim4.conf.dist =================================================================== --- trunk/doc/exim4/exim4.conf.dist (rev 0) +++ trunk/doc/exim4/exim4.conf.dist 2007-04-30 15:51:29 UTC (rev 68) @@ -0,0 +1,655 @@ +########### IMPORTANT ########## IMPORTANT ########### IMPORTANT ########### +# # +# Whenever you change Exim's configuration file, you *must* remember to # +# HUP the Exim daemon, because it will not pick up the new configuration # +# until you do. However, any other Exim processes that are started, for # +# example, a process started by an MUA in order to send a message, will # +# see the new configuration as soon as it is in place. # +# # +# You do not need to HUP the daemon for changes in auxiliary files that # +# are referenced from this file. They are read every time they are used. # +# # +# It is usually a good idea to test a new configuration for syntactic # +# correctness before installing it (for example, by running the command # +# "exim -C /config/file.new -bV"). # +# # +########### IMPORTANT ########## IMPORTANT ########### IMPORTANT ########### + + + +###################################################################### +# MAIN CONFIGURATION SETTINGS # +###################################################################### + +LDAP_HOSTNAME = 127.0.0.1:389 +LDAP_BASEDN = o=mybasedn +LDAP_DOMAINS_ROOT_DN = ou=domains,LDAP_BASEDN +LDAP_USERS_ROOT_DN = ou=users,LDAP_BASEDN +LDAP_USER = cn=exim,LDAP_USERS_ROOT_DN +LDAP_PASS = eximusersldappass +LDAP_DEFAULT_SERVERS = 127.0.0.1::389 + +MAILHOME = /var/mailhome + + +# Specify your host's canonical name here. This should normally be the fully +# qualified "official" name of your host. If this option is not set, the +# uname() function is called to obtain the name. In many cases this does +# the right thing and you need not set anything explicitly. + +# primary_hostname = + + +# The next three settings create two lists of domains and one list of hosts. +# These lists are referred to later in this configuration using the syntax +# +local_domains, +relay_to_domains, and +relay_from_hosts, respectively. They +# are all colon-separated lists: + +domainlist local_domains = @ : ${tr {${lookup ldapm{user=LDAP_USER pass=LDAP_PASS ldap://LDAP_HOSTNAME/LDAP_DOMAINS_ROOT_DN?dc?one}}} {\n}{:}} +domainlist relay_to_domains = +hostlist relay_from_hosts = 127.0.0.1 + +# Most straightforward access control requirements can be obtained by +# appropriate settings of the above options. In more complicated situations, +# you may need to modify the Access Control List (ACL) which appears later in +# this file. + +# The first setting specifies your local domains, for example: +# +# domainlist local_domains = my.first.domain : my.second.domain +# +# You can use "@" to mean "the name of the local host", as in the default +# setting above. This is the name that is specified by primary_hostname, +# as specified above (or defaulted). If you do not want to do any local +# deliveries, remove the "@" from the setting above. If you want to accept mail +# addressed to your host's literal IP address, for example, mail addressed to +# "user@[192.168.23.44]", you can add "@[]" as an item in the local domains +# list. You also need to uncomment "allow_domain_literals" below. This is not +# recommended for today's Internet. + +# The second setting specifies domains for which your host is an incoming relay. +# If you are not doing any relaying, you should leave the list empty. However, +# if your host is an MX backup or gateway of some kind for some domains, you +# must set relay_to_domains to match those domains. For example: +# +# domainlist relay_to_domains = *.myco.com : my.friend.org +# +# This will allow any host to relay through your host to those domains. +# See the section of the manual entitled "Control of relaying" for more +# information. + +# The third setting specifies hosts that can use your host as an outgoing relay +# to any other host on the Internet. Such a setting commonly refers to a +# complete local network as well as the localhost. For example: +# +# hostlist relay_from_hosts = 127.0.0.1 : 192.168.0.0/16 +# +# The "/16" is a bit mask (CIDR notation), not a number of hosts. Note that you +# have to include 127.0.0.1 if you want to allow processes on your host to send +# SMTP mail by using the loopback address. A number of MUAs use this method of +# sending mail. + +# All three of these lists may contain many different kinds of item, including +# wildcarded names, regular expressions, and file lookups. See the reference +# manual for details. The lists above are used in the access control lists for +# checking incoming messages. The names of these ACLs are defined here: + +acl_smtp_rcpt = acl_check_rcpt +acl_smtp_data = acl_check_data + +# You should not change those settings until you understand how ACLs work. + + +# If you are running a version of Exim that was compiled with the content- +# scanning extension, you can cause incoming messages to be automatically +# scanned for viruses. You have to modify the configuration in two places to +# set this up. The first of them is here, where you define the interface to +# your scanner. This example is typical for ClamAV; see the manual for details +# of what to set for other virus scanners. The second modification is in the +# acl_check_data access control list (see below). + +# av_scanner = clamd:/tmp/clamd + + +# For spam scanning, there is a similar option that defines the interface to +# SpamAssassin. You do not need to set this if you are using the default, which +# is shown in this commented example. As for virus scanning, you must also +# modify the acl_check_data access control list to enable spam scanning. + +# spamd_address = 127.0.0.1 783 + + +# If Exim is compiled with support for TLS, you may want to enable the +# following options so that Exim allows clients to make encrypted +# connections. In the authenticators section below, there are template +# configurations for plaintext username/password authentication. This kind +# of authentication is only safe when used within a TLS connection, so the +# authenticators will only work if the following TLS settings are turned on +# as well. + +# Allow any client to use TLS. + +# tls_advertise_hosts = * + +# Specify the location of the Exim server's TLS certificate and private key. +# The private key must not be encrypted (password protected). You can put +# the certificate and private key in the same file, in which case you only +# need the first setting, or in separate files, in which case you need both +# options. + +# tls_certificate = /etc/ssl/exim.crt +# tls_privatekey = /etc/ssl/exim.pem + +# In order to support roaming users who wish to send email from anywhere, +# you may want to make Exim listen on other ports as well as port 25, in +# case these users need to send email from a network that blocks port 25. +# The standard port for this purpose is port 587, the "message submission" +# port. See RFC 4409 for details. Microsoft MUAs cannot be configured to +# talk the message submission protocol correctly, so if you need to support +# them you should also allow TLS-on-connect on the traditional but +# non-standard port 465. + +# daemon_smtp_ports = 25 : 465 : 587 +# tls_on_connect_ports = 465 + + +# Specify the domain you want to be added to all unqualified addresses +# here. An unqualified address is one that does not contain an "@" character +# followed by a domain. For example, "caesar@rome.example" is a fully qualified +# address, but the string "caesar" (i.e. just a login name) is an unqualified +# email address. Unqualified addresses are accepted only from local callers by +# default. See the recipient_unqualified_hosts option if you want to permit +# unqualified addresses from remote sources. If this option is not set, the +# primary_hostname value is used for qualification. + +# qualify_domain = + + +# If you want unqualified recipient addresses to be qualified with a different +# domain to unqualified sender addresses, specify the recipient domain here. +# If this option is not set, the qualify_domain value is used. + +# qualify_recipient = + + +# The following line must be uncommented if you want Exim to recognize +# addresses of the form "user@[10.11.12.13]" that is, with a "domain literal" +# (an IP address) instead of a named domain. The RFCs still require this form, +# but it makes little sense to permit mail to be sent to specific hosts by +# their IP address in the modern Internet. This ancient format has been used +# by those seeking to abuse hosts by using them for unwanted relaying. If you +# really do want to support domain literals, uncomment the following line, and +# see also the "domain_literal" router below. + +# allow_domain_literals + + +# No deliveries will ever be run under the uids of these users (a colon- +# separated list). An attempt to do so causes a panic error to be logged, and +# the delivery to be deferred. This is a paranoic safety catch. There is an +# even stronger safety catch in the form of the FIXED_NEVER_USERS setting +# in the configuration for building Exim. The list of users that it specifies +# is built into the binary, and cannot be changed. The option below just adds +# additional users to the list. The default for FIXED_NEVER_USERS is "root", +# but just to be absolutely sure, the default here is also "root". + +# Note that the default setting means you cannot deliver mail addressed to root +# as if it were a normal user. This isn't usually a problem, as most sites have +# an alias for root that redirects such mail to a human administrator. + +never_users = root + + +# The setting below causes Exim to do a reverse DNS lookup on all incoming +# IP calls, in order to get the true host name. If you feel this is too +# expensive, you can specify the networks for which a lookup is done, or +# remove the setting entirely. + +host_lookup = * + + +# The settings below, which are actually the same as the defaults in the +# code, cause Exim to make RFC 1413 (ident) callbacks for all incoming SMTP +# calls. You can limit the hosts to which these calls are made, and/or change +# the timeout that is used. If you set the timeout to zero, all RFC 1413 calls +# are disabled. RFC 1413 calls are cheap and can provide useful information +# for tracing problem messages, but some hosts and firewalls have problems +# with them. This can result in a timeout instead of an immediate refused +# connection, leading to delays on starting up SMTP sessions. (The default was +# reduced from 30s to 5s for release 4.61.) + +rfc1413_hosts = * +rfc1413_query_timeout = 5s + + +# By default, Exim expects all envelope addresses to be fully qualified, that +# is, they must contain both a local part and a domain. If you want to accept +# unqualified addresses (just a local part) from certain hosts, you can specify +# these hosts by setting one or both of +# +# sender_unqualified_hosts = +# recipient_unqualified_hosts = +# +# to control sender and recipient addresses, respectively. When this is done, +# unqualified addresses are qualified using the settings of qualify_domain +# and/or qualify_recipient (see above). + + +# If you want Exim to support the "percent hack" for certain domains, +# uncomment the following line and provide a list of domains. The "percent +# hack" is the feature by which mail addressed to x%y@z (where z is one of +# the domains listed) is locally rerouted to x@y and sent on. If z is not one +# of the "percent hack" domains, x%y is treated as an ordinary local part. This +# hack is rarely needed nowadays; you should not enable it unless you are sure +# that you really need it. +# +# percent_hack_domains = +# +# As well as setting this option you will also need to remove the test +# for local parts containing % in the ACL definition below. + + +# When Exim can neither deliver a message nor return it to sender, it "freezes" +# the delivery error message (aka "bounce message"). There are also other +# circumstances in which messages get frozen. They will stay on the queue for +# ever unless one of the following options is set. + +# This option unfreezes frozen bounce messages after two days, tries +# once more to deliver them, and ignores any delivery failures. + +ignore_bounce_errors_after = 2d + +# This option cancels (removes) frozen messages that are older than a week. + +timeout_frozen_after = 7d + + + +###################################################################### +# ACL CONFIGURATION # +# Specifies access control lists for incoming SMTP mail # +###################################################################### + +begin acl + +# This access control list is used for every RCPT command in an incoming +# SMTP message. The tests are run in order until the address is either +# accepted or denied. + +acl_check_rcpt: + + # Accept if the source is local SMTP (i.e. not over TCP/IP). We do this by + # testing for an empty sending host field. + + accept hosts = : + + ############################################################################# + # The following section of the ACL is concerned with local parts that contain + # @ or % or ! or / or | or dots in unusual places. + # + # The characters other than dots are rarely found in genuine local parts, but + # are often tried by people looking to circumvent relaying restrictions. + # Therefore, although they are valid in local parts, these rules lock them + # out, as a precaution. + # + # Empty components (two dots in a row) are not valid in RFC 2822, but Exim + # allows them because they have been encountered. (Consider local parts + # constructed as "firstinitial.secondinitial.familyname" when applied to + # someone like me, who has no second initial.) However, a local part starting + # with a dot or containing /../ can cause trouble if it is used as part of a + # file name (e.g. for a mailing list). This is also true for local parts that + # contain slashes. A pipe symbol can also be troublesome if the local part is + # incorporated unthinkingly into a shell command line. + # + # Two different rules are used. The first one is stricter, and is applied to + # messages that are addressed to one of the local domains handled by this + # host. The line "domains = +local_domains" restricts it to domains that are + # defined by the "domainlist local_domains" setting above. The rule blocks + # local parts that begin with a dot or contain @ % ! / or |. If you have + # local accounts that include these characters, you will have to modify this + # rule. + + deny message = Restricted characters in address + domains = +local_domains + local_parts = ^[.] : ^.*[@%!/|] + + # The second rule applies to all other domains, and is less strict. The line + # "domains = !+local_domains" restricts it to domains that are NOT defined by + # the "domainlist local_domains" setting above. The exclamation mark is a + # negating operator. This rule allows your own users to send outgoing + # messages to sites that use slashes and vertical bars in their local parts. + # It blocks local parts that begin with a dot, slash, or vertical bar, but + # allows these characters within the local part. However, the sequence /../ + # is barred. The use of @ % and ! is blocked, as before. The motivation here + # is to prevent your users (or your users' viruses) from mounting certain + # kinds of attack on remote sites. + + deny message = Restricted characters in address + domains = !+local_domains + local_parts = ^[./|] : ^.*[@%!] : ^.*/\\.\\./ + ############################################################################# + + # Accept mail to postmaster in any local domain, regardless of the source, + # and without verifying the sender. + + accept local_parts = postmaster + domains = +local_domains + + # Deny unless the sender address can be verified. + + require verify = sender + + # Accept if the message comes from one of the hosts for which we are an + # outgoing relay. It is assumed that such hosts are most likely to be MUAs, + # so we set control=submission to make Exim treat the message as a + # submission. It will fix up various errors in the message, for example, the + # lack of a Date: header line. If you are actually relaying out out from + # MTAs, you may want to disable this. If you are handling both relaying from + # MTAs and submissions from MUAs you should probably split them into two + # lists, and handle them differently. + + # Recipient verification is omitted here, because in many cases the clients + # are dumb MUAs that don't cope well with SMTP error responses. If you are + # actually relaying out from MTAs, you should probably add recipient + # verification here. + + # Note that, by putting this test before any DNS black list checks, you will + # always accept from these hosts, even if they end up on a black list. The + # assumption is that they are your friends, and if they get onto a black + # list, it is a mistake. + + accept hosts = +relay_from_hosts + control = submission + + # Accept if the message arrived over an authenticated connection, from + # any host. Again, these messages are usually from MUAs, so recipient + # verification is omitted, and submission mode is set. And again, we do this + # check before any black list tests. + + accept authenticated = * + control = submission + + # Insist that any other recipient address that we accept is either in one of + # our local domains, or is in a domain for which we explicitly allow + # relaying. Any other domain is rejected as being unacceptable for relaying. + + require message = relay not permitted + domains = +local_domains : +relay_domains + + # We also require all accepted addresses to be verifiable. This check will + # do local part verification for local domains, but only check the domain + # for remote domains. The only way to check local parts for the remote + # relay domains is to use a callout (add /callout), but please read the + # documentation about callouts before doing this. + + require verify = recipient + + ############################################################################# + # There are no default checks on DNS black lists because the domains that + # contain these lists are changing all the time. However, here are two + # examples of how you can get Exim to perform a DNS black list lookup at this + # point. The first one denies, whereas the second just warns. + # + # deny message = rejected because $sender_host_address is in a black list at $dnslist_domain\n$dnslist_text + # dnslists = black.list.example + # + # warn dnslists = black.list.example + # add_header = X-Warning: $sender_host_address is in a black list at $dnslist_domain + # log_message = found in $dnslist_domain + ############################################################################# + + ############################################################################# + # This check is commented out because it is recognized that not every + # sysadmin will want to do it. If you enable it, the check performs + # Client SMTP Authorization (csa) checks on the sending host. These checks + # do DNS lookups for SRV records. The CSA proposal is currently (May 2005) + # an Internet draft. You can, of course, add additional conditions to this + # ACL statement to restrict the CSA checks to certain hosts only. + # + # require verify = csa + ############################################################################# + + # At this point, the address has passed all the checks that have been + # configured, so we accept it unconditionally. + + accept + + +# This ACL is used after the contents of a message have been received. This +# is the ACL in which you can test a message's headers or body, and in +# particular, this is where you can invoke external virus or spam scanners. +# Some suggested ways of configuring these tests are shown below, commented +# out. Without any tests, this ACL accepts all messages. If you want to use +# such tests, you must ensure that Exim is compiled with the content-scanning +# extension (WITH_CONTENT_SCAN=yes in Local/Makefile). + +acl_check_data: + + # Deny if the message contains a virus. Before enabling this check, you + # must install a virus scanner and set the av_scanner option above. + # + # deny malware = * + # message = This message contains a virus ($malware_name). + + # Add headers to a message if it is judged to be spam. Before enabling this, + # you must install SpamAssassin. You may also need to set the spamd_address + # option above. + # + # warn spam = nobody + # add_header = X-Spam_score: $spam_score\n\ + # X-Spam_score_int: $spam_score_int\n\ + # X-Spam_bar: $spam_bar\n\ + # X-Spam_report: $spam_report + + # Accept the message. + + accept + + + +###################################################################### +# ROUTERS CONFIGURATION # +# Specifies how addresses are handled # +###################################################################### +# THE ORDER IN WHICH THE ROUTERS ARE DEFINED IS IMPORTANT! # +# An address is passed to each router in turn until it is accepted. # +###################################################################### + +begin routers + +# This router routes to remote hosts over SMTP by explicit IP address, +# when an email address is given in "domain literal" form, for example, +# <user@[192.168.35.64]>. The RFCs require this facility. However, it is +# little-known these days, and has been exploited by evil people seeking +# to abuse SMTP relays. Consequently it is commented out in the default +# configuration. If you uncomment this router, you also need to uncomment +# allow_domain_literals above, so that Exim can recognize the syntax of +# domain literal addresses. + +# domain_literal: +# driver = ipliteral +# domains = ! +local_domains +# transport = remote_smtp + + +# This router routes addresses that are not in local domains by doing a DNS +# lookup on the domain name. The exclamation mark that appears in "domains = ! +# +local_domains" is a negating operator, that is, it can be read as "not". The +# recipient's domain must not be one of those defined by "domainlist +# local_domains" above for this router to be used. +# +# If the router is used, any domain that resolves to 0.0.0.0 or to a loopback +# interface address (127.0.0.0/8) is treated as if it had no DNS entry. Note +# that 0.0.0.0 is the same as 0.0.0.0/32, which is commonly treated as the +# local host inside the network stack. It is not 0.0.0.0/0, the default route. +# If the DNS lookup fails, no further routers are tried because of the no_more +# setting, and consequently the address is unrouteable. + +dnslookup: + driver = dnslookup + domains = ! +local_domains + transport = remote_smtp + ignore_target_hosts = 0.0.0.0 : 127.0.0.0/8 + no_more + + +# The remaining routers handle addresses in the local domain(s), that is those +# domains that are defined by "domainlist local_domains" above. + + +# This router handles aliasing using a linearly searched alias file with the +# name /etc/aliases. When this configuration is installed automatically, +# the name gets inserted into this file from whatever is set in Exim's +# build-time configuration. The default path is the traditional /etc/aliases. +# If you install this configuration by hand, you need to specify the correct +# path in the "data" setting below. +# +##### NB You must ensure that the alias file exists. It used to be the case +##### NB that every Unix had that file, because it was the Sendmail default. +##### NB These days, there are systems that don't have it. Your aliases +##### NB file should at least contain an alias for "postmaster". +# +# If any of your aliases expand to pipes or files, you will need to set +# up a user and a group for these deliveries to run under. You can do +# this by uncommenting the "user" option below (changing the user name +# as appropriate) and adding a "group" option if necessary. Alternatively, you +# can specify "user" on the transports that are used. Note that the transports +# listed below are the same as are used for .forward files; you might want +# to set up different ones for pipe and file deliveries from aliases. + +system_aliases: + driver = redirect + allow_fail + allow_defer + data = ${lookup{$local_part}lsearch{/etc/aliases}} +# user = exim + file_transport = address_file + pipe_transport = address_pipe + + +ldap_aliases: + driver = redirect + allow_fail + allow_defer + data = ${lookup ldapm{user=LDAP_USER pass=LDAP_PASS ldap://LDAP_HOSTNAME/uid=${quote_ldap_dn:${local_part}},dc=${quote_ldap_dn:${domain}},LDAP_DOMAINS_ROOT_DN?mailaliasedname?sub?(objectclass=mailalias)}} + file_transport = address_file + pipe_transport = address_pipe + +# This router matches local user mailboxes. If the router fails, the error +# message is "Unknown user". + +# If you want this router to treat local parts with suffixes introduced by "-" +# or "+" characters as if the suffixes did not exist, uncomment the two local_ +# part_suffix options. Then, for example, xxx...@yo...main will be treated +# in the same way as xx...@yo...main by this router. + +ldap_user: + driver = accept + condition = "${lookup ldap{user=LDAP_USER pass=LDAP_PASS ldap://LDAP_HOSTNAME/uid=${quote_ldap_dn:${local_part}},dc=${quote_ldap_dn:${domain}},LDAP_DOMAINS_ROOT_DN?uid?sub?(objectclass=mailUser)}}" + transport = local_delivery + cannot_route_message = Unknown user + + +###################################################################### +# TRANSPORTS CONFIGURATION # +###################################################################### +# ORDER DOES NOT MATTER # +# Only one appropriate transport is called for each delivery. # +###################################################################### + +# A transport is used only when referenced from a router that successfully +# handles an address. + +begin transports + + +# This transport is used for delivering messages over SMTP connections. + +remote_smtp: + driver = smtp + + +# This transport is used for local delivery to the users Maildirs which are +# located under their domain. + + +local_delivery: + driver = appendfile + mode_fail_narrower = false + directory = "MAILHOME/${domain}/${local_part}/Maildir" + maildir_format + delivery_date_add + envelope_to_add + return_path_add + group = mail + mode = 0660 + +###################################################################### +# RETRY CONFIGURATION # +###################################################################### + +begin retry + +# This single retry rule applies to all domains and all errors. It specifies +# retries every 15 minutes for 2 hours, then increasing retry intervals, +# starting at 1 hour and increasing each time by a factor of 1.5, up to 16 +# hours, then retries every 6 hours until 4 days have passed since the first +# failed delivery. + +# Address or Domain Error Retries +# ----------------- ----- ------- + +* * F,2h,15m; G,16h,1h,1.5; F,4d,6h + + + +###################################################################### +# REWRITE CONFIGURATION # +###################################################################### + +# There are no rewriting specifications in this default configuration file. + +begin rewrite + + + +###################################################################### +# AUTHENTICATION CONFIGURATION # +###################################################################### + +begin authenticators + +plain: + driver = plaintext + public_name = PLAIN + server_prompts = : + server_condition = ${if ldapauth {user="uid=${extract{1}{@}{$2}},dc=${extract{2}{@}{$2}},LDAP_DOMAINS_ROOT_DN" pass=${quote:$3} ldap://LDAP_HOSTNAME/}{yes}{no}} + server_set_id = $2 + +login: + driver = plaintext + public_name = LOGIN + server_prompts = Username:: : Password:: + server_condition = ${if ldapauth {user="uid=${extract{1}{@}{$1}},dc=${extract{2}{@}{$1}},LDAP_DOMAINS_ROOT_DN" pass=${quote:$2} ldap://LDAP_HOSTNAME/}{yes}{no}} + server_set_id = $1 + +cram: + driver = cram_md5 + public_name = CRAM-MD5 + server_secret = ${lookup ldapm{user=LDAP_USER pass=LDAP_PASS ldap://LDAP_HOSTNAME/uid=${quote_ldap_dn:${extract{1}{@}{$1}}},dc=${quote_ldap_dn:${extract{2}{@}{$1}}},LDAP_DOMAINS_ROOT_DN?clearPassword?sub}{$value}fail} + server_set_id = $1 + +###################################################################### +# CONFIGURATION FOR local_scan() # +###################################################################### + +# If you have built Exim to include a local_scan() function that contains +# tables for private options, you can define those options here. Remember to +# uncomment the "begin" line. It is commented by default because it provokes +# an error with Exim binaries that are not built with LOCAL_SCAN_HAS_OPTIONS +# set in the Local/Makefile. + +# begin local_scan + + +# End of Exim configuration file This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <tux...@us...> - 2007-04-30 15:08:52
|
Revision: 67 http://elma.svn.sourceforge.net/elma/?rev=67&view=rev Author: tuxevara Date: 2007-04-30 08:08:24 -0700 (Mon, 30 Apr 2007) Log Message: ----------- displaying the alias for column looks better now Modified Paths: -------------- trunk/templates/simple/content_users_list.tpl trunk/templates/simple/style.css Modified: trunk/templates/simple/content_users_list.tpl =================================================================== --- trunk/templates/simple/content_users_list.tpl 2007-04-30 14:58:43 UTC (rev 66) +++ trunk/templates/simple/content_users_list.tpl 2007-04-30 15:08:24 UTC (rev 67) @@ -46,10 +46,11 @@ {$aliases[aliases_sec].uid} </td> <td> - + <ul> {section name=mailaliasedname_sec loop=$aliases[aliases_sec].mailaliasedname} - {$aliases[aliases_sec].mailaliasedname[mailaliasedname_sec]} + <li>{$aliases[aliases_sec].mailaliasedname[mailaliasedname_sec]}</li> {/section} + </ul> </td> <td class="status"> {if $aliases[aliases_sec].mailstatus == "TRUE"} Modified: trunk/templates/simple/style.css =================================================================== --- trunk/templates/simple/style.css 2007-04-30 14:58:43 UTC (rev 66) +++ trunk/templates/simple/style.css 2007-04-30 15:08:24 UTC (rev 67) @@ -78,6 +78,17 @@ padding: 0; } +div#Content ul { + margin: 0; + padding: 0; +} + +div#Content li { + list-style: none; + margin: 0; + padding: 0; +} + div#Content p { margin: 1em 0; } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <tux...@us...> - 2007-04-30 14:58:47
|
Revision: 66 http://elma.svn.sourceforge.net/elma/?rev=66&view=rev Author: tuxevara Date: 2007-04-30 07:58:43 -0700 (Mon, 30 Apr 2007) Log Message: ----------- better alias input valiadtion new images in simple template some new strings to make the interface clearer Modified Paths: -------------- trunk/includes/my_functions.inc.php trunk/templates/simple/content_alias_edit.tpl trunk/templates/simple/content_domain_edit.tpl trunk/templates/simple/content_domains_list.tpl trunk/templates/simple/content_user_edit.tpl trunk/templates/simple/content_users_list.tpl trunk/templates/simple/images/button_cancel.png trunk/templates/simple/images/button_ok.png Modified: trunk/includes/my_functions.inc.php =================================================================== --- trunk/includes/my_functions.inc.php 2007-04-29 22:56:15 UTC (rev 65) +++ trunk/includes/my_functions.inc.php 2007-04-30 14:58:43 UTC (rev 66) @@ -94,7 +94,7 @@ $valid_alias_data = array(); if (! validate_data($alias["uid"],"uid")) $valid_alias_data["uid"] = FALSE; for ($i = 0; $i < count($alias["mailaliasedname"]); $i++) { - if (! validate_data($alias["mailaliasedname"][$i],"mailaliasedname")) $valid_alias_data["mailaliasedname"] = FALSE; + if (! validate_data(rtrim($alias["mailaliasedname"][$i]),"mailaliasedname")) $valid_alias_data["mailaliasedname"] = FALSE; if ((isset($valid_alias_data["mailaliasedname"])) && ($valid_alias_data["mailaliasedname"] == FALSE)) break; } return $valid_alias_data; Modified: trunk/templates/simple/content_alias_edit.tpl =================================================================== --- trunk/templates/simple/content_alias_edit.tpl 2007-04-29 22:56:15 UTC (rev 65) +++ trunk/templates/simple/content_alias_edit.tpl 2007-04-30 14:58:43 UTC (rev 66) @@ -48,7 +48,7 @@ </tr> <tr> <td> - {t}Activated{/t} + {t}Is active?{/t} </td> <td> <input type="checkbox" name="mailstatus" {if $alias.mailstatus.0 eq "FALSE"}{else}checked="checked"{/if} /> Modified: trunk/templates/simple/content_domain_edit.tpl =================================================================== --- trunk/templates/simple/content_domain_edit.tpl 2007-04-29 22:56:15 UTC (rev 65) +++ trunk/templates/simple/content_domain_edit.tpl 2007-04-30 14:58:43 UTC (rev 66) @@ -20,7 +20,7 @@ <table> <tr> <td> - {t}Activated{/t} + {t}Is active?{/t} </td> <td> <input type="checkbox" name="mailstatus" {if $domain.mailstatus.0 eq "TRUE"}checked="checked"{/if} /> Modified: trunk/templates/simple/content_domains_list.tpl =================================================================== --- trunk/templates/simple/content_domains_list.tpl 2007-04-29 22:56:15 UTC (rev 65) +++ trunk/templates/simple/content_domains_list.tpl 2007-04-30 14:58:43 UTC (rev 66) @@ -3,7 +3,7 @@ <table> <tr> <th>{t}Domain{/t}</th> - <th class="status">{t}Status{/t}</th> + <th class="status">{t}Active{/t}</th> <th class="command">{t}Command{/t}</th> </tr> {section name=domains_sec loop=$domains} Modified: trunk/templates/simple/content_user_edit.tpl =================================================================== --- trunk/templates/simple/content_user_edit.tpl 2007-04-29 22:56:15 UTC (rev 65) +++ trunk/templates/simple/content_user_edit.tpl 2007-04-30 14:58:43 UTC (rev 66) @@ -50,7 +50,7 @@ </tr> <tr> <td> - {t}Activated{/t} + {t}Is active?{/t} </td> <td> <input type="checkbox" name="mailstatus" {if $user.mailstatus.0 eq "FALSE"}{else}checked="checked"{/if} /> Modified: trunk/templates/simple/content_users_list.tpl =================================================================== --- trunk/templates/simple/content_users_list.tpl 2007-04-29 22:56:15 UTC (rev 65) +++ trunk/templates/simple/content_users_list.tpl 2007-04-30 14:58:43 UTC (rev 66) @@ -3,7 +3,7 @@ <table> <tr> <th>{t}Username{/t}</th> - <th class="status">{t}Status{/t}</th> + <th class="status">{t}Active{/t}</th> <th class="command">{t}Command{/t}</th> </tr> {section name=users_sec loop=$users} @@ -37,7 +37,7 @@ <tr> <th>{t}Alias{/t}</th> <th>{t}Alias for{/t}</th> - <th class="status">{t}Status{/t}</th> + <th class="status">{t}Active{/t}</th> <th class="command">{t}Command{/t}</th> </tr> {section name=aliases_sec loop=$aliases} @@ -48,7 +48,7 @@ <td> {section name=mailaliasedname_sec loop=$aliases[aliases_sec].mailaliasedname} - {$aliases[aliases_sec].mailaliasedname[mailaliasedname_sec]}<br/> + {$aliases[aliases_sec].mailaliasedname[mailaliasedname_sec]} {/section} </td> <td class="status"> Modified: trunk/templates/simple/images/button_cancel.png =================================================================== (Binary files differ) Modified: trunk/templates/simple/images/button_ok.png =================================================================== (Binary files differ) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <tux...@us...> - 2007-04-29 22:56:17
|
Revision: 65 http://elma.svn.sourceforge.net/elma/?rev=65&view=rev Author: tuxevara Date: 2007-04-29 15:56:15 -0700 (Sun, 29 Apr 2007) Log Message: ----------- working on passworde sync md5 <> cleantext not implemented well right now Modified Paths: -------------- trunk/modules/content_user_edit.php Modified: trunk/modules/content_user_edit.php =================================================================== --- trunk/modules/content_user_edit.php 2007-04-29 22:35:47 UTC (rev 64) +++ trunk/modules/content_user_edit.php 2007-04-29 22:56:15 UTC (rev 65) @@ -68,15 +68,14 @@ $my_user["mailstatus"] = "FALSE"; } - -my_print_r($my_user); - - $my_user["userpassword"] = "{MD5}".base64_encode(pack("H*",md5($my_user["clearpassword"]))); + if (! $my_user["clearpassword"] == "") { + $my_user["userpassword"] = "{MD5}".base64_encode(pack("H*",md5($my_user["clearpassword"]))); + } + if (! defined(SAVECLEARPASS)) { unset($my_user["clearpassword"]); } - - my_print_r($my_user); + $validation_errors = validate_user($my_user); if (count($validation_errors) == 0) { switch ($_POST["mode"]) { This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <tux...@us...> - 2007-04-29 22:35:53
|
Revision: 64 http://elma.svn.sourceforge.net/elma/?rev=64&view=rev Author: tuxevara Date: 2007-04-29 15:35:47 -0700 (Sun, 29 Apr 2007) Log Message: ----------- some small template changes disabling cleartext password saving now possible enabling/disabling alias now possible updated config.inc.php.dist to provide new cleartextoption Modified Paths: -------------- trunk/doc/README.templates trunk/doc/ldap/elma-0.1.schema trunk/includes/config.inc.php.dist trunk/includes/my_functions.inc.php trunk/modules/content_alias_edit.php trunk/modules/content_user_edit.php trunk/templates/simple/content_alias_delete.tpl trunk/templates/simple/content_alias_edit.tpl trunk/templates/simple/content_domain_delete.tpl trunk/templates/simple/content_domain_edit.tpl trunk/templates/simple/content_domains_list.tpl trunk/templates/simple/content_user_delete.tpl trunk/templates/simple/content_user_edit.tpl trunk/templates/simple/content_users_list.tpl trunk/templates/simple/style.css Added Paths: ----------- trunk/templates/simple/print_submit_status.tpl Modified: trunk/doc/README.templates =================================================================== --- trunk/doc/README.templates 2007-04-29 11:32:34 UTC (rev 63) +++ trunk/doc/README.templates 2007-04-29 22:35:47 UTC (rev 64) @@ -2,7 +2,8 @@ by the framework: header.tpl : <html>,<head></head>,<title></title>,<meta>,<link> and - the <body> tag should only be used here + the <body> tag should only be used +banner.tpl : shows the product logo or text banner content_main.tpl : this must contain a default page which will be displayed if no module is called. navigation.tpl : global navigation menu Modified: trunk/doc/ldap/elma-0.1.schema =================================================================== --- trunk/doc/ldap/elma-0.1.schema 2007-04-29 11:32:34 UTC (rev 63) +++ trunk/doc/ldap/elma-0.1.schema 2007-04-29 22:35:47 UTC (rev 64) @@ -1,7 +1,7 @@ # common Attributes attributetype ( 1.3.6.1.4.1.25287.1.1.2.1 NAME 'mailStatus' - DESC 'Enable/Disable domain or user.' + DESC 'Enable/Disable domain, user or alias.' EQUALITY booleanMatch SYNTAX 1.3.6.1.4.1.1466.115.121.1.7 SINGLE-VALUE ) @@ -23,8 +23,8 @@ objectclass ( 1.3.6.1.4.1.25287.1.1.1.200 NAME 'mailUser' DESC 'Mail router user' SUP person STRUCTURAL - MUST ( uid $ userPassword $ clearpassword) - MAY ( mailStatus) ) + MUST ( uid $ userPassword ) + MAY ( mailStatus $ clearpassword) ) # mailAlias attributetype ( 1.3.6.1.4.1.25287.1.1.2.301 NAME 'mailAliasedName' @@ -32,6 +32,7 @@ objectclass ( 1.3.6.1.4.1.25287.1.1.2.300 NAME 'mailAlias' DESC 'Mail alias' SUP top STRUCTURAL - MUST ( uid $ mailAliasedName ) ) + MUST ( uid $ mailAliasedName ) + MAY ( mailStatus) ) Modified: trunk/includes/config.inc.php.dist =================================================================== --- trunk/includes/config.inc.php.dist 2007-04-29 11:32:34 UTC (rev 63) +++ trunk/includes/config.inc.php.dist 2007-04-29 22:35:47 UTC (rev 64) @@ -40,7 +40,7 @@ define ("LDAP_USE_TLS","0"); // LDAP Servers Base DN -define ("LDAP_BASEDN","o=mycorp"); +define ("LDAP_BASEDN","o=mybase"); // LDAP Servers Base DN for domains define ("LDAP_DOMAINS_ROOT_DN","ou=domains,".LDAP_BASEDN); @@ -51,7 +51,7 @@ /* ######## Language Settings #### */ // Set the default language -define ("DEFAULT_LANGUAGE","de_DE"); +define ("DEFAULT_LANGUAGE","en_US"); // Set all languages which should be available at login define ("AVAILABLE_LANGUAGES",serialize(array("deutsch" => "de_DE", @@ -69,6 +69,9 @@ define('APPROOT',getcwd()); // Define the session variable encryption key -define('MYCRYPT_KEY',"my little key"); +define('MYCRYPT_KEY',"my mcrypt encryption key"); -// vim:tabstop=4:expandtab:shiftwidth=4:filetype=php:syntax:ruler: +// Should ELMA save the cleartext password in the LDAP database (needed for cram-md5 authentification) +// a value with anything else than an empty string will enable cleatext password saving!! +define('SAVECLEARPASS',"TRUE"); +?> Modified: trunk/includes/my_functions.inc.php =================================================================== --- trunk/includes/my_functions.inc.php 2007-04-29 11:32:34 UTC (rev 63) +++ trunk/includes/my_functions.inc.php 2007-04-29 22:35:47 UTC (rev 64) @@ -93,7 +93,6 @@ function validate_alias ($alias) { $valid_alias_data = array(); if (! validate_data($alias["uid"],"uid")) $valid_alias_data["uid"] = FALSE; - my_print_r($alias["mailaliasedname"]); for ($i = 0; $i < count($alias["mailaliasedname"]); $i++) { if (! validate_data($alias["mailaliasedname"][$i],"mailaliasedname")) $valid_alias_data["mailaliasedname"] = FALSE; if ((isset($valid_alias_data["mailaliasedname"])) && ($valid_alias_data["mailaliasedname"] == FALSE)) break; Modified: trunk/modules/content_alias_edit.php =================================================================== --- trunk/modules/content_alias_edit.php 2007-04-29 11:32:34 UTC (rev 63) +++ trunk/modules/content_alias_edit.php 2007-04-29 22:35:47 UTC (rev 64) @@ -62,6 +62,12 @@ unset($my_alias["submit"]); unset($my_alias["mode"]); + if (isset($_POST["mailstatus"])) { + $my_alias["mailstatus"] = "TRUE"; + } else { + $my_alias["mailstatus"] = "FALSE"; + } + $my_alias["mailaliasedname"] = explode("\n", $_POST['nlo_mailaliasedname']); $validation_errors = validate_alias($my_alias); Modified: trunk/modules/content_user_edit.php =================================================================== --- trunk/modules/content_user_edit.php 2007-04-29 11:32:34 UTC (rev 63) +++ trunk/modules/content_user_edit.php 2007-04-29 22:35:47 UTC (rev 64) @@ -68,8 +68,15 @@ $my_user["mailstatus"] = "FALSE"; } - $my_user["userpassword"] = $my_user["clearpassword"]; +my_print_r($my_user); + + $my_user["userpassword"] = "{MD5}".base64_encode(pack("H*",md5($my_user["clearpassword"]))); + if (! defined(SAVECLEARPASS)) { + unset($my_user["clearpassword"]); + } + + my_print_r($my_user); $validation_errors = validate_user($my_user); if (count($validation_errors) == 0) { switch ($_POST["mode"]) { Modified: trunk/templates/simple/content_alias_delete.tpl =================================================================== --- trunk/templates/simple/content_alias_delete.tpl 2007-04-29 11:32:34 UTC (rev 63) +++ trunk/templates/simple/content_alias_delete.tpl 2007-04-29 22:35:47 UTC (rev 64) @@ -1,15 +1,7 @@ <div id="Content"> <h2>{t}Delete Alias{/t}</h2> {if $smarty.post.submit} - {if $submit_status == "0"} - <div> - {t}Data saved successfully.{/t} - </div> - {else} - <div> - {t}Sorry, your data could not be saved. The following LDAP error occured:{/t} {$submit_status} - </div> - {/if} + {include file="print_submit_status.tpl"} {else} <form action="{$smarty.server.php_self}" method="post"> <fieldset> @@ -26,7 +18,7 @@ <td> </td> <td> <input type="submit" name="submit" value="{t}Yes{/t}"/> - <input type="reset" name="reset" value="{t}No{/t}"/> + <input type="reset" name="reset" value="{t}No{/t}" onClick="javascript:history.back()"/> </td> </tr> </table> Modified: trunk/templates/simple/content_alias_edit.tpl =================================================================== --- trunk/templates/simple/content_alias_edit.tpl 2007-04-29 11:32:34 UTC (rev 63) +++ trunk/templates/simple/content_alias_edit.tpl 2007-04-29 22:35:47 UTC (rev 64) @@ -5,15 +5,7 @@ <h2>{t}New Alias{/t}</h2> {/if} {if $smarty.post.submit} - {if $submit_status == "0"} - <div> - {t}Data saved successfully.{/t} - </div> - {else} - <div> - {t}Sorry, your data could not be saved. The following error occured:{/t} {$submit_status} - </div> - {/if} + {include file="print_submit_status.tpl"} {/if} <form action="{$smarty.server.php_self}" method="post"> <div> @@ -54,6 +46,14 @@ {/strip} </td> </tr> + <tr> + <td> + {t}Activated{/t} + </td> + <td> + <input type="checkbox" name="mailstatus" {if $alias.mailstatus.0 eq "FALSE"}{else}checked="checked"{/if} /> + </td> + </tr> <tr> <td> </td> <td> Modified: trunk/templates/simple/content_domain_delete.tpl =================================================================== --- trunk/templates/simple/content_domain_delete.tpl 2007-04-29 11:32:34 UTC (rev 63) +++ trunk/templates/simple/content_domain_delete.tpl 2007-04-29 22:35:47 UTC (rev 64) @@ -1,15 +1,7 @@ <div id="Content"> <h2>{t}Delete Domain{/t}</h2> {if $smarty.post.submit} - {if $submit_status == "0"} - <div> - {t}Data saved successfully.{/t} - </div> - {else} - <div> - {t}Sorry, your data could not be saved. The following LDAP error occured:{/t} {$submit_status} - </div> - {/if} + {include file="print_submit_status.tpl"} {else} <form action="{$smarty.server.php_self}" method="post"> <fieldset> @@ -25,7 +17,7 @@ <td> </td> <td> <input type="submit" name="submit" value="{t}Yes{/t}"/> - <input type="reset" name="reset" value="{t}No{/t}"/> + <input type="reset" name="reset" value="{t}No{/t}" onClick="javascript:history.back()"/> </td> </tr> </table> Modified: trunk/templates/simple/content_domain_edit.tpl =================================================================== --- trunk/templates/simple/content_domain_edit.tpl 2007-04-29 11:32:34 UTC (rev 63) +++ trunk/templates/simple/content_domain_edit.tpl 2007-04-29 22:35:47 UTC (rev 64) @@ -5,15 +5,7 @@ <h2>{t}New Domain{/t}</h2> {/if} {if $smarty.post.submit} - {if $submit_status == "0"} - <div> - {t}Data saved successfully.{/t} - </div> - {else} - <div> - {t}Sorry, your data could not be saved. The following error occured:{/t} {$submit_status} - </div> - {/if} + {include file="print_submit_status.tpl"} {/if} <form action="{$smarty.server.php_self}" method="post"> <div> Modified: trunk/templates/simple/content_domains_list.tpl =================================================================== --- trunk/templates/simple/content_domains_list.tpl 2007-04-29 11:32:34 UTC (rev 63) +++ trunk/templates/simple/content_domains_list.tpl 2007-04-29 22:35:47 UTC (rev 64) @@ -3,7 +3,7 @@ <table> <tr> <th>{t}Domain{/t}</th> - <th>{t}Status{/t}</th> + <th class="status">{t}Status{/t}</th> <th class="command">{t}Command{/t}</th> </tr> {section name=domains_sec loop=$domains} @@ -11,7 +11,7 @@ <td> <a href="{$domains[domains_sec].userslink}">{$domains[domains_sec].dc}</a> </td> - <td> + <td class="status"> {if $domains[domains_sec].mailstatus == "TRUE"} <img src="{$template_path}/images/button_ok.png" alt="active"/> {else} @@ -25,9 +25,9 @@ </tr> {/section} <tr> - <td> </td> - <td> </td> - <td class="command"> + <td class="last"> </td> + <td class="last"> </td> + <td class="last command"> <a href="{$link_newdomain}">{t}new domain{/t}</a> </td> </tr> Modified: trunk/templates/simple/content_user_delete.tpl =================================================================== --- trunk/templates/simple/content_user_delete.tpl 2007-04-29 11:32:34 UTC (rev 63) +++ trunk/templates/simple/content_user_delete.tpl 2007-04-29 22:35:47 UTC (rev 64) @@ -1,15 +1,7 @@ <div id="Content"> <h2>{t}Delete User{/t}</h2> {if $smarty.post.submit} - {if $submit_status == "0"} - <div> - {t}Data saved successfully.{/t} - </div> - {else} - <div> - {t}Sorry, your data could not be saved. The following LDAP error occured:{/t} {$submit_status} - </div> - {/if} + {include file="print_submit_status.tpl"} {else} <form action="{$smarty.server.php_self}" method="post"> <fieldset> @@ -26,7 +18,7 @@ <td> </td> <td> <input type="submit" name="submit" value="{t}Yes{/t}"/> - <input type="reset" name="reset" value="{t}No{/t}"/> + <input type="reset" name="reset" value="{t}No{/t}" onClick="javascript:history.back()"/> </td> </tr> </table> Modified: trunk/templates/simple/content_user_edit.tpl =================================================================== --- trunk/templates/simple/content_user_edit.tpl 2007-04-29 11:32:34 UTC (rev 63) +++ trunk/templates/simple/content_user_edit.tpl 2007-04-29 22:35:47 UTC (rev 64) @@ -5,15 +5,7 @@ <h2>{t}New User{/t}</h2> {/if} {if $smarty.post.submit} - {if $submit_status == "0"} - <div> - {t}Data saved successfully.{/t} - </div> - {else} - <div> - {t}Sorry, your data could not be saved. The following error occured:{/t} {$submit_status} - </div> - {/if} + {include file="print_submit_status.tpl"} {/if} <form action="{$smarty.server.php_self}" method="post"> <div> Modified: trunk/templates/simple/content_users_list.tpl =================================================================== --- trunk/templates/simple/content_users_list.tpl 2007-04-29 11:32:34 UTC (rev 63) +++ trunk/templates/simple/content_users_list.tpl 2007-04-29 22:35:47 UTC (rev 64) @@ -2,8 +2,8 @@ <h2>{t}Users and aliases for domain{/t} {$domain}</h2> <table> <tr> - <th>{t}User{/t}</th> - <th>{t}Status{/t}</th> + <th>{t}Username{/t}</th> + <th class="status">{t}Status{/t}</th> <th class="command">{t}Command{/t}</th> </tr> {section name=users_sec loop=$users} @@ -11,7 +11,7 @@ <td> {$users[users_sec].uid} </td> - <td> + <td class="status"> {if $users[users_sec].mailstatus == "TRUE"} <img src="{$template_path}/images/button_ok.png" alt="active"/> {else} @@ -25,9 +25,9 @@ </tr> {/section} <tr> - <td> </td> - <td> </td> - <td class="command"> + <td class="last"> </td> + <td class="last"> </td> + <td class="last command"> <a href="{$link_newuser}">{t}new user{/t}</a> </td> </tr> @@ -37,6 +37,7 @@ <tr> <th>{t}Alias{/t}</th> <th>{t}Alias for{/t}</th> + <th class="status">{t}Status{/t}</th> <th class="command">{t}Command{/t}</th> </tr> {section name=aliases_sec loop=$aliases} @@ -50,6 +51,13 @@ {$aliases[aliases_sec].mailaliasedname[mailaliasedname_sec]}<br/> {/section} </td> + <td class="status"> + {if $aliases[aliases_sec].mailstatus == "TRUE"} + <img src="{$template_path}/images/button_ok.png" alt="active"/> + {else} + <img src="{$template_path}/images/button_cancel.png" alt="inactive"/> + {/if} + </td> <td class="command"> <a href="{$aliases[aliases_sec].editlink}">{t}edit{/t}</a> <a href="{$aliases[aliases_sec].deletelink}">{t}delete{/t}</a> @@ -57,9 +65,10 @@ </tr> {/section} <tr> - <td> </td> - <td> </td> - <td class="command"> + <td class="last"> </td> + <td class="last"> </td> + <td class="last status"> </td> + <td class="last command"> <a href="{$link_newalias}">{t}new alias{/t}</a> </td> </tr> Added: trunk/templates/simple/print_submit_status.tpl =================================================================== --- trunk/templates/simple/print_submit_status.tpl (rev 0) +++ trunk/templates/simple/print_submit_status.tpl 2007-04-29 22:35:47 UTC (rev 64) @@ -0,0 +1,9 @@ + {if $submit_status == "0"} + <div> + {t}Data has been saved.{/t} + </div> + {else} + <div> + {t}Sorry, your data could not be saved. The following error occured:{/t} {$submit_status} + </div> + {/if} Modified: trunk/templates/simple/style.css =================================================================== --- trunk/templates/simple/style.css 2007-04-29 11:32:34 UTC (rev 63) +++ trunk/templates/simple/style.css 2007-04-29 22:35:47 UTC (rev 64) @@ -112,11 +112,21 @@ vertical-align: top; } +div#Content td.status,th.status { + width: 15%; + text-align: center; +} + div#Content td.command { width: 20%; background: #EEE } +div#Content td.last { + border-top: 1px silver solid; +} + + /* Footer elements */ div#Footer { @@ -148,8 +158,11 @@ h2 { font-size: 16px; - margin: 0; - padding: 0 0 1em 0; + margin: 0 0 0.5em 0; + padding: 0 0 0 0.5em; + font-style: italic; + border-left: 20px #99CCFF solid; + border-bottom: 1px #99CCFF solid; } hr { @@ -187,3 +200,5 @@ .space25 { height: 25px; } + + This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <tux...@us...> - 2007-04-29 11:32:37
|
Revision: 63 http://elma.svn.sourceforge.net/elma/?rev=63&view=rev Author: tuxevara Date: 2007-04-29 04:32:34 -0700 (Sun, 29 Apr 2007) Log Message: ----------- some text work and login error handling Modified Paths: -------------- trunk/index.php trunk/login.php trunk/templates/simple/content_alias_edit.tpl trunk/templates/simple/content_domain_edit.tpl trunk/templates/simple/content_main.tpl trunk/templates/simple/content_user_edit.tpl trunk/templates/simple/content_users_list.tpl trunk/templates/simple/login.tpl trunk/templates/simple/style.css Added Paths: ----------- trunk/templates/simple/banner.tpl Modified: trunk/index.php =================================================================== --- trunk/index.php 2007-04-28 21:48:48 UTC (rev 62) +++ trunk/index.php 2007-04-29 11:32:34 UTC (rev 63) @@ -45,6 +45,7 @@ if (!isset($_SESSION["login"])) { session_destroy(); + if (isset($_GET["loginerror"])) $smarty->assign("loginerror",$_GET["loginerror"]); $smarty->display("header.tpl"); $smarty->display("login.tpl"); $smarty->display("footer.tpl"); @@ -59,6 +60,7 @@ $content = $content_module->getContent(); $smarty->display("header.tpl"); + $smarty->display("banner.tpl"); $smarty->display("navigation.tpl"); echo $content; $smarty->display("footer.tpl"); Modified: trunk/login.php =================================================================== --- trunk/login.php 2007-04-28 21:48:48 UTC (rev 62) +++ trunk/login.php 2007-04-29 11:32:34 UTC (rev 63) @@ -65,11 +65,11 @@ header ("Location: index.php"); exit; } else { - echo $ldap->last_error(); session_destroy(); + header ("Location: index.php?loginerror=TRUE"); } } else { - echo "Invalid username."; + header ("Location: index.php?loginerror=TRUE"); } } // vim:tabstop=4:expandtab:shiftwidth=4:filetype=php:syntax:ruler: Added: trunk/templates/simple/banner.tpl =================================================================== --- trunk/templates/simple/banner.tpl (rev 0) +++ trunk/templates/simple/banner.tpl 2007-04-29 11:32:34 UTC (rev 63) @@ -0,0 +1,6 @@ + <div id="Banner"> + <h1>ELMA - Exim LDAP Mail Administrator - v0.1</h1> + </div> +{* +// vim:tabstop=4:expandtab:shiftwidth=4:filetype=smarty:syntax:ruler: +*} Modified: trunk/templates/simple/content_alias_edit.tpl =================================================================== --- trunk/templates/simple/content_alias_edit.tpl 2007-04-28 21:48:48 UTC (rev 62) +++ trunk/templates/simple/content_alias_edit.tpl 2007-04-29 11:32:34 UTC (rev 63) @@ -1,5 +1,9 @@ <div id="Content"> + {if $mode == "modify"} <h2>{t}Edit Alias{/t}</h2> + {else} + <h2>{t}New Alias{/t}</h2> + {/if} {if $smarty.post.submit} {if $submit_status == "0"} <div> @@ -7,7 +11,7 @@ </div> {else} <div> - {t}Sorry, your data could not be saved. The following LDAP error occured:{/t} {$submit_status} + {t}Sorry, your data could not be saved. The following error occured:{/t} {$submit_status} </div> {/if} {/if} Modified: trunk/templates/simple/content_domain_edit.tpl =================================================================== --- trunk/templates/simple/content_domain_edit.tpl 2007-04-28 21:48:48 UTC (rev 62) +++ trunk/templates/simple/content_domain_edit.tpl 2007-04-29 11:32:34 UTC (rev 63) @@ -1,5 +1,9 @@ <div id="Content"> + {if $mode == "modify"} <h2>{t}Edit Domain{/t}</h2> + {else} + <h2>{t}New Domain{/t}</h2> + {/if} {if $smarty.post.submit} {if $submit_status == "0"} <div> @@ -24,7 +28,7 @@ <table> <tr> <td> - {t}Status{/t} + {t}Activated{/t} </td> <td> <input type="checkbox" name="mailstatus" {if $domain.mailstatus.0 eq "TRUE"}checked="checked"{/if} /> Modified: trunk/templates/simple/content_main.tpl =================================================================== --- trunk/templates/simple/content_main.tpl 2007-04-28 21:48:48 UTC (rev 62) +++ trunk/templates/simple/content_main.tpl 2007-04-29 11:32:34 UTC (rev 63) @@ -1,4 +1,5 @@ <div id="Content"> - <h2>Main</h2> + <h2>{t}Welcome to your Exim LDAP Mail Administrator Frontend{/t}</h2> + <p>{t}Click on the Domain link at the left navigation bar to get an overview of your email domains. Wehen you click on the domain name you will see all users and aliases for that domain. everything else should be pretty self explaining. Have fun.{/t}</p> </div> Modified: trunk/templates/simple/content_user_edit.tpl =================================================================== --- trunk/templates/simple/content_user_edit.tpl 2007-04-28 21:48:48 UTC (rev 62) +++ trunk/templates/simple/content_user_edit.tpl 2007-04-29 11:32:34 UTC (rev 63) @@ -1,5 +1,9 @@ <div id="Content"> + {if $mode == "modify"} <h2>{t}Edit User{/t}</h2> + {else} + <h2>{t}New User{/t}</h2> + {/if} {if $smarty.post.submit} {if $submit_status == "0"} <div> @@ -7,7 +11,7 @@ </div> {else} <div> - {t}Sorry, your data could not be saved. The following LDAP error occured:{/t} {$submit_status} + {t}Sorry, your data could not be saved. The following error occured:{/t} {$submit_status} </div> {/if} {/if} @@ -54,7 +58,7 @@ </tr> <tr> <td> - {t}Status{/t} + {t}Activated{/t} </td> <td> <input type="checkbox" name="mailstatus" {if $user.mailstatus.0 eq "FALSE"}{else}checked="checked"{/if} /> Modified: trunk/templates/simple/content_users_list.tpl =================================================================== --- trunk/templates/simple/content_users_list.tpl 2007-04-28 21:48:48 UTC (rev 62) +++ trunk/templates/simple/content_users_list.tpl 2007-04-29 11:32:34 UTC (rev 63) @@ -1,5 +1,5 @@ <div id="Content"> - <h2>{t}Users for domain{/t} {$domain}</h2> + <h2>{t}Users and aliases for domain{/t} {$domain}</h2> <table> <tr> <th>{t}User{/t}</th> Modified: trunk/templates/simple/login.tpl =================================================================== --- trunk/templates/simple/login.tpl 2007-04-28 21:48:48 UTC (rev 62) +++ trunk/templates/simple/login.tpl 2007-04-29 11:32:34 UTC (rev 63) @@ -2,10 +2,22 @@ <form action="login.php" method="post"> <table> <tr> - <th colspan="3"> + <th colspan="3" class="login"> Exim Ldap Mail Administrator - Login </th> </tr> + <tr> + <td> + + </td> + <td colspan="2"> + {if $loginerror == TRUE} + <font color="red">{t}Invalid username and/or password.{/t}</font> + {else} + + {/if} + </td> + </tr> <tr> <td rowspan="4"> <img src="{$template_path}/images/email.jpg" id="loginlogo" alt="ELMA Logo"/> Modified: trunk/templates/simple/style.css =================================================================== --- trunk/templates/simple/style.css 2007-04-28 21:48:48 UTC (rev 62) +++ trunk/templates/simple/style.css 2007-04-29 11:32:34 UTC (rev 63) @@ -16,11 +16,18 @@ border: 1px solid black; } +/* Banner */ + +div#Banner { + margin: 0; + padding: 0; +} + /* Navigation elements */ div#Navigation { float: left; - margin: 4em 0 0 0; + margin: 1em 0 0 0; padding: 0; } @@ -67,7 +74,7 @@ /* Content elements */ div#Content { - margin: 1em 1em 1em 7.5em; + margin: 1.5em 1em 1em 7.5em; padding: 0; } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <tux...@us...> - 2007-04-28 21:48:53
|
Revision: 62 http://elma.svn.sourceforge.net/elma/?rev=62&view=rev Author: tuxevara Date: 2007-04-28 14:48:48 -0700 (Sat, 28 Apr 2007) Log Message: ----------- user and alias input validation added Modified Paths: -------------- trunk/includes/my_functions.inc.php trunk/modules/content_alias_edit.php trunk/modules/content_domain_edit.php trunk/modules/content_user_edit.php Modified: trunk/includes/my_functions.inc.php =================================================================== --- trunk/includes/my_functions.inc.php 2007-04-28 20:10:50 UTC (rev 61) +++ trunk/includes/my_functions.inc.php 2007-04-28 21:48:48 UTC (rev 62) @@ -1,90 +1,128 @@ - <?php - /** - * @author Daniel Weuthen <da...@we...> - * @version $LastChangedRevision$ - * @package ELMA - * - * $Id$ - * $LastChangedBy$ - * - * ===================================================================== - * - * 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, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA - * 02110-1301, USA - * - * ===================================================================== - */ +<?php +/** + * @author Daniel Weuthen <da...@we...> + * @version $LastChangedRevision$ + * @package ELMA + * + * $Id$ + * $LastChangedBy$ + * + * ===================================================================== + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA + * 02110-1301, USA + * + * ===================================================================== + */ - /** - * wrapper around print_r function - */ - function my_print_r ( $data ) { - echo "<pre>"; - print_r($data); - echo "</pre>"; - } +/** + * wrapper around print_r function + */ +function my_print_r ( $data ) { + echo "<pre>"; + print_r($data); + echo "</pre>"; +} - /** - * function to output debug messages - */ - function my_print_debug ( $message ) { - if ( DEBUG ) - { - echo "DEBUG: $message<br>\n"; - } +/** + * function to output debug messages + */ +function my_print_debug ( $message ) { + if ( DEBUG ) + { + echo "DEBUG: $message<br>\n"; } +} - /** - * remove keys from array that match given pattern - */ - function remove_key_by_str($array,$pattern) { - if( is_array($array) ) +/** + * remove keys from array that match given pattern + */ +function remove_key_by_str($array,$pattern) { + if( is_array($array) ) + { + $keys = array_keys($array); + foreach($keys as $key) + { + $length = strlen($pattern); + if(substr($key,0,$length) == $pattern) { - $keys = array_keys($array); - foreach($keys as $key) - { - $length = strlen($pattern); - if(substr($key,0,$length) == $pattern) - { - unset($array[$key]); - } - } + unset($array[$key]); } - return $array; } + } + return $array; +} - /** - * validate domain - */ - function validate_domain ($domain) { - $valid_domain_data = FALSE; - if (validate_data($domain["dc"],"domain")) $valid_domain_data = TRUE; - return $valid_domain_data; +/** + * validate domain + */ +function validate_domain ($domain) { + $valid_domain_data = array(); + if (! validate_data($domain["dc"],"dc")) $valid_domain_data["dc"] = FALSE; + return $valid_domain_data; +} + +/** + * validate user + */ +function validate_user ($user) { + $valid_user_data = array(); + if (! validate_data($user["uid"],"uid")) $valid_user_data["uid"] = FALSE; + if (! validate_data($user["sn"],"sn")) $valid_user_data["sn"] = FALSE; + if (! validate_data($user["cn"],"cn")) $valid_user_data["cn"] = FALSE; + if (! validate_data($user["userpassword"],"password")) $valid_user_data["userpassword"] = FALSE; + return $valid_user_data; +} + +/**] + * validate user + */ +function validate_alias ($alias) { + $valid_alias_data = array(); + if (! validate_data($alias["uid"],"uid")) $valid_alias_data["uid"] = FALSE; + my_print_r($alias["mailaliasedname"]); + for ($i = 0; $i < count($alias["mailaliasedname"]); $i++) { + if (! validate_data($alias["mailaliasedname"][$i],"mailaliasedname")) $valid_alias_data["mailaliasedname"] = FALSE; + if ((isset($valid_alias_data["mailaliasedname"])) && ($valid_alias_data["mailaliasedname"] == FALSE)) break; } + return $valid_alias_data; +} - /** - * validate given data against regex - */ - function validate_data($string,$object) { - $valid_data = FALSE; - switch ($object) { - case "domain": if (preg_match("/^([a-zA-Z0-9]([a-zA-Z0-9\-]{0,61}[a-zA-Z0-9])?\.)+[a-zA-Z]{2,6}$/",$string)) $valid_data = TRUE; - break; - } - return $valid_data; +/** + * validate given data against regex + */ +function validate_data($string,$object) { + $valid_data = FALSE; + switch ($object) { + case "dc": if (preg_match("/^([a-zA-Z0-9]([a-zA-Z0-9\-]{0,61}[a-zA-Z0-9])?\.)+[a-zA-Z]{2,6}$/",$string)) $valid_data = TRUE; + break; + case "uid": if (preg_match("/^[a-zA-Z0-9\-\.]{1,64}$/",$string)) $valid_data = TRUE; + break; + case "sn": if (preg_match("/^[a-zA-Z0-9\-\.]{1,64}$/",$string)) $valid_data = TRUE; + break; + case "cn": if (preg_match("/^[a-zA-Z0-9\-\.]{1,64}$/",$string)) $valid_data = TRUE; + break; + case "password": if (!preg_match("/^$/",$string)) $valid_data = TRUE; + break; + case "mailaliasedname": if ((validate_data($string,"uid")) || (validate_data($string,"email"))) $valid_data = TRUE; + break; + case "email": if (preg_match("/^([0-9a-zA-Z]([-.\w]*[0-9a-zA-Z])*@(([0-9a-zA-Z])+([-\w]*[0-9a-zA-Z])*\.)+[a-zA-Z]{2,9})$/",$string)) $valid_data = TRUE; + break; + } +return $valid_data; } // vim:tabstop=4:expandtab:shiftwidth=4:filetype=php:syntax:ruler: Modified: trunk/modules/content_alias_edit.php =================================================================== --- trunk/modules/content_alias_edit.php 2007-04-28 20:10:50 UTC (rev 61) +++ trunk/modules/content_alias_edit.php 2007-04-28 21:48:48 UTC (rev 62) @@ -63,22 +63,27 @@ unset($my_alias["mode"]); $my_alias["mailaliasedname"] = explode("\n", $_POST['nlo_mailaliasedname']); - - $alias = $my_alias["uid"]; - switch ($_POST["mode"]) { - case "add": - $this->ldap->addAlias($domain,$my_alias); - break; - case "modify": - $this->ldap->modifyAlias($domain,$my_alias); - break; - } - $submit_status = ldap_errno($this->ldap->cid); - if ($submit_status == "0") { - $this->smarty->assign("submit_status",$submit_status); + $validation_errors = validate_alias($my_alias); + if (count($validation_errors) == 0) { + switch ($_POST["mode"]) { + case "add": + $this->ldap->addAlias($domain,$my_alias); + break; + case "modify": + $this->ldap->modifyAlias($domain,$my_alias); + break; + } + $submit_status = ldap_errno($this->ldap->cid); + if ($submit_status == "0") { + $this->smarty->assign("submit_status",$submit_status); + $alias = $my_alias["uid"]; + } else { + $this->smarty->assign("submit_status",ldap_err2str($submit_status)); + } } else { - $this->smarty->assign("submit_status",ldap_err2str($submit_status)); + $this->smarty->assign("submit_status","Invalid Data"); + $this->smarty->assign("validation_errors",$validation_errors); } } else { $this->smarty->assign("submit_status",-1); Modified: trunk/modules/content_domain_edit.php =================================================================== --- trunk/modules/content_domain_edit.php 2007-04-28 20:10:50 UTC (rev 61) +++ trunk/modules/content_domain_edit.php 2007-04-28 21:48:48 UTC (rev 62) @@ -67,8 +67,8 @@ $my_domain["mailstatus"] = "FALSE"; } - echo validate_domain($my_domain); - if (validate_domain($my_domain)) { + $validation_errors = validate_domain($my_domain); + if (count($validation_errors) == 0) { switch ($_POST["mode"]) { case "add": $this->ldap->addDomain($my_domain); @@ -85,7 +85,8 @@ $this->smarty->assign("submit_status",ldap_err2str($submit_status)); } } else { - $this->smarty->assign("submit_status","Invalid domain name."); + $this->smarty->assign("submit_status","Invalid Data"); + $this->smarty->assign("validation_errors",$validation_errors); } } else { $this->smarty->assign("submit_status",-1); Modified: trunk/modules/content_user_edit.php =================================================================== --- trunk/modules/content_user_edit.php 2007-04-28 20:10:50 UTC (rev 61) +++ trunk/modules/content_user_edit.php 2007-04-28 21:48:48 UTC (rev 62) @@ -62,29 +62,35 @@ unset($my_user["submit"]); unset($my_user["mode"]); - if (isset($_POST["mailstatus"]) { + if (isset($_POST["mailstatus"])) { $my_user["mailstatus"] = "TRUE"; } else { $my_user["mailstatus"] = "FALSE"; } $my_user["userpassword"] = $my_user["clearpassword"]; - $user = $my_user["uid"]; - switch ($_POST["mode"]) { - case "add": - $this->ldap->addUser($domain,$my_user); - break; - case "modify": - $this->ldap->modifyUser($domain,$my_user); - break; - } - - $submit_status = ldap_errno($this->ldap->cid); - if ($submit_status == "0") { - $this->smarty->assign("submit_status",$submit_status); + $validation_errors = validate_user($my_user); + if (count($validation_errors) == 0) { + switch ($_POST["mode"]) { + case "add": + $this->ldap->addUser($domain,$my_user); + break; + case "modify": + $this->ldap->modifyUser($domain,$my_user); + break; + } + + $submit_status = ldap_errno($this->ldap->cid); + if ($submit_status == "0") { + $this->smarty->assign("submit_status",$submit_status); + $user = $my_user["uid"]; + } else { + $this->smarty->assign("submit_status",ldap_err2str($submit_status)); + } } else { - $this->smarty->assign("submit_status",ldap_err2str($submit_status)); + $this->smarty->assign("submit_status","Invalid Data"); + $this->smarty->assign("validation_errors",$validation_errors); } } else { $this->smarty->assign("submit_status",-1); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <tux...@us...> - 2007-04-28 20:11:07
|
Revision: 61 http://elma.svn.sourceforge.net/elma/?rev=61&view=rev Author: tuxevara Date: 2007-04-28 13:10:50 -0700 (Sat, 28 Apr 2007) Log Message: ----------- basic input validation Modified Paths: -------------- trunk/includes/my_functions.inc.php trunk/modules/content_domain_edit.php trunk/templates/simple/content_domain_edit.tpl Modified: trunk/includes/my_functions.inc.php =================================================================== --- trunk/includes/my_functions.inc.php 2007-04-24 19:21:40 UTC (rev 60) +++ trunk/includes/my_functions.inc.php 2007-04-28 20:10:50 UTC (rev 61) @@ -1,68 +1,90 @@ -<?php -/** - * @author Daniel Weuthen <da...@we...> - * @version $LastChangedRevision$ - * @package ELMA - * - * $Id$ - * $LastChangedBy$ - * - * ===================================================================== - * - * 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, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA - * 02110-1301, USA - * - * ===================================================================== - */ + <?php + /** + * @author Daniel Weuthen <da...@we...> + * @version $LastChangedRevision$ + * @package ELMA + * + * $Id$ + * $LastChangedBy$ + * + * ===================================================================== + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA + * 02110-1301, USA + * + * ===================================================================== + */ -/** - * wrapper around print_r function - */ -function my_print_r ( $data ) { - echo "<pre>"; - print_r($data); - echo "</pre>"; -} + /** + * wrapper around print_r function + */ + function my_print_r ( $data ) { + echo "<pre>"; + print_r($data); + echo "</pre>"; + } -/** - * function to output debug messages - */ -function my_print_debug ( $message ) { - if ( DEBUG ) - { - echo "DEBUG: $message<br>\n"; + /** + * function to output debug messages + */ + function my_print_debug ( $message ) { + if ( DEBUG ) + { + echo "DEBUG: $message<br>\n"; + } } -} -/** - * remove keys from array that match given pattern - */ -function remove_key_by_str($array,$pattern) { - if( is_array($array) ) - { - $keys = array_keys($array); - foreach($keys as $key) - { - $length = strlen($pattern); - if(substr($key,0,$length) == $pattern) + /** + * remove keys from array that match given pattern + */ + function remove_key_by_str($array,$pattern) { + if( is_array($array) ) { - unset($array[$key]); + $keys = array_keys($array); + foreach($keys as $key) + { + $length = strlen($pattern); + if(substr($key,0,$length) == $pattern) + { + unset($array[$key]); + } + } } + return $array; } - } - return $array; + + + /** + * validate domain + */ + function validate_domain ($domain) { + $valid_domain_data = FALSE; + if (validate_data($domain["dc"],"domain")) $valid_domain_data = TRUE; + return $valid_domain_data; + } + + /** + * validate given data against regex + */ + function validate_data($string,$object) { + $valid_data = FALSE; + switch ($object) { + case "domain": if (preg_match("/^([a-zA-Z0-9]([a-zA-Z0-9\-]{0,61}[a-zA-Z0-9])?\.)+[a-zA-Z]{2,6}$/",$string)) $valid_data = TRUE; + break; + } + return $valid_data; } // vim:tabstop=4:expandtab:shiftwidth=4:filetype=php:syntax:ruler: Modified: trunk/modules/content_domain_edit.php =================================================================== --- trunk/modules/content_domain_edit.php 2007-04-24 19:21:40 UTC (rev 60) +++ trunk/modules/content_domain_edit.php 2007-04-28 20:10:50 UTC (rev 61) @@ -61,29 +61,32 @@ unset($my_domain["submit"]); unset($my_domain["mode"]); - if (isset($_POST["mailstatus"]) { + if (isset($_POST["mailstatus"])) { $my_domain["mailstatus"] = "TRUE"; } else { - $my_domain["mailstatus"] = "FALSE"); + $my_domain["mailstatus"] = "FALSE"; } - - $domain = $my_domain["dc"]; - - switch ($_POST["mode"]) { - case "add": - $this->ldap->addDomain($my_domain); - break; - case "modify": - $this->ldap->modifyDomain($my_domain); - break; + + echo validate_domain($my_domain); + if (validate_domain($my_domain)) { + switch ($_POST["mode"]) { + case "add": + $this->ldap->addDomain($my_domain); + break; + case "modify": + $this->ldap->modifyDomain($my_domain); + break; + } + $submit_status = ldap_errno($this->ldap->cid); + if ($submit_status == "0") { + $this->smarty->assign("submit_status",$submit_status); + $domain = $my_domain["dc"]; + } else { + $this->smarty->assign("submit_status",ldap_err2str($submit_status)); + } + } else { + $this->smarty->assign("submit_status","Invalid domain name."); } - - $submit_status = ldap_errno($this->ldap->cid); - if ($submit_status == "0") { - $this->smarty->assign("submit_status",$submit_status); - } else { - $this->smarty->assign("submit_status",ldap_err2str($submit_status)); - } } else { $this->smarty->assign("submit_status",-1); } Modified: trunk/templates/simple/content_domain_edit.tpl =================================================================== --- trunk/templates/simple/content_domain_edit.tpl 2007-04-24 19:21:40 UTC (rev 60) +++ trunk/templates/simple/content_domain_edit.tpl 2007-04-28 20:10:50 UTC (rev 61) @@ -7,7 +7,7 @@ </div> {else} <div> - {t}Sorry, your data could not be saved. The following LDAP error occured:{/t} {$submit_status} + {t}Sorry, your data could not be saved. The following error occured:{/t} {$submit_status} </div> {/if} {/if} This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <tux...@us...> - 2007-04-24 19:21:42
|
Revision: 60 http://elma.svn.sourceforge.net/elma/?rev=60&view=rev Author: tuxevara Date: 2007-04-24 12:21:40 -0700 (Tue, 24 Apr 2007) Log Message: ----------- added join parameter Modified Paths: -------------- trunk/bin/gen_po.sh Modified: trunk/bin/gen_po.sh =================================================================== --- trunk/bin/gen_po.sh 2007-04-24 19:18:20 UTC (rev 59) +++ trunk/bin/gen_po.sh 2007-04-24 19:21:40 UTC (rev 60) @@ -4,4 +4,4 @@ LOCALE=$2 tsmarty2c.php ../templates/$TEMPLATE/*.tpl > ../templates/$TEMPLATE/locale/$LOCALE/LC_MESSAGES/messages.c -xgettext -C ../templates/$TEMPLATE/locale/$LOCALE/LC_MESSAGES/messages.c -o ../templates/$TEMPLATE/locale/$LOCALE/LC_MESSAGES/messages.po --keyword=_ --add-comments --from-code=utf-8 +xgettext -j -C ../templates/$TEMPLATE/locale/$LOCALE/LC_MESSAGES/messages.c -o ../templates/$TEMPLATE/locale/$LOCALE/LC_MESSAGES/messages.po --keyword=_ --add-comments --from-code=utf-8 This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <tux...@us...> - 2007-04-24 19:18:25
|
Revision: 59 http://elma.svn.sourceforge.net/elma/?rev=59&view=rev Author: tuxevara Date: 2007-04-24 12:18:20 -0700 (Tue, 24 Apr 2007) Log Message: ----------- hmm, forgot what i changed here ;-) Modified Paths: -------------- trunk/includes/ldap_functions.inc.php Modified: trunk/includes/ldap_functions.inc.php =================================================================== --- trunk/includes/ldap_functions.inc.php 2007-04-23 21:09:53 UTC (rev 58) +++ trunk/includes/ldap_functions.inc.php 2007-04-24 19:18:20 UTC (rev 59) @@ -70,15 +70,16 @@ function connect() { - if ($this->cid = ldap_connect($this->hostname)) { - ldap_set_option($this->cid, LDAP_OPT_PROTOCOL_VERSION, 3); + if ($this->cid = @ldap_connect($this->hostname)) { + @ldap_set_option($this->cid, LDAP_OPT_PROTOCOL_VERSION, 3); if (function_exists("ldap_start_tls") && $this->tls) { - ldap_start_tls($this->cid); + @ldap_start_tls($this->cid); } - $this->result = 0; + $this->result = TRUE; } else { - $this->result = "Could not connect to LDAP server ".$this->hostname; + $this->result = FALSE; } + return $this->result; } function bind () { This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <tux...@us...> - 2007-04-23 21:09:54
|
Revision: 58 http://elma.svn.sourceforge.net/elma/?rev=58&view=rev Author: tuxevara Date: 2007-04-23 14:09:53 -0700 (Mon, 23 Apr 2007) Log Message: ----------- license and version file added Added Paths: ----------- trunk/LICENCE trunk/VERSION Added: trunk/LICENCE =================================================================== --- trunk/LICENCE (rev 0) +++ trunk/LICENCE 2007-04-23 21:09:53 UTC (rev 58) @@ -0,0 +1,339 @@ + GNU GENERAL PUBLIC LICENSE + Version 2, June 1991 + + Copyright (C) 1989, 1991 Free Software Foundation, Inc., + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + Preamble + + The licenses for most software are designed to take away your +freedom to share and change it. By contrast, the GNU General Public +License is intended to guarantee your freedom to share and change free +software--to make sure the software is free for all its users. This +General Public License applies to most of the Free Software +Foundation's software and to any other program whose authors commit to +using it. (Some other Free Software Foundation software is covered by +the GNU Lesser General Public License instead.) You can apply it to +your programs, too. + + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +this service if you wish), that you receive source code or can get it +if you want it, that you can change the software or use pieces of it +in new free programs; and that you know you can do these things. + + To protect your rights, we need to make restrictions that forbid +anyone to deny you these rights or to ask you to surrender the rights. +These restrictions translate to certain responsibilities for you if you +distribute copies of the software, or if you modify it. + + For example, if you distribute copies of such a program, whether +gratis or for a fee, you must give the recipients all the rights that +you have. You must make sure that they, too, receive or can get the +source code. And you must show them these terms so they know their +rights. + + We protect your rights with two steps: (1) copyright the software, and +(2) offer you this license which gives you legal permission to copy, +distribute and/or modify the software. + + Also, for each author's protection and ours, we want to make certain +that everyone understands that there is no warranty for this free +software. If the software is modified by someone else and passed on, we +want its recipients to know that what they have is not the original, so +that any problems introduced by others will not reflect on the original +authors' reputations. + + Finally, any free program is threatened constantly by software +patents. We wish to avoid the danger that redistributors of a free +program will individually obtain patent licenses, in effect making the +program proprietary. To prevent this, we have made it clear that any +patent must be licensed for everyone's free use or not licensed at all. + + The precise terms and conditions for copying, distribution and +modification follow. + + GNU GENERAL PUBLIC LICENSE + TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION + + 0. This License applies to any program or other work which contains +a notice placed by the copyright holder saying it may be distributed +under the terms of this General Public License. The "Program", below, +refers to any such program or work, and a "work based on the Program" +means either the Program or any derivative work under copyright law: +that is to say, a work containing the Program or a portion of it, +either verbatim or with modifications and/or translated into another +language. (Hereinafter, translation is included without limitation in +the term "modification".) Each licensee is addressed as "you". + +Activities other than copying, distribution and modification are not +covered by this License; they are outside its scope. The act of +running the Program is not restricted, and the output from the Program +is covered only if its contents constitute a work based on the +Program (independent of having been made by running the Program). +Whether that is true depends on what the Program does. + + 1. You may copy and distribute verbatim copies of the Program's +source code as you receive it, in any medium, provided that you +conspicuously and appropriately publish on each copy an appropriate +copyright notice and disclaimer of warranty; keep intact all the +notices that refer to this License and to the absence of any warranty; +and give any other recipients of the Program a copy of this License +along with the Program. + +You may charge a fee for the physical act of transferring a copy, and +you may at your option offer warranty protection in exchange for a fee. + + 2. You may modify your copy or copies of the Program or any portion +of it, thus forming a work based on the Program, and copy and +distribute such modifications or work under the terms of Section 1 +above, provided that you also meet all of these conditions: + + a) You must cause the modified files to carry prominent notices + stating that you changed the files and the date of any change. + + b) You must cause any work that you distribute or publish, that in + whole or in part contains or is derived from the Program or any + part thereof, to be licensed as a whole at no charge to all third + parties under the terms of this License. + + c) If the modified program normally reads commands interactively + when run, you must cause it, when started running for such + interactive use in the most ordinary way, to print or display an + announcement including an appropriate copyright notice and a + notice that there is no warranty (or else, saying that you provide + a warranty) and that users may redistribute the program under + these conditions, and telling the user how to view a copy of this + License. (Exception: if the Program itself is interactive but + does not normally print such an announcement, your work based on + the Program is not required to print an announcement.) + +These requirements apply to the modified work as a whole. If +identifiable sections of that work are not derived from the Program, +and can be reasonably considered independent and separate works in +themselves, then this License, and its terms, do not apply to those +sections when you distribute them as separate works. But when you +distribute the same sections as part of a whole which is a work based +on the Program, the distribution of the whole must be on the terms of +this License, whose permissions for other licensees extend to the +entire whole, and thus to each and every part regardless of who wrote it. + +Thus, it is not the intent of this section to claim rights or contest +your rights to work written entirely by you; rather, the intent is to +exercise the right to control the distribution of derivative or +collective works based on the Program. + +In addition, mere aggregation of another work not based on the Program +with the Program (or with a work based on the Program) on a volume of +a storage or distribution medium does not bring the other work under +the scope of this License. + + 3. You may copy and distribute the Program (or a work based on it, +under Section 2) in object code or executable form under the terms of +Sections 1 and 2 above provided that you also do one of the following: + + a) Accompany it with the complete corresponding machine-readable + source code, which must be distributed under the terms of Sections + 1 and 2 above on a medium customarily used for software interchange; or, + + b) Accompany it with a written offer, valid for at least three + years, to give any third party, for a charge no more than your + cost of physically performing source distribution, a complete + machine-readable copy of the corresponding source code, to be + distributed under the terms of Sections 1 and 2 above on a medium + customarily used for software interchange; or, + + c) Accompany it with the information you received as to the offer + to distribute corresponding source code. (This alternative is + allowed only for noncommercial distribution and only if you + received the program in object code or executable form with such + an offer, in accord with Subsection b above.) + +The source code for a work means the preferred form of the work for +making modifications to it. For an executable work, complete source +code means all the source code for all modules it contains, plus any +associated interface definition files, plus the scripts used to +control compilation and installation of the executable. However, as a +special exception, the source code distributed need not include +anything that is normally distributed (in either source or binary +form) with the major components (compiler, kernel, and so on) of the +operating system on which the executable runs, unless that component +itself accompanies the executable. + +If distribution of executable or object code is made by offering +access to copy from a designated place, then offering equivalent +access to copy the source code from the same place counts as +distribution of the source code, even though third parties are not +compelled to copy the source along with the object code. + + 4. You may not copy, modify, sublicense, or distribute the Program +except as expressly provided under this License. Any attempt +otherwise to copy, modify, sublicense or distribute the Program is +void, and will automatically terminate your rights under this License. +However, parties who have received copies, or rights, from you under +this License will not have their licenses terminated so long as such +parties remain in full compliance. + + 5. You are not required to accept this License, since you have not +signed it. However, nothing else grants you permission to modify or +distribute the Program or its derivative works. These actions are +prohibited by law if you do not accept this License. Therefore, by +modifying or distributing the Program (or any work based on the +Program), you indicate your acceptance of this License to do so, and +all its terms and conditions for copying, distributing or modifying +the Program or works based on it. + + 6. Each time you redistribute the Program (or any work based on the +Program), the recipient automatically receives a license from the +original licensor to copy, distribute or modify the Program subject to +these terms and conditions. You may not impose any further +restrictions on the recipients' exercise of the rights granted herein. +You are not responsible for enforcing compliance by third parties to +this License. + + 7. If, as a consequence of a court judgment or allegation of patent +infringement or for any other reason (not limited to patent issues), +conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot +distribute so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you +may not distribute the Program at all. For example, if a patent +license would not permit royalty-free redistribution of the Program by +all those who receive copies directly or indirectly through you, then +the only way you could satisfy both it and this License would be to +refrain entirely from distribution of the Program. + +If any portion of this section is held invalid or unenforceable under +any particular circumstance, the balance of the section is intended to +apply and the section as a whole is intended to apply in other +circumstances. + +It is not the purpose of this section to induce you to infringe any +patents or other property right claims or to contest validity of any +such claims; this section has the sole purpose of protecting the +integrity of the free software distribution system, which is +implemented by public license practices. Many people have made +generous contributions to the wide range of software distributed +through that system in reliance on consistent application of that +system; it is up to the author/donor to decide if he or she is willing +to distribute software through any other system and a licensee cannot +impose that choice. + +This section is intended to make thoroughly clear what is believed to +be a consequence of the rest of this License. + + 8. If the distribution and/or use of the Program is restricted in +certain countries either by patents or by copyrighted interfaces, the +original copyright holder who places the Program under this License +may add an explicit geographical distribution limitation excluding +those countries, so that distribution is permitted only in or among +countries not thus excluded. In such case, this License incorporates +the limitation as if written in the body of this License. + + 9. The Free Software Foundation may publish revised and/or new versions +of the General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns. + +Each version is given a distinguishing version number. If the Program +specifies a version number of this License which applies to it and "any +later version", you have the option of following the terms and conditions +either of that version or of any later version published by the Free +Software Foundation. If the Program does not specify a version number of +this License, you may choose any version ever published by the Free Software +Foundation. + + 10. If you wish to incorporate parts of the Program into other free +programs whose distribution conditions are different, write to the author +to ask for permission. For software which is copyrighted by the Free +Software Foundation, write to the Free Software Foundation; we sometimes +make exceptions for this. Our decision will be guided by the two goals +of preserving the free status of all derivatives of our free software and +of promoting the sharing and reuse of software generally. + + NO WARRANTY + + 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY +FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN +OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES +PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED +OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS +TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE +PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, +REPAIR OR CORRECTION. + + 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR +REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, +INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING +OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED +TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY +YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER +PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE +POSSIBILITY OF SUCH DAMAGES. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Programs + + If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these terms. + + To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +convey the exclusion of warranty; and each file should have at least +the "copyright" line and a pointer to where the full notice is found. + + <one line to give the program's name and a brief idea of what it does.> + Copyright (C) <year> <name of author> + + 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, write to the Free Software Foundation, Inc., + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + +Also add information on how to contact you by electronic and paper mail. + +If the program is interactive, make it output a short notice like this +when it starts in an interactive mode: + + Gnomovision version 69, Copyright (C) year name of author + Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. + This is free software, and you are welcome to redistribute it + under certain conditions; type `show c' for details. + +The hypothetical commands `show w' and `show c' should show the appropriate +parts of the General Public License. Of course, the commands you use may +be called something other than `show w' and `show c'; they could even be +mouse-clicks or menu items--whatever suits your program. + +You should also get your employer (if you work as a programmer) or your +school, if any, to sign a "copyright disclaimer" for the program, if +necessary. Here is a sample; alter the names: + + Yoyodyne, Inc., hereby disclaims all copyright interest in the program + `Gnomovision' (which makes passes at compilers) written by James Hacker. + + <signature of Ty Coon>, 1 April 1989 + Ty Coon, President of Vice + +This General Public License does not permit incorporating your program into +proprietary programs. If your program is a subroutine library, you may +consider it more useful to permit linking proprietary applications with the +library. If this is what you want to do, use the GNU Lesser General +Public License instead of this License. Added: trunk/VERSION =================================================================== --- trunk/VERSION (rev 0) +++ trunk/VERSION 2007-04-23 21:09:53 UTC (rev 58) @@ -0,0 +1 @@ +0.1-beta This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <tux...@us...> - 2007-04-23 21:03:07
|
Revision: 57 http://elma.svn.sourceforge.net/elma/?rev=57&view=rev Author: tuxevara Date: 2007-04-23 14:03:02 -0700 (Mon, 23 Apr 2007) Log Message: ----------- adding gpl headers Modified Paths: -------------- trunk/includes/class_ldap.inc.php trunk/includes/config.inc.php.dist trunk/includes/crypt.inc.php trunk/includes/gettext.inc.php trunk/includes/ldap_functions.inc.php trunk/includes/my_functions.inc.php trunk/includes/smarty.inc.php trunk/index.php trunk/login.php trunk/logout.php trunk/modules/content_alias_delete.php trunk/modules/content_alias_edit.php trunk/modules/content_domain_delete.php trunk/modules/content_domain_edit.php trunk/modules/content_domains_list.php trunk/modules/content_main.php trunk/modules/content_skeleton.php trunk/modules/content_user_delete.php trunk/modules/content_user_edit.php trunk/modules/content_users_list.php trunk/modules/modules.class.php Modified: trunk/includes/class_ldap.inc.php =================================================================== --- trunk/includes/class_ldap.inc.php 2007-04-23 15:38:28 UTC (rev 56) +++ trunk/includes/class_ldap.inc.php 2007-04-23 21:03:02 UTC (rev 57) @@ -1,5 +1,36 @@ <?php +/** + * @author Daniel Weuthen <da...@we...> + * @version $LastChangedRevision$ + * @package ELMA + * + * $Id$ + * $LastChangedBy$ + * + * ===================================================================== + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA + * 02110-1301, USA + * + * ===================================================================== + */ + +/** + * function to delete a complete ldap subtree recursivly + */ function myldap_delete($ds,$dn,$recursive=false){ if($recursive == false) @@ -24,6 +55,8 @@ } + + class USERS{ var $owner; Modified: trunk/includes/config.inc.php.dist =================================================================== --- trunk/includes/config.inc.php.dist 2007-04-23 15:38:28 UTC (rev 56) +++ trunk/includes/config.inc.php.dist 2007-04-23 21:03:02 UTC (rev 57) @@ -1,36 +1,74 @@ <?php -// ######## LDAP Settings ######## +/** + * @author Daniel Weuthen <da...@we...> + * @version $LastChangedRevision$ + * @package ELMA + * + * $Id$ + * $LastChangedBy$ + * + * ===================================================================== + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA + * 02110-1301, USA + * + * ===================================================================== + */ -/* LDAP Server hostname */ +/** + * This is the global configuration file for ELMA + */ + +/* ######## LDAP Settings ######## */ + +// LDAP Server hostname define ("LDAP_HOSTNAME","ldap://127.0.0.1"); -/* use TLS for LDAP connection */ +// use TLS for LDAP connection define ("LDAP_USE_TLS","0"); -/* LDAP Servers Base DN */ -define ("LDAP_BASEDN","o=megabit"); +// LDAP Servers Base DN +define ("LDAP_BASEDN","o=mycorp"); -/* LDAP Servers Base DN for domains*/ +// LDAP Servers Base DN for domains define ("LDAP_DOMAINS_ROOT_DN","ou=domains,".LDAP_BASEDN); -/* LDAP Servers Base DN for system user (e.g. admin)*/ +// LDAP Servers Base DN for system user (e.g. admin) define ("LDAP_USERS_ROOT_DN","ou=users,".LDAP_BASEDN); -// ######## Language Settings #### +/* ######## Language Settings #### */ +// Set the default language define ("DEFAULT_LANGUAGE","de_DE"); + +// Set all languages which should be available at login define ("AVAILABLE_LANGUAGES",serialize(array("deutsch" => "de_DE", "english" => "en_US" - )) - ); + ))); -// ######## Template Settings #### +/* ######## Template Settings #### */ +// Define template to use define ("TEMPLATE","simple"); -// ######## Application Settings #### +/* ######## Application Settings #### */ +// Define the applications root directory, getcwd() should work in most cases define('APPROOT',getcwd()); +// Define the session variable encryption key define('MYCRYPT_KEY',"my little key"); -?> + +// vim:tabstop=4:expandtab:shiftwidth=4:filetype=php:syntax:ruler: Modified: trunk/includes/crypt.inc.php =================================================================== --- trunk/includes/crypt.inc.php 2007-04-23 15:38:28 UTC (rev 56) +++ trunk/includes/crypt.inc.php 2007-04-23 21:03:02 UTC (rev 57) @@ -1,7 +1,43 @@ <?php +/** + * @author Daniel Weuthen <da...@we...> + * @version $LastChangedRevision$ + * @package ELMA + * + * $Id$ + * $LastChangedBy$ + * + * ===================================================================== + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA + * 02110-1301, USA + * + * ===================================================================== + */ + +/** + * class for easy text encryption and decryption my mycrypt + */ + class mycrypt { + /** + * the class constructor + */ + function mycrypt () { $this->key = MYCRYPT_KEY; $this->cipher = MCRYPT_RIJNDAEL_256; @@ -9,15 +45,21 @@ $iv_size = mcrypt_get_iv_size($this->cipher, $this->mode); $this->iv = mcrypt_create_iv($iv_size, MCRYPT_RAND); } - + + /** + * encryption function + */ function encrypt ($text) { $return_text = mcrypt_encrypt($this->cipher, $this->key, $text, $this->mode, $this->iv); - return($return_text); + return $return_text; } - + + /** + * decryption function + */ function decrypt ($text) { $return_text = mcrypt_decrypt($this->cipher, $this->key, $text, $this->mode, $this->iv); - return($return_text); + return $return_text; } } -?> +// vim:tabstop=4:expandtab:shiftwidth=4:filetype=php:syntax:ruler: Modified: trunk/includes/gettext.inc.php =================================================================== --- trunk/includes/gettext.inc.php 2007-04-23 15:38:28 UTC (rev 56) +++ trunk/includes/gettext.inc.php 2007-04-23 21:03:02 UTC (rev 57) @@ -1,4 +1,31 @@ <?php +/** + * @author Daniel Weuthen <da...@we...> + * @version $LastChangedRevision$ + * @package ELMA + * + * $Id$ + * $LastChangedBy$ + * + * ===================================================================== + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA + * 02110-1301, USA + * + * ===================================================================== + */ if ( isset($_SESSION["language"]) ) { $set_language = $_SESSION["language"]; @@ -14,4 +41,4 @@ bindtextdomain($domain, getcwd()."/templates/".TEMPLATE."/locale"); textdomain($domain); -?> +// vim:tabstop=4:expandtab:shiftwidth=4:filetype=php:syntax:ruler: Modified: trunk/includes/ldap_functions.inc.php =================================================================== --- trunk/includes/ldap_functions.inc.php 2007-04-23 15:38:28 UTC (rev 56) +++ trunk/includes/ldap_functions.inc.php 2007-04-23 21:03:02 UTC (rev 57) @@ -1,4 +1,36 @@ <?php +/** + * @author Daniel Weuthen <da...@we...> + * @version $LastChangedRevision$ + * @package ELMA + * + * $Id$ + * $LastChangedBy$ + * + * ===================================================================== + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA + * 02110-1301, USA + * + * ===================================================================== + */ + + +/** + * function to delete a complete ldap subtree recursivly + */ function my_ldap_delete($cid,$dn,$recursive=false) { if ( $recursive == false ) { return(ldap_delete($cid,$dn)); @@ -11,19 +43,19 @@ $result = my_ldap_delete($cid,$info[$i]['dn'],$recursive); if (!$result) { //return result code, if delete fails - return($result); + return $result; } } - return (ldap_delete($cid,$dn)); + return ldap_delete($cid,$dn); } } + class ELMA { var $tls = false; // Don't use TLS by default var $basedn = ""; // Base DN of LDAP Tree var $cid; // Connection ID - var $error = ""; // Any error messages to be returned, value of 0 if no error, otherwise error string var $binddn = ""; // DN for binding to LDAP var $bindpw = ""; // Password for DN var $hostname = ""; // Hostname or IP of LDAP Server @@ -55,28 +87,26 @@ } else { $this->result = FALSE; } - return($this->result); + return $this->result; } function last_error () { $error = @ldap_error($this->cid); - return($error); + return $error; } # DOMAIN function listDomains () { - //$result = ldap_list($this->cid, LDAP_DOMAINS_ROOT_DN, "dc=*"); - //$domains = ldap_get_entries($this->cid, $result); $domains = $this->getDomain(); - return($domains); + return $domains; } function getDomain ($domain_dc = "*") { $result = ldap_list($this->cid, LDAP_DOMAINS_ROOT_DN, "dc=".$domain_dc); $domain = ldap_get_entries($this->cid, $result); if ( $domain_dc !== "*" ) $domain = $domain[0]; - return($domain); + return $domain; } function addDomain ( $domain ) { @@ -87,7 +117,7 @@ } else { $result = 0; } - return ($result); + return $result; } function modifyDomain ( $domain ) { @@ -97,7 +127,7 @@ } else { $result = 0; } - return ($result); + return $result; } function deleteDomain ( $domain ) { @@ -107,24 +137,22 @@ } else { $result = 0; } - return ($result); + return $result; } # USER function listUsers( $domain ) { - //$result = ldap_list($this->cid,"dc=".$domain.",".LDAP_DOMAINS_ROOT_DN, "(&(objectclass=mailUser))"); - //$users = ldap_get_entries($this->cid, $result); $users = $this->getUser( $domain ); - return($users); + return $users; } function getUser ( $domain, $user_uid = "*") { $result = ldap_list($this->cid, "dc=".$domain.",".LDAP_DOMAINS_ROOT_DN, "(&(objectclass=mailUser)(uid=$user_uid))"); $user = ldap_get_entries($this->cid, $result); if ( $user_uid !== "*" ) $user = $user[0]; - return($user); + return $user; } function addUser ( $domain, $user) { @@ -135,7 +163,7 @@ } else { $result = 0; } - return ($result); + return $result; } function modifyUser ( $domain, $user) { @@ -145,7 +173,7 @@ } else { $result = 0; } - return ($result); + return $result; } function deleteUser ( $domain, $user) { @@ -155,21 +183,21 @@ } else { $result = 0; } - return ($result); + return $result; } # ALIAS function listAliases( $domain ) { $aliases = $this->getAlias( $domain ); - return($aliases); + return $aliases; } function getAlias ( $domain, $alias_uid = "*") { $result = ldap_list($this->cid,"dc=".$domain.",".LDAP_DOMAINS_ROOT_DN, "(&(objectclass=mailAlias)(uid=$alias_uid))"); $alias = ldap_get_entries($this->cid, $result); if ( $alias_uid !== "*" ) $alias = $alias[0]; - return($alias); + return $alias; } function addAlias ( $domain, $alias) { @@ -180,7 +208,7 @@ } else { $result = 0; } - return ($result); + return $result; } function modifyAlias ( $domain, $alias) { @@ -190,7 +218,7 @@ } else { $result = 0; } - return ($result); + return $result; } function deleteAlias ( $domain, $alias) { @@ -201,8 +229,7 @@ } else { $result = 0; } - return ($result); + return $result; } } // vim:tabstop=4:expandtab:shiftwidth=4:filetype=php:syntax:ruler: -?> Modified: trunk/includes/my_functions.inc.php =================================================================== --- trunk/includes/my_functions.inc.php 2007-04-23 15:38:28 UTC (rev 56) +++ trunk/includes/my_functions.inc.php 2007-04-23 21:03:02 UTC (rev 57) @@ -1,11 +1,44 @@ <?php +/** + * @author Daniel Weuthen <da...@we...> + * @version $LastChangedRevision$ + * @package ELMA + * + * $Id$ + * $LastChangedBy$ + * + * ===================================================================== + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA + * 02110-1301, USA + * + * ===================================================================== + */ +/** + * wrapper around print_r function + */ function my_print_r ( $data ) { echo "<pre>"; print_r($data); echo "</pre>"; } +/** + * function to output debug messages + */ function my_print_debug ( $message ) { if ( DEBUG ) { @@ -13,6 +46,9 @@ } } +/** + * remove keys from array that match given pattern + */ function remove_key_by_str($array,$pattern) { if( is_array($array) ) { @@ -30,4 +66,3 @@ } // vim:tabstop=4:expandtab:shiftwidth=4:filetype=php:syntax:ruler: -?> Modified: trunk/includes/smarty.inc.php =================================================================== --- trunk/includes/smarty.inc.php 2007-04-23 15:38:28 UTC (rev 56) +++ trunk/includes/smarty.inc.php 2007-04-23 21:03:02 UTC (rev 57) @@ -1,4 +1,32 @@ <?php +/** + * @author Daniel Weuthen <da...@we...> + * @version $LastChangedRevision$ + * @package ELMA + * + * $Id$ + * $LastChangedBy$ + * + * ===================================================================== + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA + * 02110-1301, USA + * + * ===================================================================== + */ + require("/usr/share/php/smarty/libs/Smarty.class.php"); $smarty = new Smarty; @@ -9,4 +37,3 @@ $smarty->assign('template_path',"templates/".TEMPLATE); // vim:tabstop=4:expandtab:shiftwidth=4:filetype=php:syntax:ruler: -?> Modified: trunk/index.php =================================================================== --- trunk/index.php 2007-04-23 15:38:28 UTC (rev 56) +++ trunk/index.php 2007-04-23 21:03:02 UTC (rev 57) @@ -1,4 +1,33 @@ <?php +/** + * @author Daniel Weuthen <da...@we...> + * @version $LastChangedRevision$ + * @package ELMA + * + * $Id$ + * $LastChangedBy$ + * + * ===================================================================== + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA + * 02110-1301, USA + * + * ===================================================================== + */ + + session_start(); require("includes/config.inc.php"); @@ -35,4 +64,3 @@ $smarty->display("footer.tpl"); } // vim:tabstop=4:expandtab:shiftwidth=4:filetype=php:syntax:ruler: -?> Modified: trunk/login.php =================================================================== --- trunk/login.php 2007-04-23 15:38:28 UTC (rev 56) +++ trunk/login.php 2007-04-23 21:03:02 UTC (rev 57) @@ -1,11 +1,39 @@ <?php +/** + * @author Daniel Weuthen <da...@we...> + * @version $LastChangedRevision$ + * @package ELMA + * + * $Id$ + * $LastChangedBy$ + * + * ===================================================================== + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA + * 02110-1301, USA + * + * ===================================================================== + */ + +session_start (); + require("includes/config.inc.php"); require("includes/ldap_functions.inc.php"); require("includes/my_functions.inc.php"); require("includes/crypt.inc.php"); -session_start (); - $ldap = new ELMA(LDAP_HOSTNAME); $ldap->connect(); @@ -45,4 +73,3 @@ } } // vim:tabstop=4:expandtab:shiftwidth=4:filetype=php:syntax:ruler: -?> Modified: trunk/logout.php =================================================================== --- trunk/logout.php 2007-04-23 15:38:28 UTC (rev 56) +++ trunk/logout.php 2007-04-23 21:03:02 UTC (rev 57) @@ -1,4 +1,31 @@ <?php +/** + * @author Daniel Weuthen <da...@we...> + * @version $LastChangedRevision$ + * @package ELMA + * + * $Id$ + * $LastChangedBy$ + * + * ===================================================================== + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA + * 02110-1301, USA + * + * ===================================================================== + */ session_start(); session_destroy(); @@ -6,4 +33,3 @@ exit; // vim:tabstop=4:expandtab:shiftwidth=4:filetype=php:syntax:ruler: -?> Modified: trunk/modules/content_alias_delete.php =================================================================== --- trunk/modules/content_alias_delete.php 2007-04-23 15:38:28 UTC (rev 56) +++ trunk/modules/content_alias_delete.php 2007-04-23 21:03:02 UTC (rev 57) @@ -1,29 +1,37 @@ <?php -/* Copyright (C) 2007 Daniel Weuthen +/** + * @author Daniel Weuthen <da...@we...> + * @version $LastChangedRevision$ + * @package ELMA + * + * $Id$ + * $LastChangedBy$ + * + * ===================================================================== + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA + * 02110-1301, USA + * + * ===================================================================== + */ - 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, write to the Free Software - Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA - 02110-1301, USA */ - - /** - * Content User Delete + * content alias delete * - * This content module is used to get a delete confirmation - * - * @author Daniel Weuthen <da...@we...> - * + * This content module is used to get a delete confirmation for aliases. */ class content_alias_delete extends module_base @@ -44,12 +52,18 @@ */ function proceed() { - if ( isset($_POST["submit"]) ) { + if (isset($_POST["submit"])) { $uid = $_POST["uid"]; $domain = $_POST["domain"]; $this->ldap->deleteAlias($domain,$uid); $submit_status = ldap_errno($this->ldap->cid); - ($submit_status == "0" ? $this->smarty->assign("submit_status",$submit_status) : $this->smarty->assign("submit_status",ldap_err2str($submit_status))); + + if ($submit_status == "0") { + $this->smarty->assign("submit_status",$submit_status); + } else { + $this->smarty->assign("submit_status",ldap_err2str($submit_status)); + } + } else { $uid = $_GET["alias"]; $domain = $_GET["domain"]; @@ -60,8 +74,7 @@ } /** - * This method returns any content that should be echoed by the - * main page. + * This method returns any content that should be echoed by the main page. * * @return string */ @@ -72,4 +85,3 @@ } } // vim:tabstop=4:expandtab:shiftwidth=4:filetype=php:syntax:ruler: -?> Modified: trunk/modules/content_alias_edit.php =================================================================== --- trunk/modules/content_alias_edit.php 2007-04-23 15:38:28 UTC (rev 56) +++ trunk/modules/content_alias_edit.php 2007-04-23 21:03:02 UTC (rev 57) @@ -1,19 +1,44 @@ <?php /** - * Content Alias Edit - * - * This content module is used for creating the alias edit form. - * * @author Daniel Weuthen <da...@we...> + * @version $LastChangedRevision$ + * @package ELMA * + * $Id$ + * $LastChangedBy$ + * + * ===================================================================== + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA + * 02110-1301, USA + * + * ===================================================================== */ +/** + * content alias edit + * + * This content module is used for creating the alias edit form and handling + * the submited data. + */ + class content_alias_edit extends module_base { /** * Constructor of this class - * */ function content_alias_edit() { @@ -22,7 +47,6 @@ /** * This method is called after the constructor by the main page - * */ function proceed() { @@ -51,7 +75,11 @@ break; } $submit_status = ldap_errno($this->ldap->cid); - ($submit_status == "0" ? $this->smarty->assign("submit_status",$submit_status) : $this->smarty->assign("submit_status",ldap_err2str($submit_status))); + if ($submit_status == "0") { + $this->smarty->assign("submit_status",$submit_status); + } else { + $this->smarty->assign("submit_status",ldap_err2str($submit_status)); + } } else { $this->smarty->assign("submit_status",-1); } @@ -78,4 +106,3 @@ } } // vim:tabstop=4:expandtab:shiftwidth=4:filetype=php:syntax:ruler: -?> Modified: trunk/modules/content_domain_delete.php =================================================================== --- trunk/modules/content_domain_delete.php 2007-04-23 15:38:28 UTC (rev 56) +++ trunk/modules/content_domain_delete.php 2007-04-23 21:03:02 UTC (rev 57) @@ -1,19 +1,44 @@ <?php /** - * Content User Delete - * - * This content module is used to get a delete confirmation - * * @author Daniel Weuthen <da...@we...> + * @version $LastChangedRevision$ + * @package ELMA * + * $Id$ + * $LastChangedBy$ + * + * ===================================================================== + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA + * 02110-1301, USA + * + * ===================================================================== */ +/** + * content user delete + * + * This content module is used to get a delete confirmation when deleting + * a domain. + */ + class content_domain_delete extends module_base { /** * Constructor of this class - * */ function content_domain_delete() { @@ -22,7 +47,6 @@ /** * This method is called after the constructor by the main page - * */ function proceed() { @@ -30,7 +54,11 @@ $domain = $_POST["domain"]; $this->ldap->deleteDomain($domain); $submit_status = ldap_errno($this->ldap->cid); - ($submit_status == "0" ? $this->smarty->assign("submit_status",$submit_status) : $this->smarty->assign("submit_status",ldap_err2str($submit_status))); + if ($submit_status == "0") { + $this->smarty->assign("submit_status",$submit_status); + } else { + $this->smarty->assign("submit_status",ldap_err2str($submit_status)); + } } else { $domain = $_GET["domain"]; $this->smarty->assign("domain",$domain); @@ -51,4 +79,3 @@ } } // vim:tabstop=4:expandtab:shiftwidth=4:filetype=php:syntax:ruler: -?> Modified: trunk/modules/content_domain_edit.php =================================================================== --- trunk/modules/content_domain_edit.php 2007-04-23 15:38:28 UTC (rev 56) +++ trunk/modules/content_domain_edit.php 2007-04-23 21:03:02 UTC (rev 57) @@ -1,19 +1,44 @@ <?php /** - * Content Domain Edit - * - * This content module is used for creating the domain edit form. - * * @author Daniel Weuthen <da...@we...> + * @version $LastChangedRevision$ + * @package ELMA * + * $Id$ + * $LastChangedBy$ + * + * ===================================================================== + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA + * 02110-1301, USA + * + * ===================================================================== */ +/** + * content domain edit + * + * This content module is used for creating the domain edit form and + * handling the submited data. + */ + class content_domain_edit extends module_base { /** * Constructor of this class - * */ function content_domain_edit() { @@ -22,7 +47,6 @@ /** * This method is called after the constructor by the main page - * */ function proceed() { @@ -37,7 +61,11 @@ unset($my_domain["submit"]); unset($my_domain["mode"]); - (isset($_POST["mailstatus"]) ? $my_domain["mailstatus"] = "TRUE" : $my_domain["mailstatus"] = "FALSE"); + if (isset($_POST["mailstatus"]) { + $my_domain["mailstatus"] = "TRUE"; + } else { + $my_domain["mailstatus"] = "FALSE"); + } $domain = $my_domain["dc"]; @@ -49,8 +77,13 @@ $this->ldap->modifyDomain($my_domain); break; } + $submit_status = ldap_errno($this->ldap->cid); - ($submit_status == "0" ? $this->smarty->assign("submit_status",$submit_status) : $this->smarty->assign("submit_status",ldap_err2str($submit_status))); + if ($submit_status == "0") { + $this->smarty->assign("submit_status",$submit_status); + } else { + $this->smarty->assign("submit_status",ldap_err2str($submit_status)); + } } else { $this->smarty->assign("submit_status",-1); } @@ -76,4 +109,3 @@ } } // vim:tabstop=4:expandtab:shiftwidth=4:filetype=php:syntax:ruler: -?> Modified: trunk/modules/content_domains_list.php =================================================================== --- trunk/modules/content_domains_list.php 2007-04-23 15:38:28 UTC (rev 56) +++ trunk/modules/content_domains_list.php 2007-04-23 21:03:02 UTC (rev 57) @@ -1,13 +1,38 @@ <?php /** -* Domain Module -* -* This module is used for domian maintenance, eg. list, add, etc. -* -* @author Daniel Weuthen -* -*/ + * @author Daniel Weuthen <da...@we...> + * @version $LastChangedRevision$ + * @package ELMA + * + * $Id$ + * $LastChangedBy$ + * + * ===================================================================== + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA + * 02110-1301, USA + * + * ===================================================================== + */ +/** + * Domain Module + * + * This module is used for listing available domains + */ + class content_domains_list extends module_base { /** @@ -21,7 +46,6 @@ /** * This method is called after the constructor by the main page - * */ function proceed() { @@ -52,4 +76,3 @@ } } // vim:tabstop=4:expandtab:shiftwidth=4:filetype=php:syntax:ruler: -?> Modified: trunk/modules/content_main.php =================================================================== --- trunk/modules/content_main.php 2007-04-23 15:38:28 UTC (rev 56) +++ trunk/modules/content_main.php 2007-04-23 21:03:02 UTC (rev 57) @@ -1,12 +1,36 @@ <?php /** + * @author Daniel Weuthen <da...@we...> and Rudolph Bott <rb...@me...> + * @version $LastChangedRevision$ + * @package ELMA + * + * $Id$ + * $LastChangedBy$ + * + * ===================================================================== + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA + * 02110-1301, USA + * + * ===================================================================== + */ + +/** * Content Module Main * * This module displays the main page - * - * @author Rudolph Bott <rb...@me...> - * @author Daniel Weuthen <da...@we...> - * @package elma */ class content_main extends module_base @@ -35,4 +59,3 @@ } } // vim:tabstop=4:expandtab:shiftwidth=4:filetype=php:syntax:ruler: -?> Modified: trunk/modules/content_skeleton.php =================================================================== --- trunk/modules/content_skeleton.php 2007-04-23 15:38:28 UTC (rev 56) +++ trunk/modules/content_skeleton.php 2007-04-23 21:03:02 UTC (rev 57) @@ -1,52 +1,64 @@ <?php /** -* Content Module Template -* -* Use this content module as a template for new modules -* -* @author John Doe -* -*/ + * @author John Doe <jd...@jd...> + * @version $LastChangedRevision$ + * @package ELMA + * + * $Id$ + * $LastChangedBy$ + * + * ===================================================================== + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA + * 02110-1301, USA + * + * ===================================================================== + */ +/** + * Content Module Template + * + * Use this content module as a template for new modules + */ + class content_template extends module_base { /** - * Constructor of this class - * - */ + * Constructor of this class + */ function content_template() { } - /** - * This method is called after the constructor by the main page - * - */ + /** + * This method is called after the constructor by the main page + */ function proceed() { } - /** - * construct and return menu for page template - * - */ - function getMenu() - { - $menu[]['link'] = $_SERVER['PHP_SELF'] . '?module=template'; - $menu[count($menu)-1]['title'] = 'Template'; - return $menu; - } - /** * This method returns any content that should be echoed by the * main page. * - * @return string - */ + * @return string + */ function getContent() { $_content = $this->smarty->fetch('content_template.tpl'); @@ -54,4 +66,3 @@ } } // vim:tabstop=4:expandtab:shiftwidth=4:filetype=php:syntax:ruler: -?> Modified: trunk/modules/content_user_delete.php =================================================================== --- trunk/modules/content_user_delete.php 2007-04-23 15:38:28 UTC (rev 56) +++ trunk/modules/content_user_delete.php 2007-04-23 21:03:02 UTC (rev 57) @@ -1,19 +1,43 @@ <?php /** - * Content User Delete - * - * This content module is used to get a delete confirmation - * * @author Daniel Weuthen <da...@we...> + * @version $LastChangedRevision$ + * @package ELMA * + * $Id$ + * $LastChangedBy$ + * + * ===================================================================== + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA + * 02110-1301, USA + * + * ===================================================================== */ +/** + * Content User Delete + * + * This content module is used to get a delete confirmation for users. + */ + class content_user_delete extends module_base { /** * Constructor of this class - * */ function content_template() { @@ -22,7 +46,6 @@ /** * This method is called after the constructor by the main page - * */ function proceed() { @@ -30,8 +53,13 @@ $uid = $_POST["uid"]; $domain = $_POST["domain"]; $this->ldap->deleteUser($domain,$uid); + $submit_status = ldap_errno($this->ldap->cid); - ($submit_status == "0" ? $this->smarty->assign("submit_status",$submit_status) : $this->smarty->assign("submit_status",ldap_err2str($submit_status))); + if ($submit_status == "0") { + $this->smarty->assign("submit_status",$submit_status); + } else { + $this->smarty->assign("submit_status",ldap_err2str($submit_status)); + } } else { $uid = $_GET["user"]; $domain = $_GET["domain"]; @@ -54,4 +82,3 @@ } } // vim:tabstop=4:expandtab:shiftwidth=4:filetype=php:syntax:ruler: -?> Modified: trunk/modules/content_user_edit.php =================================================================== --- trunk/modules/content_user_edit.php 2007-04-23 15:38:28 UTC (rev 56) +++ trunk/modules/content_user_edit.php 2007-04-23 21:03:02 UTC (rev 57) @@ -1,19 +1,44 @@ <?php /** - * Content User Edit - * - * This content module is used for creating the user edit form. - * * @author Daniel Weuthen <da...@we...> + * @version $LastChangedRevision$ + * @package ELMA * + * $Id$ + * $LastChangedBy$ + * + * ===================================================================== + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA + * 02110-1301, USA + * + * ===================================================================== */ +/** + * content user edit + * + * This content module is used for creating the user edit/add form and + * handling the submited data. + */ + class content_user_edit extends module_base { /** * Constructor of this class - * */ function content_user_edit() { @@ -22,7 +47,6 @@ /** * This method is called after the constructor by the main page - * */ function proceed() { @@ -30,7 +54,7 @@ $domain = $_GET["domain"]; $this->smarty->assign("domain",$domain); - // new user created or existing user altert + // new user created or existing user modified if (isset($_POST["submit"])) { // remove all non LDAP objects from submited form // an the submit and mode value @@ -38,9 +62,13 @@ unset($my_user["submit"]); unset($my_user["mode"]); - (isset($_POST["mailstatus"]) ? $my_user["mailstatus"] = "TRUE" : $my_user["mailstatus"] = "FALSE"); + if (isset($_POST["mailstatus"]) { + $my_user["mailstatus"] = "TRUE"; + } else { + $my_user["mailstatus"] = "FALSE"; + } + $my_user["userpassword"] = $my_user["clearpassword"]; - $user = $my_user["uid"]; switch ($_POST["mode"]) { @@ -51,8 +79,13 @@ $this->ldap->modifyUser($domain,$my_user); break; } + $submit_status = ldap_errno($this->ldap->cid); - ($submit_status == "0" ? $this->smarty->assign("submit_status",$submit_status) : $this->smarty->assign("submit_status",ldap_err2str($submit_status))); + if ($submit_status == "0") { + $this->smarty->assign("submit_status",$submit_status); + } else { + $this->smarty->assign("submit_status",ldap_err2str($submit_status)); + } } else { $this->smarty->assign("submit_status",-1); } @@ -78,4 +111,3 @@ } } // vim:tabstop=4:expandtab:shiftwidth=4:filetype=php:syntax:ruler: -?> Modified: trunk/modules/content_users_list.php =================================================================== --- trunk/modules/content_users_list.php 2007-04-23 15:38:28 UTC (rev 56) +++ trunk/modules/content_users_list.php 2007-04-23 21:03:02 UTC (rev 57) @@ -1,27 +1,49 @@ <?php /** -* Domain Module -* -* This module is used to create a list for users for the given domain. -* -* @author Daniel Weuthen -* -*/ + * @author Daniel Weuthen <da...@we...> + * @version $LastChangedRevision$ + * @package ELMA + * + * $Id$ + * $LastChangedBy$ + * + * ===================================================================== + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA + * 02110-1301, USA + * + * ===================================================================== + */ +/** + * Domain Module + * + * This module is used to create a list of users for the given domain. + */ + class content_users_list extends module_base { /** * Constructor of this class - * */ function content_users_list() { parent::module_base(); } - /** * This method is called after the constructor by the main page - * */ function proceed() { @@ -43,9 +65,7 @@ $this->smarty->assign("link_newuser",$_SERVER['PHP_SELF']."?module=user_edit&domain=".$domain."&user=new"); $this->smarty->assign('users',$my_users); - /** - * prepare aliases array for smarty output - */ + // prepare aliases array for smarty output $my_aliases = array(); $aliases = $this->ldap->listAliases($domain); for ($i = 0; $i < $aliases["count"]; $i++) { @@ -71,4 +91,3 @@ } } // vim:tabstop=4:expandtab:shiftwidth=4:filetype=php:syntax:ruler: -?> Modified: trunk/modules/modules.class.php =================================================================== --- trunk/modules/modules.class.php 2007-04-23 15:38:28 UTC (rev 56) +++ trunk/modules/modules.class.php 2007-04-23 21:03:02 UTC (rev 57) @@ -1,24 +1,46 @@ <?php /** + * @author Daniel Weuthen <da...@we...> and Rudolph Bott <rb...@me...> + * @version $LastChangedRevision$ + * @package ELMA + * + * $Id$ + * $LastChangedBy$ + * + * ===================================================================== + * + * 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, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA + * 02110-1301, USA + * + * ===================================================================== + */ + +/** * module factory * * This class contains a factory to call modules. This makes * calling modules by index.php much easier. - * - * $Id:: $ - * $LastChangedBy:: $ - * $LastChangedDate:: $ - * $LastChangedRevision:: $ - * */ class modules { + /** * factory-method * * @param string type * @return object class on success, error message on error - * */ function &factory($type = "main") { if (!file_exists(APPROOT."/modules/content_${type}.php")) { @@ -43,7 +65,6 @@ * This is the base class for all content modules * All modules should be inherited from this class! * - * @author Rudolph Bott * */ @@ -59,10 +80,16 @@ function module_base() { $crypt = new mycrypt(); $this->ldap = new ELMA(LDAP_HOSTNAME); - $this->ldap->connect(); + + if (! $this->ldap->connect()) { + echo $this->ldap->last_error(); + } + $this->ldap->binddn = $crypt->decrypt($_SESSION["ldap_binddn"]); $this->ldap->bindpw = $crypt->decrypt($_SESSION["ldap_bindpass"]); - if ( ! $this->ldap->bind() ) echo $this->ldap->last_error(); + if (! $this->ldap->bind()) { + echo $this->ldap->last_error(); + } } /** @@ -73,13 +100,6 @@ } /** - * return errors (if any) - */ - function getErrors() { - return $errors; - } - - /** * This method returns any content that should be echoed by the * main page. * @@ -88,6 +108,4 @@ function getContent() { } } - // vim:tabstop=4:expandtab:shiftwidth=4:filetype=php:syntax:ruler: -?> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <tux...@us...> - 2007-04-23 16:34:17
|
Revision: 56 http://elma.svn.sourceforge.net/elma/?rev=56&view=rev Author: tuxevara Date: 2007-04-23 08:38:28 -0700 (Mon, 23 Apr 2007) Log Message: ----------- resolved auth error Modified Paths: -------------- trunk/includes/ldap_functions.inc.php trunk/login.php trunk/modules/content_alias_delete.php trunk/modules/content_alias_edit.php trunk/modules/content_domain_edit.php trunk/modules/content_user_edit.php trunk/modules/modules.class.php Modified: trunk/includes/ldap_functions.inc.php =================================================================== --- trunk/includes/ldap_functions.inc.php 2007-04-22 22:22:29 UTC (rev 55) +++ trunk/includes/ldap_functions.inc.php 2007-04-23 15:38:28 UTC (rev 56) @@ -50,13 +50,19 @@ } function bind () { - if ($bind = ldap_bind($this->cid, $this->binddn, $this->bindpw)) { - $this->result = 0; + if ( @ldap_bind($this->cid, $this->binddn, $this->bindpw) ) { + $this->result = TRUE; } else { - $this->result = "Could not bind ".$this->binddn." to host ".$this->hostname; + $this->result = FALSE; } + return($this->result); } + function last_error () { + $error = @ldap_error($this->cid); + return($error); + } + # DOMAIN function listDomains () { Modified: trunk/login.php =================================================================== --- trunk/login.php 2007-04-22 22:22:29 UTC (rev 55) +++ trunk/login.php 2007-04-23 15:38:28 UTC (rev 56) @@ -21,7 +21,10 @@ } if (isset($LDAP_BINDDN) && isset($LDAP_BINDPASS)) { - if ($ldap->bind($LDAP_BINDDN,$LDAP_BINDPASS) == 0) { + $ldap->binddn = $LDAP_BINDDN; + $ldap->bindpw = $LDAP_BINDPASS; + + if ( $ldap->bind() ) { $_SESSION["login"] = TRUE; $_SESSION["logintime"] = time(); $_SESSION["username"] = $_POST["username"]; @@ -34,9 +37,11 @@ header ("Location: index.php"); exit; } else { - echo "error"; + echo $ldap->last_error(); session_destroy(); } + } else { + echo "Invalid username."; } } // vim:tabstop=4:expandtab:shiftwidth=4:filetype=php:syntax:ruler: Modified: trunk/modules/content_alias_delete.php =================================================================== --- trunk/modules/content_alias_delete.php 2007-04-22 22:22:29 UTC (rev 55) +++ trunk/modules/content_alias_delete.php 2007-04-23 15:38:28 UTC (rev 56) @@ -1,4 +1,22 @@ <?php +/* Copyright (C) 2007 Daniel Weuthen + + 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, write to the Free Software + Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA + 02110-1301, USA */ + + /** * Content User Delete * Modified: trunk/modules/content_alias_edit.php =================================================================== --- trunk/modules/content_alias_edit.php 2007-04-22 22:22:29 UTC (rev 55) +++ trunk/modules/content_alias_edit.php 2007-04-23 15:38:28 UTC (rev 56) @@ -15,9 +15,9 @@ * Constructor of this class * */ - function content_template() + function content_alias_edit() { - + parent::module_base(); } /** Modified: trunk/modules/content_domain_edit.php =================================================================== --- trunk/modules/content_domain_edit.php 2007-04-22 22:22:29 UTC (rev 55) +++ trunk/modules/content_domain_edit.php 2007-04-23 15:38:28 UTC (rev 56) @@ -15,9 +15,9 @@ * Constructor of this class * */ - function content_template() + function content_domain_edit() { - + parent::module_base(); } /** @@ -27,6 +27,7 @@ function proceed() { $domain = $_GET["domain"]; + $this->smarty->assign("domain",$domain); // new domain created or existing domain altert if (isset($_POST["submit"])) { @@ -38,10 +39,11 @@ (isset($_POST["mailstatus"]) ? $my_domain["mailstatus"] = "TRUE" : $my_domain["mailstatus"] = "FALSE"); + $domain = $my_domain["dc"]; + switch ($_POST["mode"]) { case "add": $this->ldap->addDomain($my_domain); - $domain = $my_domain["dc"]; break; case "modify": $this->ldap->modifyDomain($my_domain); Modified: trunk/modules/content_user_edit.php =================================================================== --- trunk/modules/content_user_edit.php 2007-04-22 22:22:29 UTC (rev 55) +++ trunk/modules/content_user_edit.php 2007-04-23 15:38:28 UTC (rev 56) @@ -17,7 +17,7 @@ */ function content_user_edit() { - + parent::module_base(); } /** Modified: trunk/modules/modules.class.php =================================================================== --- trunk/modules/modules.class.php 2007-04-22 22:22:29 UTC (rev 55) +++ trunk/modules/modules.class.php 2007-04-23 15:38:28 UTC (rev 56) @@ -62,7 +62,7 @@ $this->ldap->connect(); $this->ldap->binddn = $crypt->decrypt($_SESSION["ldap_binddn"]); $this->ldap->bindpw = $crypt->decrypt($_SESSION["ldap_bindpass"]); - $this->ldap->bind($this->ldap->binddn,$this->ldap->bindpw); + if ( ! $this->ldap->bind() ) echo $this->ldap->last_error(); } /** This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <tux...@us...> - 2007-04-22 22:22:36
|
Revision: 55 http://elma.svn.sourceforge.net/elma/?rev=55&view=rev Author: tuxevara Date: 2007-04-22 15:22:29 -0700 (Sun, 22 Apr 2007) Log Message: ----------- deleting something needs a confirmation now some template changes to make translating easier. Modified Paths: -------------- trunk/modules/content_alias_edit.php trunk/modules/content_domains_list.php trunk/modules/content_user_delete.php trunk/modules/content_user_edit.php trunk/modules/content_users_list.php trunk/templates/simple/content_alias_edit.tpl trunk/templates/simple/content_domain_edit.tpl trunk/templates/simple/content_domains_list.tpl trunk/templates/simple/content_user_delete.tpl trunk/templates/simple/content_user_edit.tpl trunk/templates/simple/content_users_list.tpl trunk/templates/simple/locale/de_DE/LC_MESSAGES/messages.c trunk/templates/simple/locale/de_DE/LC_MESSAGES/messages.mo trunk/templates/simple/locale/de_DE/LC_MESSAGES/messages.po trunk/templates/simple/style.css Added Paths: ----------- trunk/modules/content_alias_delete.php trunk/modules/content_domain_delete.php trunk/templates/simple/content_alias_delete.tpl trunk/templates/simple/content_domain_delete.tpl Added: trunk/modules/content_alias_delete.php =================================================================== --- trunk/modules/content_alias_delete.php (rev 0) +++ trunk/modules/content_alias_delete.php 2007-04-22 22:22:29 UTC (rev 55) @@ -0,0 +1,57 @@ +<?php +/** + * Content User Delete + * + * This content module is used to get a delete confirmation + * + * @author Daniel Weuthen <da...@we...> + * + */ + +class content_alias_delete extends module_base +{ + + /** + * Constructor of this class + * + */ + function content_alias_delete() + { + parent::module_base(); + } + + /** + * This method is called after the constructor by the main page + * + */ + function proceed() + { + if ( isset($_POST["submit"]) ) { + $uid = $_POST["uid"]; + $domain = $_POST["domain"]; + $this->ldap->deleteAlias($domain,$uid); + $submit_status = ldap_errno($this->ldap->cid); + ($submit_status == "0" ? $this->smarty->assign("submit_status",$submit_status) : $this->smarty->assign("submit_status",ldap_err2str($submit_status))); + } else { + $uid = $_GET["alias"]; + $domain = $_GET["domain"]; + $this->smarty->assign("domain",$domain); + $this->smarty->assign("alias",$this->ldap->getAlias($domain,$uid)); + $this->smarty->assign("submit_status",-1); + } + } + + /** + * This method returns any content that should be echoed by the + * main page. + * + * @return string + */ + function getContent() + { + $_content = $this->smarty->fetch('content_alias_delete.tpl'); + return $_content; + } +} +// vim:tabstop=4:expandtab:shiftwidth=4:filetype=php:syntax:ruler: +?> Modified: trunk/modules/content_alias_edit.php =================================================================== --- trunk/modules/content_alias_edit.php 2007-04-17 20:35:22 UTC (rev 54) +++ trunk/modules/content_alias_edit.php 2007-04-22 22:22:29 UTC (rev 55) @@ -28,6 +28,8 @@ { $alias = $_GET["alias"]; $domain = $_GET["domain"]; + $this->smarty->assign("domain",$domain); + // new alias created or existing alias altert if (isset($_POST["submit"])) { // remove all non LDAP objects from submited form @@ -38,10 +40,11 @@ $my_alias["mailaliasedname"] = explode("\n", $_POST['nlo_mailaliasedname']); + $alias = $my_alias["uid"]; + switch ($_POST["mode"]) { case "add": $this->ldap->addAlias($domain,$my_alias); - $alias = $my_alias["uid"]; break; case "modify": $this->ldap->modifyAlias($domain,$my_alias); @@ -59,6 +62,7 @@ $this->smarty->assign("mode","modify"); $this->smarty->assign("alias",$this->ldap->getAlias($domain,$alias)); } + } /** Added: trunk/modules/content_domain_delete.php =================================================================== --- trunk/modules/content_domain_delete.php (rev 0) +++ trunk/modules/content_domain_delete.php 2007-04-22 22:22:29 UTC (rev 55) @@ -0,0 +1,54 @@ +<?php +/** + * Content User Delete + * + * This content module is used to get a delete confirmation + * + * @author Daniel Weuthen <da...@we...> + * + */ + +class content_domain_delete extends module_base +{ + + /** + * Constructor of this class + * + */ + function content_domain_delete() + { + parent::module_base(); + } + + /** + * This method is called after the constructor by the main page + * + */ + function proceed() + { + if ( isset($_POST["submit"]) ) { + $domain = $_POST["domain"]; + $this->ldap->deleteDomain($domain); + $submit_status = ldap_errno($this->ldap->cid); + ($submit_status == "0" ? $this->smarty->assign("submit_status",$submit_status) : $this->smarty->assign("submit_status",ldap_err2str($submit_status))); + } else { + $domain = $_GET["domain"]; + $this->smarty->assign("domain",$domain); + $this->smarty->assign("submit_status",-1); + } + } + + /** + * This method returns any content that should be echoed by the + * main page. + * + * @return string + */ + function getContent() + { + $_content = $this->smarty->fetch('content_domain_delete.tpl'); + return $_content; + } +} +// vim:tabstop=4:expandtab:shiftwidth=4:filetype=php:syntax:ruler: +?> Modified: trunk/modules/content_domains_list.php =================================================================== --- trunk/modules/content_domains_list.php 2007-04-17 20:35:22 UTC (rev 54) +++ trunk/modules/content_domains_list.php 2007-04-22 22:22:29 UTC (rev 55) @@ -25,10 +25,6 @@ */ function proceed() { - if ((isset($_GET["mode"])) && ($_GET["mode"] == "delete")) { - $this->ldap->deleteDomain($_GET["domain"]); - } - $my_domains = array(); $domains = $this->ldap->listDomains(); @@ -36,7 +32,7 @@ $domain['dc'] = $domains[$i]["dc"][0]; $domain['mailstatus'] = $domains[$i]["mailstatus"][0]; $domain['userslink'] = $_SERVER['PHP_SELF']."?module=users_list&domain=".$domain['dc']; - $domain['deletelink'] = $_SERVER['PHP_SELF']."?module=domains_list&domain=".$domain['dc']."&mode=delete"; + $domain['deletelink'] = $_SERVER['PHP_SELF']."?module=domain_delete&domain=".$domain['dc']; $domain['editlink'] = $_SERVER['PHP_SELF']."?module=domain_edit&domain=".$domain['dc']; array_push($my_domains,$domain); } Modified: trunk/modules/content_user_delete.php =================================================================== --- trunk/modules/content_user_delete.php 2007-04-17 20:35:22 UTC (rev 54) +++ trunk/modules/content_user_delete.php 2007-04-22 22:22:29 UTC (rev 55) @@ -33,7 +33,7 @@ $submit_status = ldap_errno($this->ldap->cid); ($submit_status == "0" ? $this->smarty->assign("submit_status",$submit_status) : $this->smarty->assign("submit_status",ldap_err2str($submit_status))); } else { - $uid = $_GET["uid"]; + $uid = $_GET["user"]; $domain = $_GET["domain"]; $this->smarty->assign("domain",$domain); $this->smarty->assign("user",$this->ldap->getUser($domain,$uid)); Modified: trunk/modules/content_user_edit.php =================================================================== --- trunk/modules/content_user_edit.php 2007-04-17 20:35:22 UTC (rev 54) +++ trunk/modules/content_user_edit.php 2007-04-22 22:22:29 UTC (rev 55) @@ -15,7 +15,7 @@ * Constructor of this class * */ - function content_template() + function content_user_edit() { } @@ -28,6 +28,8 @@ { $user = $_GET["user"]; $domain = $_GET["domain"]; + $this->smarty->assign("domain",$domain); + // new user created or existing user altert if (isset($_POST["submit"])) { // remove all non LDAP objects from submited form @@ -38,11 +40,12 @@ (isset($_POST["mailstatus"]) ? $my_user["mailstatus"] = "TRUE" : $my_user["mailstatus"] = "FALSE"); $my_user["userpassword"] = $my_user["clearpassword"]; + + $user = $my_user["uid"]; switch ($_POST["mode"]) { case "add": $this->ldap->addUser($domain,$my_user); - $user = $my_user["uid"]; break; case "modify": $this->ldap->modifyUser($domain,$my_user); Modified: trunk/modules/content_users_list.php =================================================================== --- trunk/modules/content_users_list.php 2007-04-17 20:35:22 UTC (rev 54) +++ trunk/modules/content_users_list.php 2007-04-22 22:22:29 UTC (rev 55) @@ -36,12 +36,11 @@ for ($i = 0; $i < $users["count"]; $i++) { $user['uid'] = $users[$i]["uid"][0]; $user['mailstatus'] = $users[$i]["mailstatus"][0]; - $user['deletelink'] = $_SERVER['PHP_SELF']."?module=user_delete&domain=".$domain."&uid=".$user['uid']."&mode=delete"; + $user['deletelink'] = $_SERVER['PHP_SELF']."?module=user_delete&domain=".$domain."&user=".$user['uid']."&mode=delete"; $user['editlink'] = $_SERVER['PHP_SELF']."?module=user_edit&domain=".$domain."&user=".$user['uid']; array_push($my_users,$user); } $this->smarty->assign("link_newuser",$_SERVER['PHP_SELF']."?module=user_edit&domain=".$domain."&user=new"); - $this->smarty->assign("link_newalias",$_SERVER['PHP_SELF']."?module=alias_edit&domain=".$domain."&alias=new"); $this->smarty->assign('users',$my_users); /** @@ -52,12 +51,11 @@ for ($i = 0; $i < $aliases["count"]; $i++) { $alias['uid'] = $aliases[$i]["uid"][0]; $alias['mailaliasedname'] = $aliases[$i]["mailaliasedname"]; - $alias['deletelink'] = $_SERVER['PHP_SELF']."?module=aliases_list&domain=".$domain."&alias=".$alias['uid']."&mode=delete"; + $alias['deletelink'] = $_SERVER['PHP_SELF']."?module=alias_delete&domain=".$domain."&alias=".$alias['uid']; $alias['editlink'] = $_SERVER['PHP_SELF']."?module=alias_edit&domain=".$domain."&alias=".$alias['uid']; array_push($my_aliases,$alias); } $this->smarty->assign("link_newalias",$_SERVER['PHP_SELF']."?module=alias_edit&domain=".$domain."&alias=new"); - $this->smarty->assign("link_newalias",$_SERVER['PHP_SELF']."?module=alias_edit&domain=".$domain."&alias=new"); $this->smarty->assign('aliases',$my_aliases); } Added: trunk/templates/simple/content_alias_delete.tpl =================================================================== --- trunk/templates/simple/content_alias_delete.tpl (rev 0) +++ trunk/templates/simple/content_alias_delete.tpl 2007-04-22 22:22:29 UTC (rev 55) @@ -0,0 +1,40 @@ + <div id="Content"> + <h2>{t}Delete Alias{/t}</h2> + {if $smarty.post.submit} + {if $submit_status == "0"} + <div> + {t}Data saved successfully.{/t} + </div> + {else} + <div> + {t}Sorry, your data could not be saved. The following LDAP error occured:{/t} {$submit_status} + </div> + {/if} + {else} + <form action="{$smarty.server.php_self}" method="post"> + <fieldset> + <legend>{$alias.uid.0}@{$domain}</legend> + <table> + <tr> + <td> + {t 1=$alias.uid.0 2=$domain}Are you sure you want to delete alias %1@%2?{/t} + <input type="hidden" name="uid" value="{$alias.uid.0}" /> + <input type="hidden" name="domain" value="{$domain}" /> + </td> + </tr> + <tr> + <td> </td> + <td> + <input type="submit" name="submit" value="{t}Yes{/t}"/> + <input type="reset" name="reset" value="{t}No{/t}"/> + </td> + </tr> + </table> + </fieldset> + </form> + {/if} + </div> + +{* +// vim:tabstop=4:expandtab:shiftwidth=4:filetype=smarty:syntax:ruler: +*} Modified: trunk/templates/simple/content_alias_edit.tpl =================================================================== --- trunk/templates/simple/content_alias_edit.tpl 2007-04-17 20:35:22 UTC (rev 54) +++ trunk/templates/simple/content_alias_edit.tpl 2007-04-22 22:22:29 UTC (rev 55) @@ -17,7 +17,7 @@ </div> <fieldset> {if $mode == "modify"} - <legend>{$alias.uid.0}</legend> + <legend>{$alias.uid.0}@{$domain}</legend> <table> <tr> <td> @@ -53,7 +53,7 @@ <tr> <td> </td> <td> - <input type="submit" name="submit" /> + <input type="submit" name="submit" value="{t}Save{/t}"/> </td> </tr> </table> Added: trunk/templates/simple/content_domain_delete.tpl =================================================================== --- trunk/templates/simple/content_domain_delete.tpl (rev 0) +++ trunk/templates/simple/content_domain_delete.tpl 2007-04-22 22:22:29 UTC (rev 55) @@ -0,0 +1,39 @@ + <div id="Content"> + <h2>{t}Delete Domain{/t}</h2> + {if $smarty.post.submit} + {if $submit_status == "0"} + <div> + {t}Data saved successfully.{/t} + </div> + {else} + <div> + {t}Sorry, your data could not be saved. The following LDAP error occured:{/t} {$submit_status} + </div> + {/if} + {else} + <form action="{$smarty.server.php_self}" method="post"> + <fieldset> + <legend>{$domain}</legend> + <table> + <tr> + <td> + {t 1=$domain}Are you sure you want to delete domain %1?{/t} + <input type="hidden" name="domain" value="{$domain}" /> + </td> + </tr> + <tr> + <td> </td> + <td> + <input type="submit" name="submit" value="{t}Yes{/t}"/> + <input type="reset" name="reset" value="{t}No{/t}"/> + </td> + </tr> + </table> + </fieldset> + </form> + {/if} + </div> + +{* +// vim:tabstop=4:expandtab:shiftwidth=4:filetype=smarty:syntax:ruler: +*} Modified: trunk/templates/simple/content_domain_edit.tpl =================================================================== --- trunk/templates/simple/content_domain_edit.tpl 2007-04-17 20:35:22 UTC (rev 54) +++ trunk/templates/simple/content_domain_edit.tpl 2007-04-22 22:22:29 UTC (rev 55) @@ -32,7 +32,7 @@ </tr> <tr> <td> </td> - <td><input type="submit" name="submit" /></td> + <td><input type="submit" name="submit" value="{t}Save{/t}" /></td> </tr> </table> </fieldset> @@ -59,7 +59,7 @@ <tr> <td> </td> <td> - <input type="submit" name="submit" /> + <input type="submit" name="submit" value="{t}Save{/t}"/> </td> </tr> </table> Modified: trunk/templates/simple/content_domains_list.tpl =================================================================== --- trunk/templates/simple/content_domains_list.tpl 2007-04-17 20:35:22 UTC (rev 54) +++ trunk/templates/simple/content_domains_list.tpl 2007-04-22 22:22:29 UTC (rev 55) @@ -2,9 +2,9 @@ <h2>Domains</h2> <table> <tr> - <th>Domain</th> - <th>Status</th> - <th class="command">Command</th> + <th>{t}Domain{/t}</th> + <th>{t}Status{/t}</th> + <th class="command">{t}Command{/t}</th> </tr> {section name=domains_sec loop=$domains} <tr> Modified: trunk/templates/simple/content_user_delete.tpl =================================================================== --- trunk/templates/simple/content_user_delete.tpl 2007-04-17 20:35:22 UTC (rev 54) +++ trunk/templates/simple/content_user_delete.tpl 2007-04-22 22:22:29 UTC (rev 55) @@ -17,7 +17,7 @@ <table> <tr> <td> - Are you sure you want to delete user {$user.uid.0}@{$domain}? + {t 1=$user.uid.0 2=$domain}Are you sure you want to delete user %1@%2?{/t} <input type="hidden" name="uid" value="{$user.uid.0}" /> <input type="hidden" name="domain" value="{$domain}" /> </td> @@ -25,7 +25,8 @@ <tr> <td> </td> <td> - <input type="submit" name="submit" /> + <input type="submit" name="submit" value="{t}Yes{/t}"/> + <input type="reset" name="reset" value="{t}No{/t}"/> </td> </tr> </table> Modified: trunk/templates/simple/content_user_edit.tpl =================================================================== --- trunk/templates/simple/content_user_edit.tpl 2007-04-17 20:35:22 UTC (rev 54) +++ trunk/templates/simple/content_user_edit.tpl 2007-04-22 22:22:29 UTC (rev 55) @@ -17,7 +17,7 @@ </div> <fieldset> {if $mode == "modify"} - <legend>{$user.uid.0}</legend> + <legend>{$user.uid.0}@{$domain}</legend> <table> <tr> <td> @@ -32,7 +32,7 @@ {t}User{/t} </td> <td> - <input type="text" name="uid" value="{$user.uid.0}" /> + <input type="text" name="uid" value="{$user.uid.0}" />@{$domain} </td> </tr> {/if} @@ -76,7 +76,7 @@ <tr> <td> </td> <td> - <input type="submit" name="submit" /> + <input type="submit" name="submit" value="{t}Save{/t}"/> </td> </tr> </table> Modified: trunk/templates/simple/content_users_list.tpl =================================================================== --- trunk/templates/simple/content_users_list.tpl 2007-04-17 20:35:22 UTC (rev 54) +++ trunk/templates/simple/content_users_list.tpl 2007-04-22 22:22:29 UTC (rev 55) @@ -2,9 +2,9 @@ <h2>{t}Users for domain{/t} {$domain}</h2> <table> <tr> - <th>Users</th> - <th>Status</th> - <th class="command">Command</th> + <th>{t}User{/t}</th> + <th>{t}Status{/t}</th> + <th class="command">{t}Command{/t}</th> </tr> {section name=users_sec loop=$users} <tr> @@ -35,9 +35,9 @@ <div class="space25"></div> <table> <tr> - <th>Alias</th> - <th>Alias for</th> - <th class="command">Command</th> + <th>{t}Alias{/t}</th> + <th>{t}Alias for{/t}</th> + <th class="command">{t}Command{/t}</th> </tr> {section name=aliases_sec loop=$aliases} <tr> Modified: trunk/templates/simple/locale/de_DE/LC_MESSAGES/messages.c =================================================================== --- trunk/templates/simple/locale/de_DE/LC_MESSAGES/messages.c 2007-04-17 20:35:22 UTC (rev 54) +++ trunk/templates/simple/locale/de_DE/LC_MESSAGES/messages.c 2007-04-22 22:22:29 UTC (rev 55) @@ -1,3 +1,135 @@ +/* ../templates/simple/content_alias_delete.tpl */ +gettext("Delete Alias"); + +/* ../templates/simple/content_alias_delete.tpl */ +gettext("Data saved successfully."); + +/* ../templates/simple/content_alias_delete.tpl */ +gettext("Sorry, your data could not be saved. The following LDAP error occured:"); + +/* ../templates/simple/content_alias_delete.tpl */ +gettext("Are you sure you want to delete alias"); + +/* ../templates/simple/content_alias_edit.tpl */ +gettext("Edit Alias"); + +/* ../templates/simple/content_alias_edit.tpl */ +gettext("Data saved successfully."); + +/* ../templates/simple/content_alias_edit.tpl */ +gettext("Sorry, your data could not be saved. The following LDAP error occured:"); + +/* ../templates/simple/content_alias_edit.tpl */ +gettext("new Alias"); + +/* ../templates/simple/content_alias_edit.tpl */ +gettext("Alias"); + +/* ../templates/simple/content_alias_edit.tpl */ +gettext("Alias for"); + +/* ../templates/simple/content_domain_delete.tpl */ +gettext("Delete Domain"); + +/* ../templates/simple/content_domain_delete.tpl */ +gettext("Data saved successfully."); + +/* ../templates/simple/content_domain_delete.tpl */ +gettext("Sorry, your data could not be saved. The following LDAP error occured:"); + +/* ../templates/simple/content_domain_delete.tpl */ +gettext("Are you sure you want to delete domain %1?"); + +/* ../templates/simple/content_domain_edit.tpl */ +gettext("Edit Domain"); + +/* ../templates/simple/content_domain_edit.tpl */ +gettext("Data saved successfully."); + +/* ../templates/simple/content_domain_edit.tpl */ +gettext("Sorry, your data could not be saved. The following LDAP error occured:"); + +/* ../templates/simple/content_domain_edit.tpl */ +gettext("Status"); + +/* ../templates/simple/content_domain_edit.tpl */ +gettext("new Domain"); + +/* ../templates/simple/content_domain_edit.tpl */ +gettext("Domain"); + +/* ../templates/simple/content_domain_edit.tpl */ +gettext("Status"); + +/* ../templates/simple/content_domains_list.tpl */ +gettext("edit"); + +/* ../templates/simple/content_domains_list.tpl */ +gettext("delete"); + +/* ../templates/simple/content_domains_list.tpl */ +gettext("new domain"); + +/* ../templates/simple/content_user_delete.tpl */ +gettext("Delete User"); + +/* ../templates/simple/content_user_delete.tpl */ +gettext("Data saved successfully."); + +/* ../templates/simple/content_user_delete.tpl */ +gettext("Sorry, your data could not be saved. The following LDAP error occured:"); + +/* ../templates/simple/content_user_delete.tpl */ +gettext("Are you sure you want to delete user"); + +/* ../templates/simple/content_user_edit.tpl */ +gettext("Edit User"); + +/* ../templates/simple/content_user_edit.tpl */ +gettext("Data saved successfully."); + +/* ../templates/simple/content_user_edit.tpl */ +gettext("Sorry, your data could not be saved. The following LDAP error occured:"); + +/* ../templates/simple/content_user_edit.tpl */ +gettext("new User"); + +/* ../templates/simple/content_user_edit.tpl */ +gettext("User"); + +/* ../templates/simple/content_user_edit.tpl */ +gettext("First Name"); + +/* ../templates/simple/content_user_edit.tpl */ +gettext("Last Name"); + +/* ../templates/simple/content_user_edit.tpl */ +gettext("Status"); + +/* ../templates/simple/content_user_edit.tpl */ +gettext("Password"); + +/* ../templates/simple/content_users_list.tpl */ +gettext("Users for domain"); + +/* ../templates/simple/content_users_list.tpl */ +gettext("edit"); + +/* ../templates/simple/content_users_list.tpl */ +gettext("delete"); + +/* ../templates/simple/content_users_list.tpl */ +gettext("new user"); + +/* ../templates/simple/content_users_list.tpl */ +gettext("edit"); + +/* ../templates/simple/content_users_list.tpl */ +gettext("delete"); + +/* ../templates/simple/content_users_list.tpl */ +gettext("new alias"); + /* ../templates/simple/login.tpl */ gettext("Username"); @@ -5,6 +137,9 @@ gettext("Password"); /* ../templates/simple/login.tpl */ +gettext("Language"); + +/* ../templates/simple/login.tpl */ gettext("Login"); /* ../templates/simple/navigation.tpl */ Modified: trunk/templates/simple/locale/de_DE/LC_MESSAGES/messages.mo =================================================================== (Binary files differ) Modified: trunk/templates/simple/locale/de_DE/LC_MESSAGES/messages.po =================================================================== --- trunk/templates/simple/locale/de_DE/LC_MESSAGES/messages.po 2007-04-17 20:35:22 UTC (rev 54) +++ trunk/templates/simple/locale/de_DE/LC_MESSAGES/messages.po 2007-04-22 22:22:29 UTC (rev 55) @@ -8,7 +8,7 @@ msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2007-04-03 17:02+0200\n" +"POT-Creation-Date: 2007-04-22 22:58+0200\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" "Language-Team: LANGUAGE <LL...@li...>\n" @@ -16,32 +16,203 @@ "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -#. ../templates/simple/login.tpl +#. ../templates/simple/content_alias_delete.tpl #: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:2 -msgid "Username" -msgstr "Benutzername" +msgid "Delete Alias" +msgstr "" +#. ../templates/simple/content_alias_delete.tpl +#. ../templates/simple/content_alias_edit.tpl +#. ../templates/simple/content_domain_delete.tpl +#. ../templates/simple/content_domain_edit.tpl +#. ../templates/simple/content_user_delete.tpl +#. ../templates/simple/content_user_edit.tpl +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:5 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:17 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:35 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:47 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:77 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:89 +msgid "Data saved successfully." +msgstr "" + +#. ../templates/simple/content_alias_delete.tpl +#. ../templates/simple/content_alias_edit.tpl +#. ../templates/simple/content_domain_delete.tpl +#. ../templates/simple/content_domain_edit.tpl +#. ../templates/simple/content_user_delete.tpl +#. ../templates/simple/content_user_edit.tpl +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:8 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:20 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:38 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:50 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:80 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:92 +msgid "Sorry, your data could not be saved. The following LDAP error occured:" +msgstr "" + +#. ../templates/simple/content_alias_delete.tpl +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:11 +msgid "Are you sure you want to delete alias" +msgstr "" + +#. ../templates/simple/content_alias_edit.tpl +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:14 +msgid "Edit Alias" +msgstr "" + +#. ../templates/simple/content_alias_edit.tpl +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:23 +msgid "new Alias" +msgstr "" + +#. ../templates/simple/content_alias_edit.tpl +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:26 +msgid "Alias" +msgstr "" + +#. ../templates/simple/content_alias_edit.tpl +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:29 +msgid "Alias for" +msgstr "" + +#. ../templates/simple/content_domain_delete.tpl +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:32 +msgid "Delete Domain" +msgstr "" + +#. ../templates/simple/content_domain_delete.tpl +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:41 +msgid "Are you sure you want to delete domain %1?" +msgstr "Sind sie Sicher, dass Sie die Domaene %1 loeschen wollen?" + +#. ../templates/simple/content_domain_edit.tpl +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:44 +msgid "Edit Domain" +msgstr "" + +#. ../templates/simple/content_domain_edit.tpl +#. ../templates/simple/content_user_edit.tpl +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:53 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:62 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:107 +msgid "Status" +msgstr "" + +#. ../templates/simple/content_domain_edit.tpl +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:56 +msgid "new Domain" +msgstr "" + +#. ../templates/simple/content_domain_edit.tpl +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:59 +msgid "Domain" +msgstr "" + +#. ../templates/simple/content_domains_list.tpl +#. ../templates/simple/content_users_list.tpl +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:65 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:116 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:125 +msgid "edit" +msgstr "" + +#. ../templates/simple/content_domains_list.tpl +#. ../templates/simple/content_users_list.tpl +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:68 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:119 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:128 +msgid "delete" +msgstr "" + +#. ../templates/simple/content_domains_list.tpl +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:71 +msgid "new domain" +msgstr "" + +#. ../templates/simple/content_user_delete.tpl +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:74 +msgid "Delete User" +msgstr "" + +#. ../templates/simple/content_user_delete.tpl +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:83 +msgid "Are you sure you want to delete user" +msgstr "" + +#. ../templates/simple/content_user_edit.tpl +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:86 +msgid "Edit User" +msgstr "" + +#. ../templates/simple/content_user_edit.tpl +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:95 +msgid "new User" +msgstr "" + +#. ../templates/simple/content_user_edit.tpl +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:98 +msgid "User" +msgstr "" + +#. ../templates/simple/content_user_edit.tpl +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:101 +msgid "First Name" +msgstr "" + +#. ../templates/simple/content_user_edit.tpl +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:104 +msgid "Last Name" +msgstr "" + +#. ../templates/simple/content_user_edit.tpl #. ../templates/simple/login.tpl -#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:5 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:110 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:137 msgid "Password" -msgstr "Passwort" +msgstr "" +#. ../templates/simple/content_users_list.tpl +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:113 +msgid "Users for domain" +msgstr "" + +#. ../templates/simple/content_users_list.tpl +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:122 +msgid "new user" +msgstr "" + +#. ../templates/simple/content_users_list.tpl +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:131 +msgid "new alias" +msgstr "" + #. ../templates/simple/login.tpl -#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:8 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:134 +msgid "Username" +msgstr "" + +#. ../templates/simple/login.tpl +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:140 +msgid "Language" +msgstr "" + +#. ../templates/simple/login.tpl +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:143 msgid "Login" -msgstr "Anmelden" +msgstr "" #. ../templates/simple/navigation.tpl -#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:11 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:146 msgid "Home" -msgstr "Übersicht" +msgstr "" #. ../templates/simple/navigation.tpl -#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:14 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:149 msgid "Domains" -msgstr "Domänen" +msgstr "" #. ../templates/simple/navigation.tpl -#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:17 +#: ../templates/simple/locale/de_DE/LC_MESSAGES/messages.c:152 msgid "Logout" -msgstr "Abmelden" +msgstr "" Modified: trunk/templates/simple/style.css =================================================================== --- trunk/templates/simple/style.css 2007-04-17 20:35:22 UTC (rev 54) +++ trunk/templates/simple/style.css 2007-04-22 22:22:29 UTC (rev 55) @@ -174,7 +174,7 @@ border-left: 2px #99CCFF solid; border-right: 2px #99CCFF solid; padding-left: 5px; - width: 15%; + padding-right: 5px; } .space25 { This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |