Koozali.org: home of the SME Server

Horde 5.2, activesync

Offline SchulzStefan

  • *
  • 620
  • +0/-0
Re: Horde 5.2, activesync
« Reply #15 on: November 29, 2016, 02:54:47 PM »
typo is no problem...

I'll try the log settings in the evening.

What do you mean with setting up preferences? In the BB-device (also in the nokia) you need to enter

- the account (user),
- password for the user,
- you may enter the domain (usually I leave this empty)
- email of the user (in my case it's an email-adress from a virtual domain)
- server (in my case it's a dyndns),
- port,
- ssl (or not),
- push (or not)
- sync-periods

And what you want to sync. Means email, calendar, contacts...

That's all. Works fine with sogo. On both mobiles.

And then one day you find ten years have got behind you.

Time, 1973
(Mason, Waters, Wright, Gilmour)

Offline mrjhb3

  • *
  • 1,188
  • +0/-0
    • John Bennett Services
Re: Horde 5.2, activesync
« Reply #16 on: November 30, 2016, 12:56:48 AM »
Preferences set up in webmail.  Login, click the gear icon, and set your preferences for each of the modules.
......

Offline SchulzStefan

  • *
  • 620
  • +0/-0
Re: Horde 5.2, activesync
« Reply #17 on: November 30, 2016, 10:56:17 AM »
I enabled logging - no logs in tmp.

Yes, I configured horde... as I understand, most should work out of the box.

I think as long as no device is showing up in the activesync tab (general settings) nothing will be synced. Question is, why does no mobile show up there?

Could there be an interference with sogo? Maybe I should set up a virtualbox for more testings. Right now I only disabled sogo.
And then one day you find ten years have got behind you.

Time, 1973
(Mason, Waters, Wright, Gilmour)

Offline SchulzStefan

  • *
  • 620
  • +0/-0
Re: Horde 5.2, activesync
« Reply #18 on: November 30, 2016, 01:20:22 PM »
I set up a virtual server.

Results:

- email seems to be synced (there's more testing needed because of the issue with virtual domains and the depending email-accounts)
- contacts from server to phone seems to work
- contacts from phone to server don't work
- calendar is not being synced at all
- tasks are not synced - an error occurs while editing tasks on the left panel (there's a pencil shown): Forbidden You don't have permission to access /horde/nag/tasklists/edit.php on this server.
- in horde no devices show up in the activesync tab and nothing shows up in the syncml tab.

Log from the device is created in tmp

In /var/log/messages appears:
Nov 30 12:50:26 mond HORDE: [imp] Login success for test (Horde user test@dyndns.org) (89.204.137.9) to {imap://localhost/} [pid 2985 on line 157 of "/home/httpd/html/horde/imp/lib/Auth.php"]

There's no user test@dyndns.org. There's a user "test" but no domain dyndns.org.

Maybe there's some more testing needed...
And then one day you find ten years have got behind you.

Time, 1973
(Mason, Waters, Wright, Gilmour)

Offline SchulzStefan

  • *
  • 620
  • +0/-0
Re: Horde 5.2, activesync
« Reply #19 on: December 01, 2016, 10:30:00 AM »
John,

Quote
I've also only tested activesync on Andriod and IOS devices.

Do you see your devices in the activesync tab? Or in the syncml?
And then one day you find ten years have got behind you.

Time, 1973
(Mason, Waters, Wright, Gilmour)

Offline mrjhb3

  • *
  • 1,188
  • +0/-0
    • John Bennett Services
Re: Horde 5.2, activesync
« Reply #20 on: December 01, 2016, 02:27:10 PM »
Yes, all of the devices that are being used with ActiveSync show up in preferences, Global preferences, Activesync tab.

Please show the output of this.
cat /home/httpd/html/horde/imp/config/backends.local.php

Also, this thread should be moved to the  SME 9.x Contribs section since horde 5.2 isn't part of the official SME 9 release.



......

Offline SchulzStefan

  • *
  • 620
  • +0/-0
Re: Horde 5.2, activesync
« Reply #21 on: December 01, 2016, 02:39:50 PM »
Quote
Yes, all of the devices that are being used with ActiveSync show up in preferences, Global preferences, Activesync tab

I have a "no show".

Quote
Please show the output of this.
cat /home/httpd/html/horde/imp/config/backends.local.php

#------------------------------------------------------------
#          !!DO NOT MODIFY THIS FILE!!
#
# Manual changes will be lost when this file is regenerated.
#
# Please read the developer's guide, which is available
# at http://www.contribs.org/development/
#
# Copyright (C) 1999-2006 Mitel Networks Corporation
#------------------------------------------------------------
*/

//100Overrides
$servers['imap']['disabled'] = true;

//120IMAPServers
$servers['ivb.local'] = array(
    'disabled' => false,
    'name' => 'IMAP Server',
    'hostspec' => 'localhost',
    'hordeauth' => true,
    'protocol' => 'imap',
    'port' => '143',
    'secure' => 'notls',
    'maildomain' => 'ivb.local',
    'smtphost' => 'localhost',
    'smtpport' => '25',
    'cache' => false,
);
$servers['eyeseetv.de'] = array(
    'disabled' => false,
    'name' => 'IMAP Server',
    'hostspec' => 'localhost',
    'hordeauth' => true,
    'protocol' => 'imap',
    'port' => '143',
    'secure' => 'notls',
    'maildomain' => 'eyeseetv.de',
    'smtphost' => 'localhost',
    'smtpport' => '25',
    'cache' => false,
);
$servers['fax'] = array(
    'disabled' => false,
    'name' => 'IMAP Server',
    'hostspec' => 'localhost',
    'hordeauth' => true,
    'protocol' => 'imap',
    'port' => '143',
    'secure' => 'notls',
    'maildomain' => 'fax',
    'smtphost' => 'localhost',
    'smtpport' => '25',
    'cache' => false,
);
$servers['ivbonline.de'] = array(
    'disabled' => false,
    'name' => 'IMAP Server',
    'hostspec' => 'localhost',
    'hordeauth' => true,
    'protocol' => 'imap',
    'port' => '143',
    'secure' => 'notls',
    'maildomain' => 'ivbonline.de',
    'smtphost' => 'localhost',
    'smtpport' => '25',
    'cache' => false,
);
$servers['objektschilder.de'] = array(
    'disabled' => false,
    'name' => 'IMAP Server',
    'hostspec' => 'localhost',
    'hordeauth' => true,
    'protocol' => 'imap',
    'port' => '143',
    'secure' => 'notls',
    'maildomain' => 'objektschilder.de',
    'smtphost' => 'localhost',
    'smtpport' => '25',
    'cache' => false,
);

?>

Here you are. It's the output from the production server.


And then one day you find ten years have got behind you.

Time, 1973
(Mason, Waters, Wright, Gilmour)

Offline mrjhb3

  • *
  • 1,188
  • +0/-0
    • John Bennett Services
Re: Horde 5.2, activesync
« Reply #22 on: December 02, 2016, 12:57:03 AM »
What URL are you using when trying to access webmail?


You may also need to do this as well, [/size]https://forums.contribs.org/index.php/topic,50969.msg271247.html#msg271247[/color]


I'm also curious of that dyndns.org entry.


John

......

Offline SchulzStefan

  • *
  • 620
  • +0/-0
Re: Horde 5.2, activesync
« Reply #23 on: December 02, 2016, 09:22:40 AM »
Quote
What URL are you using when trying to access webmail?

https://my.server.ip/webmail or https://my.server.ip/horde

Quote
I'm also curious of that dyndns.org entry.

As I said usually I leave the domain empty for EAS. I'll try to connect with a domain and report.

Quote
You may also need to do this as well, [/size]https://forums.contribs.org/index.php/topic,50969.msg271247.html#msg271247[/color]

I'll try this and report.

stefan
And then one day you find ten years have got behind you.

Time, 1973
(Mason, Waters, Wright, Gilmour)

Offline SchulzStefan

  • *
  • 620
  • +0/-0
Re: Horde 5.2, activesync
« Reply #24 on: December 02, 2016, 06:58:46 PM »
Quote
You may also need to do this as well, [/size]https://forums.contribs.org/index.php/topic,50969.msg271247.html#msg271247[/color]

This leads from:

HORDE: [imp] Login success for test (Horde user test@dyndns.org) (78.42.153.224) to {imap://localhost/} [pid 2299 on line 157 of "/home/httpd/html/horde/imp/lib/Auth.php"]

to:

HORDE: [imp] Login success for test (Horde user test@eyeseetv.de) (78.42.153.224) to {imap://localhost/} [pid 2794 on line 157 of "/home/httpd/html/horde/imp/lib/Auth.php"]

Anyway - only emails seems to be synced properly. The rest (calendar, contacts, tasks) is not working without errors. All tested in the virtual machine with the nokia device.

The device does not show up in the activesync tab.
And then one day you find ten years have got behind you.

Time, 1973
(Mason, Waters, Wright, Gilmour)

Offline SchulzStefan

  • *
  • 620
  • +0/-0
Re: Horde 5.2, activesync
« Reply #25 on: December 03, 2016, 05:58:21 PM »
I did a pear ua.

Among some other modules activesync was also updated. Surprise - (nearly) everything seems to work now. Nearly, because for me it's not possible to login remote as admin. Only with FQHN not with an IP. Tested with a Nokia E7-00 in a virtualbox, SME 9.1 up-to-date, no other contribs installed.

- emails work in both directions
- calendar work in both directions
- tasks work in both directions
- contacts work in both directions

I'll give this a try on a production server.  For years I was happy with zarafa. Due to their new policy I moved to sogo 2.x. Sogo 2.x does not handle invitations, therefore I'm still looking for an alternative. If horde 5.2.x turns out to be stable, I vote for Horde in the next SME major release.

Good work John, thank you.
stefan
And then one day you find ten years have got behind you.

Time, 1973
(Mason, Waters, Wright, Gilmour)

Offline mrjhb3

  • *
  • 1,188
  • +0/-0
    • John Bennett Services
Re: Horde 5.2, activesync
« Reply #26 on: December 03, 2016, 10:21:55 PM »
Thank you for the update.  Very interesting.  I have all the updated files installed on my system, so that means what's on my contribs is old, so I'll get that updated so no one else has to go through the initial pain that you did.

As far as logging in with an IP address as admin, you are going to have to use a custom template for that.  There is a DB key to add additional admins, but it appends the main domain.

You will have to look at the logs for when you login remote to know what to put there.  For my example, my test server is at 10.10.10.50.  I went to https://10.10.10.50/webmail, and logged in as admin.  Here is what's in my log.

Dec  3 15:10:46 www HORDE: [horde] Login success for admin@10.50 to horde (10.10.10.125) [pid 2410 on line 164 of "/home/httpd/html/horde/login.php"]
Dec  3 15:10:46 www HORDE: [imp] Login success for admin (Horde user admin@10.50) (10.10.10.125) to {imap://localhost/} [pid 2410 on line 157 of "/home/httpd/html/horde/imp/lib/Auth.php"]

You need to use the second output that shows Horde user.  This is because the hook that is currently being used, doesn't accommodate when using an IP address to log in.  If you have a dynamic address, then this probably isn't a good solution.  Here is what I did.

/etc/e-smith/templates-custom/home/httpd/html/horde/config/conf.php

//500ConfHordePHP custom template
{
       my @HordeAdmins = split /[,:]/, $horde{Admins} || '';
       $OUT .= "\$conf['auth']['admins'] = array(";
       if (($horde{RemoveUsers} || 'disabled') eq 'enabled')
       {
          $OUT .= "'adminremoveuser'" . ", "  ;
       }
       $OUT .= "'admin\@$DomainName', ";
       $OUT .= "'admin\@10.50', ";     
       foreach my $HordeAdmins (sort @HordeAdmins)
       {
       $OUT .= "'$HordeAdmins" . "@" . "$DomainName'" . ", "  ;
       }
     $OUT .= ");";
}

After this, now when I go to the IP address and login as admin, I have the  Administration options.

John
......

Offline SchulzStefan

  • *
  • 620
  • +0/-0
Re: Horde 5.2, activesync
« Reply #27 on: December 04, 2016, 12:10:07 AM »
Moved to a production server.

Here's what I got:

- email works fine
- contacts are working fine (imported as csv)
- calender is not syncing (imported as ics), maybe too much data?

Here's an error:
HORDE: [kronolith] PHP ERROR: Invalid argument supplied for foreach() [pid 5253 on line 1638 of "/home/httpd/html/horde/kronolith/lib/Kronolith.php"]

Further it seems to me if working remote connected with an IP all kind of imported data (contacts and calendar) is lost with the next connect. Doing exactly the same with FQHN (VNC-connection) the data is all there. I've no idea about this. Working remote over an IP with i.e. sogo works fine.

Another error:
HORDE: [kronolith] PHP ERROR: json_encode() [<a href='function.json-encode'>function.json-encode</a>]: Invalid UTF-8 sequence in argument [pid 2590 on line 242 of "/usr/share/pear/Horde/Serialize.php"]

Quote
You may also need to do this as well, [/size]https://forums.contribs.org/index.php/topic,50969.msg271247.html#msg271247[/color]

I think this should be templated - otherwise EAS over dyndns will not work?

I'd like to know why the calendar on the production machine only syncs one date... could that be a memory problem? Hmm... I didn't import calendar-data in the virtual box, I just played around with a few dates.
« Last Edit: December 04, 2016, 12:28:24 AM by SchulzStefan »
And then one day you find ten years have got behind you.

Time, 1973
(Mason, Waters, Wright, Gilmour)

Offline SchulzStefan

  • *
  • 620
  • +0/-0
Re: Horde 5.2, activesync
« Reply #28 on: December 04, 2016, 12:47:43 AM »
I'm not able to access https://FQHN/horde/admin/config/ as admin. Clicking the redirect-button of the browser leads me to the webmail tab of the admin. Doing the same as a user who I added as admin, leads to the webmail tab of the user. Doesn't work either with an access over IP. Strange.
And then one day you find ten years have got behind you.

Time, 1973
(Mason, Waters, Wright, Gilmour)

Offline SchulzStefan

  • *
  • 620
  • +0/-0
Re: Horde 5.2, activesync
« Reply #29 on: December 05, 2016, 10:46:57 AM »
Update and a few comments to tests on a production server

1) activesync:

1. Device:
Id: IMEI3548XXX
Policy Key: 0
Programm: NokiaE700/1.00(0)MailforExchange 3gpp-gba
Modell: NokiaE700
IMEI: IMEI3548XXX
Eindeutiger Name: Nokia/Mail For Exchange
OS: 25.007
EAS Version: 12.1

Working except of calendar in the case, that a calendar has been imported to horde. What usually should be the case if one is migrating from another groupware.

2. Device:
Id: BB2BFD4A09
Policy Key: 0
Programm: RIM-Passport-SQW100-1/10.3.2.2876
Modell: Passport SQW100-1
IMEI: 35185XXX
Eindeutiger Name: BlackBerry Passport
Mobile Operator: o2 - de
OS: BlackBerry 10
OS Language: de_DE
Telefonnummer: +491XXX
EAS Version: 14.1
Gespeicherter Heartbeat (Sekunden): 600

Working properly.

3. Device:
Id: 14439XXX
Policy Key: 0
Programm: Thunderbird ActiveSync Lightning/4.7.5
EAS Version: 14.0
Gespeicherter Heartbeat (Sekunden): Nicht verfügbar

Seems to work for email, calendar and addresses. More tests need to be done.


2) access as admin:

No luck remote accessing over an IP. Quite interesting thing - 12 hours before re-starting all important services (I do this nightly for maintanence reasons on all servers) I had no admin privileges in my menu. Yes, I added myself as admin. Now, in the morning the admin menu appears.

3) working with filters

It seems that dovecot-extras have to be installed/enabled. Without dovecot errors have been generated and scripts did not work.
And then one day you find ten years have got behind you.

Time, 1973
(Mason, Waters, Wright, Gilmour)