Discussion:
Dynamic, Minimalist, Traditional selection?
(too old to reply)
horde
2008-10-09 14:22:03 UTC
Permalink
I know I used to have the option to select which GUI to log on as
(Dynamic, Minimalist, Traditional ) but somehow it's gone.

/horde/imp/config/conf.php $conf['user']['select_view'] = true;

MIMP and DIMP both work if I actively select the URL
http://server/horde/mimp or http://server/horde/dimp

What setting am I missing? Thx

Rick



Rick Steeves
http://www.sinister.net

"The journey is the destination"
marta
2008-10-09 19:34:32 UTC
Permalink
Dear List,

I'm trying to access my horde email using Outlook in Brazil but I am
having problems sending the emails. This is the text that appears:

The message could not be sent. The configuration of authentication may
be incorrect for the outgoing server e-mail [SMTP]. For help on how to
resolve this problem, go to Help, search for "Troubleshoot Windows
Mail" and read the section titled "Issues to send email." If you need
help to determine the appropriate configurations of the server,
contact your email service provider.

The rejected e-mail address was' marta at gostudy.com.au '. Subject
'test', Account: 'Marta', Server: 'smtp.ig.com.br', Protocol: SMTP,
Server Response:'530 5.7.0 Must issue a STARTTLS command first.
2sm1488894aga.3 ', Port: 25, Secure (SSL): No, Server Error: 530, No
of error: 0x800CCC78



I already double check with my internet provider, and they told me
that?s nothing they could do for me.

Can someone please help me in this matter?


Thanks Marta
Andrew Morgan
2008-10-09 20:17:47 UTC
Permalink
Post by marta
Dear List,
I'm trying to access my horde email using Outlook in Brazil but I am having
The message could not be sent. The configuration of authentication may be
incorrect for the outgoing server e-mail [SMTP]. For help on how to resolve
this problem, go to Help, search for "Troubleshoot Windows Mail" and read the
section titled "Issues to send email." If you need help to determine the
appropriate configurations of the server, contact your email service
provider.
The rejected e-mail address was' marta at gostudy.com.au '. Subject 'test',
Account: 'Marta', Server: 'smtp.ig.com.br', Protocol: SMTP, Server
Response:'530 5.7.0 Must issue a STARTTLS command first. 2sm1488894aga.3 ',
Port: 25, Secure (SSL): No, Server Error: 530, No of error: 0x800CCC78
I already double check with my internet provider, and they told me that?s
nothing they could do for me.
Can someone please help me in this matter?
Horde is an email client, not an email server. Based on the error message
above, it sounds like you need to change your Outlook settings to make a
secure connection to the outgoing mail server (SMTP). But, this is not a
question for the Horde mailing list.

Andy
Michael Rubinsky
2008-10-09 20:28:38 UTC
Permalink
Post by marta
Dear List,
I'm trying to access my horde email using Outlook in Brazil but I am
The message could not be sent. The configuration of authentication
may be incorrect for the outgoing server e-mail [SMTP]. For help on
how to resolve this problem, go to Help, search for "Troubleshoot
Windows Mail" and read the section titled "Issues to send email." If
you need help to determine the appropriate configurations of the
server, contact your email service provider.
The rejected e-mail address was' marta at gostudy.com.au '. Subject
'test', Account: 'Marta', Server: 'smtp.ig.com.br', Protocol: SMTP,
Server Response:'530 5.7.0 Must issue a STARTTLS command first.
2sm1488894aga.3 ', Port: 25, Secure (SSL): No, Server Error: 530, No
of error: 0x800CCC78
This has nothing to do with Horde, and is exactly what it says. You
need to properly configure your outgoing mail server in Outlook.

http://wiki.horde.org/ICantGetMyMail

Thanks,
mike

--
The Horde Project (www.horde.org)
mrubinsk at horde.org

