Author Topic: Password Plugin + HMAIL  (Read 419 times)

Offline kwriley87

  • Newbie
  • *
  • Posts: 4
Password Plugin + HMAIL
« on: December 12, 2019, 12:54:21 PM »
Good morning-

I am using Roundcube 1.3.9 with Hmail 5.6.6. Both are running on the same server and I am attempting to get the password plugin to work.

I have modified my Hmail config.inc.php and added the line to enable the plugin:
$config['plugins'] = array(password);

I have also modified the config.inc.php file for the password plugin as follows:

$config['password_driver'] = 'hmail';

// hMail Driver options
// -----------------------
// Remote hMailServer configuration
// true:  HMailserver is on a remote box (php.ini: com.allow_dcom = true)
// false: Hmailserver is on same box as PHP
$config['hmailserver_remote_dcom'] = false;
// Windows credentials
$config['hmailserver_server'] = array(
    'Server'   => 'localhost',      // hostname or ip address
    'Username' => 'Administrator',  // windows username
    'Password' => 'mypassword'        // windows user password
);

The username and password configured above matches both the Windows credentials and Hmail administrator credentials.

When I log into webmail and navigate to Settings, I can see the Password plugin, however, when I enter a new password and submit it I am getting an HTTP 500 error.

Any ideas of where I should be looking to correct this?

Thanks!

Offline alec

  • Hero Member
  • *****
  • Posts: 1,178
Re: Password Plugin + HMAIL
« Reply #1 on: December 13, 2019, 02:15:30 AM »
Check Roundcube or http server error log.

Offline kwriley87

  • Newbie
  • *
  • Posts: 4
Re: Password Plugin + HMAIL
« Reply #2 on: December 13, 2019, 11:42:28 PM »
Thank you for your reply.


From the Roundcube error log:
[14-Dec-2019 05:38:00 Europe/Berlin] PHP Fatal error:  Uncaught Error: Class 'COM' not found in C:\xampp\htdocs\webmail\plugins\password\drivers\hmail.php:40
Stack trace:
#0 C:\xampp\htdocs\webmail\plugins\password\password.php(335): rcube_hmail_password->save('oldpass', 'newpass')
#1 C:\xampp\htdocs\webmail\plugins\password\password.php(172): password->_save('oldpass', 'newpass')
#2 C:\xampp\htdocs\webmail\program\lib\Roundcube\rcube_plugin_api.php(493): password->password_save()
#3 C:\xampp\htdocs\webmail\index.php(289): rcube_plugin_api->exec_action('plugin.password...')
#4 {main}
  thrown in C:\xampp\htdocs\webmail\plugins\password\drivers\hmail.php on line 40

Based on the COM error, I changed my php.ini to the following:
com.allow_dcom = true

Then I restarted Apache and the problem persists. Any ideas?

Here is line 40 of hmail.php from the error above:
$obApp = new COM("hMailServer.Application");

Thank you for your help!
« Last Edit: December 13, 2019, 11:58:10 PM by kwriley87 »

Offline kwriley87

  • Newbie
  • *
  • Posts: 4
Re: Password Plugin + HMAIL
« Reply #3 on: December 14, 2019, 12:03:43 AM »
This issue has been resolved by adding the following in my php.ini:

[COM_DOT_NET]
extension=php_com_dotnet.dll

More info here:
https://stackoverflow.com/questions/10678325/class-com-not-found