"Time just hates me. That's why it made me an adult." - Josh Joplin
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: PGP Digital Signature
URL: <http://lists.horde.org/archives/horde/attachments/20081009/36810894/attachment.bin>
horde
2008-10-09 22:12:24 UTC
Permalink
Well, I can resolve this by changing the horde > authentication from
my custom sql queries to Horde Default > Imp.
$conf['auth']['params']['app'] = 'imp';
$conf['auth']['driver'] = 'application';

However, if I get rid of the custom queries I lose the ability to
manage users inside of horde ("our authentication backend does not
support adding users") as an admin, which I'd like to keep.

Can I use Custom SQL Queries for authentication, AND be prompted for
Dynamic, Minimalist, or Traditional?

Rick
Post by horde
I know I used to have the option to select which GUI to log on as
(Dynamic, Minimalist, Traditional ) but somehow it's gone.
/horde/imp/config/conf.php $conf['user']['select_view'] = true;
MIMP and DIMP both work if I actively select the URL
http://server/horde/mimp or http://server/horde/dimp
What setting am I missing? Thx
Rick
Rick Steeves
http://www.sinister.net
"The journey is the destination"
--
Horde mailing list - Join the hunt: http://horde.org/bounties/#horde
Frequently Asked Questions: http://horde.org/faq/
To unsubscribe, mail: horde-unsubscribe at lists.horde.org
Michael M Slusarz
2008-10-09 22:47:38 UTC
Permalink
Post by horde
Well, I can resolve this by changing the horde > authentication from
my custom sql queries to Horde Default > Imp.
$conf['auth']['params']['app'] = 'imp';
$conf['auth']['driver'] = 'application';
However, if I get rid of the custom queries I lose the ability to
manage users inside of horde ("our authentication backend does not
support adding users") as an admin, which I'd like to keep.
Can I use Custom SQL Queries for authentication, AND be prompted for
Dynamic, Minimalist, or Traditional?
No. You either have to:
1. Continue using custom queries but disable hordeauth (so you have to
login again for IMP).
2. Use IMP authentication.
3. Hack the horde login screen.

michael
--
___________________________________
Michael Slusarz [slusarz at horde.org]
Jan Schneider
2008-10-09 23:50:55 UTC
Permalink
Post by Michael M Slusarz
Post by horde
Well, I can resolve this by changing the horde > authentication
from my custom sql queries to Horde Default > Imp.
$conf['auth']['params']['app'] = 'imp';
$conf['auth']['driver'] = 'application';
However, if I get rid of the custom queries I lose the ability to
manage users inside of horde ("our authentication backend does not
support adding users") as an admin, which I'd like to keep.
Can I use Custom SQL Queries for authentication, AND be prompted
for Dynamic, Minimalist, or Traditional?
1. Continue using custom queries but disable hordeauth (so you have
to login again for IMP).
2. Use IMP authentication.
3. Hack the horde login screen.
2b. Use composite authentication.

Jan.
--
Do you need professional PHP or Horde consulting?
http://horde.org/consulting/
horde
2008-10-10 02:04:17 UTC
Permalink
Well, this idea is brilliant. I do have a few questions. The wiki says
"Next we need to select the correct drivers for the different
purposes of the authentication API. The driver gets selected by the
name we used in the last step. There are currently three possible
switches for selecting a driver: "

but I only see two options after that? Should there be a third, or
are there only two?

I can understand (great instructions!) how to define mysql as one of
the drivers, and application for the other. I can see how to set the
login driver to be one or the other, and pick which one actually
determines who the horde admins are (although I don't quite
understand, because horde admins I thought were defined by
$conf['auth']['admins']. (Copy of my config below my name.)

I see the login driver needs to be the application driver to trigger
the choices for Dyn, Min, and Trad, yes?. How does everything else
know what to pick?

Questions aside, all of that appears to work swimmingly even if I
have no idea how. I can log in, get the options, and yet still pick
the Users tab and modify users. cool.

I do still have one thing I'm stuck on. I finally got the sql right
to update the mailbox table (from postfixadmin) for the domains (at
least if your user IDs are user at example.com). But I need to update
TWO tables when working with postfixadmin in the background (as I
also have to update the "alias" table). I tried just appending the
second query to the primary query (as query1; query2;) , but the sql
function in horde submits it as all one big SQL query.

Possible, or have I finally stretched things too far?

Rick

//composite of mysql and application driver
$conf['auth']['driver'] = 'composite';
//composite mysql driver
$conf['auth']['params']['drivers']['customsql_mod']['driver'] = 'customsql';
$conf['auth']['params']['drivers']['customsql_mod']['params'] = array(
'phptype' => 'mysqli',
'protocol' => 'unix',
'hostspec' => 'localhost',
'username' => 'postfix',
'password' => 'pfix1723',
'database' => 'postfix',
'query_auth' => 'SELECT * FROM mailbox WHERE username = \L and password=\P; ',
'query_add' => 'INSERT INTO mailbox
(username,password,maildir,quota,domain,created,modified) VALUES (\L,
\P, CONCAT(RIGHT(\L, (LENGTH(\L)-(INSTR(\L, \'@\')))), \'/\',
LEFT(\L, INSTR(\L,\'@\')-1) , \'/\') ,\'512000000\', RIGHT(\L,
(LENGTH(\L)-(INSTR(\L, \'@\')))), now(), now());',
'query_getpw' => 'SELECT password FROM mailbox WHERE username = \L;',
'query_update' => 'UPDATE mailbox SET username = \L WHERE username =
\O) LIMIT 1;',
'query_resetpassword' => 'UPDATE mailbox SET password = \P WHERE
username = \L;',
'query_remove' => 'DELETE FROM mailbox WHERE username = \L;',
'query_list' => 'SELECT * FROM mailbox;',
'query_exists' => 'SELECT 1 FROM mailbox WHERE username = \L;',
'encryption' => 'crypt-md5',
'show_encryption' => false);
//composite application driver
$conf['auth']['params']['drivers']['application_mod']['driver'] =
'application';
$conf['auth']['params']['drivers']['application_mod']['params'] = array(
'app' => 'imp');
//selecting the login driver
$conf['auth']['params']['admin_driver'] = 'customsql_mod';
$conf['auth']['params']['loginscreen_switch'] = '_horde_select_loginscreen';
if (!function_exists('_horde_select_loginscreen')) {
function _horde_select_loginscreen()
{
return 'application_mod';
}
}
Post by Jan Schneider
2b. Use composite authentication.
Jan Schneider
2008-10-10 09:18:23 UTC
Permalink
Post by horde
Well, this idea is brilliant. I do have a few questions. The wiki says
"Next we need to select the correct drivers for the different
purposes of the authentication API. The driver gets selected by the
name we used in the last step. There are currently three possible
switches for selecting a driver: "
but I only see two options after that? Should there be a third, or
are there only two?
I have no idea why I wrote "three" there. There are only two, and even
only one is documented in the howto at all. We should add some
information about the user name switch too.
Post by horde
I can understand (great instructions!) how to define mysql as one of
the drivers, and application for the other. I can see how to set the
login driver to be one or the other, and pick which one actually
determines who the horde admins are (although I don't quite
understand, because horde admins I thought were defined by
$conf['auth']['admins']. (Copy of my config below my name.)
That looked like a typo. It's about "administration", not "administrators".
Post by horde
I see the login driver needs to be the application driver to trigger
the choices for Dyn, Min, and Trad, yes?. How does everything else
know what to pick?
Questions aside, all of that appears to work swimmingly even if I
have no idea how. I can log in, get the options, and yet still pick
the Users tab and modify users. cool.
I do still have one thing I'm stuck on. I finally got the sql right
to update the mailbox table (from postfixadmin) for the domains (at
least if your user IDs are user at example.com). But I need to update
TWO tables when working with postfixadmin in the background (as I
also have to update the "alias" table). I tried just appending the
second query to the primary query (as query1; query2;) , but the sql
function in horde submits it as all one big SQL query.
Possible, or have I finally stretched things too far?
No, Horde can stretch even more. :) You can achieve that by creating a
_horde_hook_signup_addextra hook. If you've gone through that, it
would great if you could add instructions to the howto.
Post by horde
//composite of mysql and application driver
$conf['auth']['driver'] = 'composite';
//composite mysql driver
$conf['auth']['params']['drivers']['customsql_mod']['driver'] = 'customsql';
$conf['auth']['params']['drivers']['customsql_mod']['params'] = array(
'phptype' => 'mysqli',
'protocol' => 'unix',
'hostspec' => 'localhost',
'username' => 'postfix',
'password' => 'pfix1723',
'database' => 'postfix',
'query_auth' => 'SELECT * FROM mailbox WHERE username = \L and
password=\P; ',
'query_add' => 'INSERT INTO mailbox
(username,password,maildir,quota,domain,created,modified) VALUES
'query_getpw' => 'SELECT password FROM mailbox WHERE username = \L;',
'query_update' => 'UPDATE mailbox SET username = \L WHERE username =
\O) LIMIT 1;',
'query_resetpassword' => 'UPDATE mailbox SET password = \P WHERE
username = \L;',
'query_remove' => 'DELETE FROM mailbox WHERE username = \L;',
'query_list' => 'SELECT * FROM mailbox;',
'query_exists' => 'SELECT 1 FROM mailbox WHERE username = \L;',
'encryption' => 'crypt-md5',
'show_encryption' => false);
//composite application driver
$conf['auth']['params']['drivers']['application_mod']['driver'] =
'application';
$conf['auth']['params']['drivers']['application_mod']['params'] = array(
'app' => 'imp');
//selecting the login driver
$conf['auth']['params']['admin_driver'] = 'customsql_mod';
$conf['auth']['params']['loginscreen_switch'] = '_horde_select_loginscreen';
if (!function_exists('_horde_select_loginscreen')) {
function _horde_select_loginscreen()
{
return 'application_mod';
}
}
Post by Jan Schneider
2b. Use composite authentication.
Jan.
--
Do you need professional PHP or Horde consulting?
http://horde.org/consulting/
horde
2008-10-10 14:46:41 UTC
Permalink
Post by Jan Schneider
Post by horde
I see the login driver needs to be the application driver to trigger
the choices for Dyn, Min, and Trad, yes?. How does everything else
know what to pick?
Still a question
Post by Jan Schneider
No, Horde can stretch even more. :) You can achieve that by creating a
_horde_hook_signup_addextra hook. If you've gone through that, it
would great if you could add instructions to the howto.
A better point here is whether _I_ can stretch more. *sigh*. Catch-22
I think, but we'll give 'er a go.

Ok, so in config/conf.php I add as part of my composite query next to
'query_add':
'query_add2' => 'INSERT INTO alias
(address,goto,domain,created,modified) VALUES (\L, \L, RIGHT(\L,
(LENGTH(\L)-(INSTR(\L, \'@\')))), now(), now());';

in config/hooks.php I add:
if (!function_exists('_horde_hook_signup_addextra')) {
function _horde_hook_signup_addextra($userID)
{
global $conf;

require_once 'DB.php';
$_db = &DB::connect($conf['mysqli'], true);
$query = $this->_params['query_add2'];
$query = str_replace('\L',$this->_db->quote($userID, $query);
$result = $_db->query($query);

return is_a($result, 'PEAR_Error') ? $result : true;
}
}

(which I at least thing will work based on the code from
horde/lib/Horde/Auth/customsql.php)

However, config/hooks.php says: "Having a hook function in this file
does NOT mean that the hook will automatically be used. YOU MUST
enable the hook."

From the documentation in hooks.php, that looks like I need
horde_hook_somethig or other,
or do I set
$conf[hooks][auth2] = true

or something in between?

I feel like it's close, but not working!

Rick
Post by Jan Schneider
Post by horde
//composite of mysql and application driver
$conf['auth']['driver'] = 'composite';
//composite mysql driver
$conf['auth']['params']['drivers']['customsql_mod']['driver'] = 'customsql';
$conf['auth']['params']['drivers']['customsql_mod']['params'] = array(
'phptype' => 'mysqli',
'protocol' => 'unix',
'hostspec' => 'localhost',
'username' => 'postfix',
'password' => 'pfix1723',
'database' => 'postfix',
'query_auth' => 'SELECT * FROM mailbox WHERE username = \L and
password=\P; ',
'query_add' => 'INSERT INTO mailbox
(username,password,maildir,quota,domain,created,modified) VALUES
'query_getpw' => 'SELECT password FROM mailbox WHERE username = \L;',
'query_update' => 'UPDATE mailbox SET username = \L WHERE username =
\O) LIMIT 1;',
'query_resetpassword' => 'UPDATE mailbox SET password = \P WHERE
username = \L;',
'query_remove' => 'DELETE FROM mailbox WHERE username = \L;',
'query_list' => 'SELECT * FROM mailbox;',
'query_exists' => 'SELECT 1 FROM mailbox WHERE username = \L;',
'encryption' => 'crypt-md5',
'show_encryption' => false);
//composite application driver
$conf['auth']['params']['drivers']['application_mod']['driver'] =
'application';
$conf['auth']['params']['drivers']['application_mod']['params'] = array(
'app' => 'imp');
//selecting the login driver
$conf['auth']['params']['admin_driver'] = 'customsql_mod';
$conf['auth']['params']['loginscreen_switch'] = '_horde_select_loginscreen';
if (!function_exists('_horde_select_loginscreen')) {
function _horde_select_loginscreen()
{
return 'application_mod';
}
}
Post by Jan Schneider
2b. Use composite authentication.
Jan.
Jan Schneider
2008-10-10 15:17:03 UTC
Permalink
Post by horde
Post by Jan Schneider
Post by horde
I see the login driver needs to be the application driver to trigger
the choices for Dyn, Min, and Trad, yes?. How does everything else
know what to pick?
Still a question
Post by Jan Schneider
No, Horde can stretch even more. :) You can achieve that by creating a
_horde_hook_signup_addextra hook. If you've gone through that, it
would great if you could add instructions to the howto.
A better point here is whether _I_ can stretch more. *sigh*.
Catch-22 I think, but we'll give 'er a go.
Ok, so in config/conf.php I add as part of my composite query next
'query_add2' => 'INSERT INTO alias
(address,goto,domain,created,modified) VALUES (\L, \L, RIGHT(\L,
if (!function_exists('_horde_hook_signup_addextra')) {
function _horde_hook_signup_addextra($userID)
{
global $conf;
require_once 'DB.php';
$_db = &DB::connect($conf['mysqli'], true);
$query = $this->_params['query_add2'];
$query = str_replace('\L',$this->_db->quote($userID, $query);
$result = $_db->query($query);
return is_a($result, 'PEAR_Error') ? $result : true;
}
}
(which I at least thing will work based on the code from
horde/lib/Horde/Auth/customsql.php)
However, config/hooks.php says: "Having a hook function in this file
does NOT mean that the hook will automatically be used. YOU MUST
enable the hook."
From the documentation in hooks.php, that looks like I need
horde_hook_somethig or other,
or do I set
$conf[hooks][auth2] = true
or something in between?
Looking at the code it seems that you also have to specify the
_horde_hook_signup_getextra, so that the signup_addextra is actually
triggered.
Post by horde
I feel like it's close, but not working!
Rick
Post by Jan Schneider
Post by horde
//composite of mysql and application driver
$conf['auth']['driver'] = 'composite';
//composite mysql driver
$conf['auth']['params']['drivers']['customsql_mod']['driver'] = 'customsql';
$conf['auth']['params']['drivers']['customsql_mod']['params'] = array(
'phptype' => 'mysqli',
'protocol' => 'unix',
'hostspec' => 'localhost',
'username' => 'postfix',
'password' => 'pfix1723',
'database' => 'postfix',
'query_auth' => 'SELECT * FROM mailbox WHERE username = \L and password=\P; ',
'query_add' => 'INSERT INTO mailbox
(username,password,maildir,quota,domain,created,modified) VALUES
'query_getpw' => 'SELECT password FROM mailbox WHERE username = \L;',
'query_update' => 'UPDATE mailbox SET username = \L WHERE username =
\O) LIMIT 1;',
'query_resetpassword' => 'UPDATE mailbox SET password = \P WHERE
username = \L;',
'query_remove' => 'DELETE FROM mailbox WHERE username = \L;',
'query_list' => 'SELECT * FROM mailbox;',
'query_exists' => 'SELECT 1 FROM mailbox WHERE username = \L;',
'encryption' => 'crypt-md5',
'show_encryption' => false);
//composite application driver
$conf['auth']['params']['drivers']['application_mod']['driver'] =
'application';
$conf['auth']['params']['drivers']['application_mod']['params'] = array(
'app' => 'imp');
//selecting the login driver
$conf['auth']['params']['admin_driver'] = 'customsql_mod';
$conf['auth']['params']['loginscreen_switch'] =
'_horde_select_loginscreen';
if (!function_exists('_horde_select_loginscreen')) {
function _horde_select_loginscreen()
{
return 'application_mod';
}
}
Post by Jan Schneider
2b. Use composite authentication.
Jan.
Jan.
--
Do you need professional PHP or Horde consulting?
http://horde.org/consulting/
horde
2008-10-10 17:50:38 UTC
Permalink
Post by Jan Schneider
Post by horde
Post by horde
I see the login driver needs to be the application driver to trigger
the choices for Dyn, Min, and Trad, yes?. How does everything else
know what to pick?
?
Post by Jan Schneider
Looking at the code it seems that you also have to specify the
_horde_hook_signup_getextra, so that the signup_addextra is actually
triggered.
It looks like the hook _horde_hook_signup_addextra runs when you
attempt to add a new user in /lib/Horde/Auth/signup.php, if you have
$info['extra'] defined, so I don't think I need
_horde_hook_signup_getextra necessarily
(and if I had that value to tinker with, I could use it as my SQL
query.) But I have no idea how to get $info['extra'] there.

and thus I give up. I'm about 3 layers deep into this problem, and no
idea how many more before I get it working.

I think I can work around this functionality in Horde; I'll just
manage it from the outside. Thanks for all your help.

Rick
Post by Jan Schneider
Post by horde
I feel like it's close, but not working!
Rick
Post by horde
//composite of mysql and application driver
$conf['auth']['driver'] = 'composite';
//composite mysql driver
$conf['auth']['params']['drivers']['customsql_mod']['driver'] = 'customsql';
$conf['auth']['params']['drivers']['customsql_mod']['params'] = array(
'phptype' => 'mysqli',
'protocol' => 'unix',
'hostspec' => 'localhost',
'username' => 'postfix',
'password' => 'pfix1723',
'database' => 'postfix',
'query_auth' => 'SELECT * FROM mailbox WHERE username = \L and password=\P; ',
'query_add' => 'INSERT INTO mailbox
(username,password,maildir,quota,domain,created,modified) VALUES
'query_getpw' => 'SELECT password FROM mailbox WHERE username = \L;',
'query_update' => 'UPDATE mailbox SET username = \L WHERE username =
\O) LIMIT 1;',
'query_resetpassword' => 'UPDATE mailbox SET password = \P WHERE
username = \L;',
'query_remove' => 'DELETE FROM mailbox WHERE username = \L;',
'query_list' => 'SELECT * FROM mailbox;',
'query_exists' => 'SELECT 1 FROM mailbox WHERE username = \L;',
'encryption' => 'crypt-md5',
'show_encryption' => false);
//composite application driver
$conf['auth']['params']['drivers']['application_mod']['driver'] =
'application';
$conf['auth']['params']['drivers']['application_mod']['params'] = array(
'app' => 'imp');
//selecting the login driver
$conf['auth']['params']['admin_driver'] = 'customsql_mod';
$conf['auth']['params']['loginscreen_switch'] =
'_horde_select_loginscreen';
if (!function_exists('_horde_select_loginscreen')) {
function _horde_select_loginscreen()
{
return 'application_mod';
}
}
Post by Jan Schneider
2b. Use composite authentication.
Jan.
Jan.
--
Do you need professional PHP or Horde consulting?
http://horde.org/consulting/
horde
2008-10-10 15:20:32 UTC
Permalink
Missed a ')', should be
$query = str_replace('\L',$this->_db->quote($userID), $query);

Still missing how to get it to actually enable. I have figured out
that it shouldn't be in
Post by horde
if (!function_exists('_horde_hook_signup_addextra')) {
because I'm trying to get it to work in the users function not the
signup function.
Post by horde
Post by Jan Schneider
Post by horde
I see the login driver needs to be the application driver to trigger
the choices for Dyn, Min, and Trad, yes?. How does everything else
know what to pick?
Still a question
Post by Jan Schneider
No, Horde can stretch even more. :) You can achieve that by creating a
_horde_hook_signup_addextra hook. If you've gone through that, it
would great if you could add instructions to the howto.
A better point here is whether _I_ can stretch more. *sigh*.
Catch-22 I think, but we'll give 'er a go.
Ok, so in config/conf.php I add as part of my composite query next
'query_add2' => 'INSERT INTO alias
(address,goto,domain,created,modified) VALUES (\L, \L, RIGHT(\L,
if (!function_exists('_horde_hook_signup_addextra')) {
function _horde_hook_signup_addextra($userID)
{
global $conf;
require_once 'DB.php';
$_db = &DB::connect($conf['mysqli'], true);
$query = $this->_params['query_add2'];
$query = str_replace('\L',$this->_db->quote($userID, $query);
$result = $_db->query($query);
return is_a($result, 'PEAR_Error') ? $result : true;
}
}
(which I at least thing will work based on the code from
horde/lib/Horde/Auth/customsql.php)
However, config/hooks.php says: "Having a hook function in this file
does NOT mean that the hook will automatically be used. YOU MUST
enable the hook."
From the documentation in hooks.php, that looks like I need
horde_hook_somethig or other,
or do I set
$conf[hooks][auth2] = true
or something in between?
I feel like it's close, but not working!
Rick
Post by Jan Schneider
Post by horde
//composite of mysql and application driver
$conf['auth']['driver'] = 'composite';
//composite mysql driver
$conf['auth']['params']['drivers']['customsql_mod']['driver'] = 'customsql';
$conf['auth']['params']['drivers']['customsql_mod']['params'] = array(
'phptype' => 'mysqli',
'protocol' => 'unix',
'hostspec' => 'localhost',
'username' => 'postfix',
'password' => 'pfix1723',
'database' => 'postfix',
'query_auth' => 'SELECT * FROM mailbox WHERE username = \L and
password=\P; ',
'query_add' => 'INSERT INTO mailbox
(username,password,maildir,quota,domain,created,modified) VALUES
'query_getpw' => 'SELECT password FROM mailbox WHERE username = \L;',
'query_update' => 'UPDATE mailbox SET username = \L WHERE username =
\O) LIMIT 1;',
'query_resetpassword' => 'UPDATE mailbox SET password = \P WHERE
username = \L;',
'query_remove' => 'DELETE FROM mailbox WHERE username = \L;',
'query_list' => 'SELECT * FROM mailbox;',
'query_exists' => 'SELECT 1 FROM mailbox WHERE username = \L;',
'encryption' => 'crypt-md5',
'show_encryption' => false);
//composite application driver
$conf['auth']['params']['drivers']['application_mod']['driver'] =
'application';
$conf['auth']['params']['drivers']['application_mod']['params'] = array(
'app' => 'imp');
//selecting the login driver
$conf['auth']['params']['admin_driver'] = 'customsql_mod';
$conf['auth']['params']['loginscreen_switch'] = '_horde_select_loginscreen';
if (!function_exists('_horde_select_loginscreen')) {
function _horde_select_loginscreen()
{
return 'application_mod';
}
}
Post by Jan Schneider
2b. Use composite authentication.
Jan.
Loading...