Zimbra offers Open Source email server software and shared calendar for Linux and the Mac
Go Back   Zimbra :: Forums > Zimbra Collaboration Suite > Mobility

Welcome to the Zimbra :: Forums!
Welcome, if you would like to post a comment please register. We also encourage you to explore all things Zimbra with our team and members of the community.

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 10-22-2011, 04:45 PM
Special Member
 
Posts: 138
Default [SOLVED] iPhone + CardDAV to access GAL on ZCS 7.1.3 OSE

I have searched but cannot find what I'm looking for.

I have Zimbra 7.1.3 OSE running and can setup an iPhone to access personal email via IMAP, personal and shared calendars via CalDAV and personal contacts through CardDAV.

What I don't know is how to setup CardDAV to access the global address list so when iPhone users create a new email, the "TO" button will populate with everyone on the Zimbra server (via the GAL).

Do I need to login with the admin account and grant access to the GAL to an in-between user and then have everyone add the CardDAV for that in-between user?

For those curious, the following is how I setup an iPhone

to access personal emails:
  1. Click the Settings icon
  2. Select Mail, Contacts, Calendars, Add Account..., Other, Add Mail Account
  3. Set the following and click Next:
    Name: John Doe
    Address: JDoe@mydomain.com
    Password: ******
    Description: JDoe @ mydomain
  4. Select IMAP, set the following and click Next, Finish
    Incoming Hostname: mail.mydomain.com
    Incoming User Name: JDoe
    Incoming Password: *****
    Outgoing Hostname: mail.mydomain.com
    Outgoing User Name: JDoe
    Outgoing Password: *****

to access personal calendars:
  1. Click the Settings icon
  2. Select Mail, Contacts, Calendars, Add Account..., Other, Add CalDAV Account
  3. Set the following and click Next:
    Server: mail.mydomain.com
    User Name: JDoe
    Password: ******
    Description: CalDAV @ mydomain

to access personal contacts:
  1. Click the Settings icon
  2. Select Mail, Contacts, Calendars, Add Account..., Other, Add CardDAV Account
  3. Set the following and click Next:
    Server: mail.mydomain.com
    User Name: JDoe
    Password: ******
    Description: CardDAV @ mydomain

Any help would be appreciated.
Thanks,
LHammonds

Last edited by LHammonds; 10-28-2011 at 03:15 PM..
Reply With Quote
  #2 (permalink)  
Old 10-26-2011, 12:49 PM
Moderator
 
Posts: 1,432
Default

You could possibly access the GAL through LDAP, but only if you have success setting up access using secure LDAP. Not a good idea to expose your directory to snoops.

What you could try is to share your galsync account's _internalGAL to a user account read-only using ZWC, and then mount it in that account, again using ZWC. Note: I haven't tested this myself extensively, let alone with iPhone. But I believe that iOS, unlike Mac OS 10.7, can display multiple CardDAV address books.
__________________
Elliot Wilen
Berkeley, CA

Don't forget to enter your Zimbra version in your forum profile.
Reply With Quote
  #3 (permalink)  
Old 10-26-2011, 02:48 PM
Special Member
 
Posts: 138
Default

Quote:
Originally Posted by ewilen View Post
What you could try is to share your galsync account's _internalGAL to a user account read-only using ZWC, and then mount it in that account, again using ZWC. Note: I haven't tested this myself extensively, let alone with iPhone.
Thanks for the suggestion. I will give it a whirl after I rebuild the server (currently testing space increase procedures and determining best partition setup scheme).

Quote:
Originally Posted by ewilen View Post
But I believe that iOS, unlike Mac OS 10.7, can display multiple CardDAV address books.
I can confirm that the iPhone has no problem with multiple CardDAV and CalDAV accounts as they are integrated seamlessly. I tested that by setting up two accounts and then added both via IMAP, CardDAV and CalDAV. I was able to get a nicely blended listing of emails in both accounts (or one at a time if I chose), a nicely blended listing of contacts and calendars (including shared calendars in the account).

Thanks,
LHammonds
Reply With Quote
  #4 (permalink)  
Old 10-26-2011, 03:35 PM
Moderator
 
Posts: 1,432
Default

Ah, here we're not talking about multiple accounts, but multiple address books within a single account, equivalent to multiple calendars in a single account.

If you share either one from one account to another, and then mount it in the second account, then the mounted item should be exposed via CalDAV/CardDAV.

(In fact if you share a mail folder and mount it, it'll be exposed via IMAP.)
__________________
Elliot Wilen
Berkeley, CA

Don't forget to enter your Zimbra version in your forum profile.
Reply With Quote
  #5 (permalink)  
Old 10-27-2011, 07:06 AM
Trained Alumni
 
Posts: 32
Default

Use the Exchange connection on the iPhone to access the GAL... you can turn off the mail and calendars so it only has the contacts (GAL)...

CardDav will only give you the contacts in your address book not a shared one.

To Setup the Exchange connection on the iPhone

Settings > Mail, Contacts ,Calendars > Add Account > Microsoft Exchange

Email: myemail@address
Domain: MyDomain.com
Username: myusername@MyDomain.com <---- This bit is needed you cannot use just uername
Password: mypassword

Description: GAL

Click Next

Mail Server: MyFQDNofMyMailServer.com

Now Click Save..

Turn off Mail <--- no point as it will not support shared folders
Turn off Cal <---- ditto

Make sure you take advantage of the mobile sync options in Zimbra for remote wipe and force pin...

Hope this helps

Last edited by Guest; 10-27-2011 at 09:35 AM.. Reason: Extra info
Reply With Quote
  #6 (permalink)  
Old 10-27-2011, 08:59 AM
Special Member
 
Posts: 138
Default

I have the administrator's "_InternalGAL" folder listed in the "Shared by me" under the Sharing section of the Preference tab in ZWC.

I forgot the process in which I shared it but it is there.

I created a new mailbox account. I login with the new account in the ZWC, click Preferences, Sharing and type "administrator" in the "Show folders shared with me by the following user:" box. I then click "Accept" when I see the _InternalGAL folder.

I now click on the Address Book tab which shows the following folders:

Contacts
Emailed Contacts
Trash
administrator's _InternalGAL

If I click on the _InternalGAL folder, I can see a list of all users defined in the system.

I now add this account to my iPhone as described in the 1st post by adding IMAP, CalDAV and CardDAV.

When I look at contacts, I only see "Contacts" and "Emailed Contacts" and cannot see the global address list.

If I add the CardDAV of the administrator account, I see the following entries:

_ActiveDirectoryGAL
_InternalGAL
Contacts
Emailed Contacts

When looking at all those contacts, I can see all internal users and even the Windows Active Directory users.

I need to do some more research...I know I saw some documentation somewhere talking about mounting shares via the command-line which may help me with this a bit more.

As I find resources related to this, I'm going to add them to this list:
EDIT:
Quote:
Originally Posted by Guest View Post
Use the Exchange connection on the iPhone to access the GAL... you can turn off the mail and calendars so it only has the contacts (GAL)...
I'll investigate this option. Thanks.

EDIT: I get "unable to verify account information" which is probably par for the course when using the OSE version.

Quote:
Originally Posted by Guest View Post
CardDav will only give you the contacts in your address book not a shared one.
Upon initial testing, that seems to be the case...unless the _InternalGAL is a special scenario.

I just tested the CalDAV sharing where I included a couple of conference rooms shared calendars and those show up and are visible on the iPhone immediately.

I'll test the ordinary contacts sharing the same way to see if the _InternalGAL is just handled differently.

EDIT: The normal sharing of a contact folder did not work...at least not the same way sharing of calendars work.

-------------------------------------------------------
-------------------------------------------------------
-------------------------------------------------------

If sharing does not work for CardDAV (e.g. iPhone cannot access it like it can with shared calendars in CalDAV), my next option might be to create a generic account called "AddressList" and then create a script that will export all users and distribution lists in the _InternalGAL and import them into the Contacts folder of the "AddressList" user. Then have instructions for all my iPhone users to add an additional CardDAV account called "AddressList" which should pull the contacts and distribution lists in that user's list...which is a copy of the GAL.

I think an individual backup / restore script would do the trick. Basically backing up administrators _InternalGAL and restoring to AddressList's "contact" folder. I'll need to research and test this out:

Code:
/opt/zimbra/bin/zmmailbox -z -m administrator@mydomain.com getRestURL "/_InternalGAL?fmt=tgz" > /tmp/internalgal.tgz
/opt/zimbra/bin/zmmailbox -z -m addresslist@mydomain.com postRestURL "/Contacts?fmt=tgz&resolve=reset" /tmp/internalgal.tgz
Ok, the above worked in that I got the contacts into the addresslist account, however, they went into Contacts/_InternalGAL as a sub-folder. Seems that the iPhone doesn't like sub-folders either. So I need to figure out how to dump the contents of the _InternalGAL in the backup archive directly into the root of the Contacts folder.

hhmmm...researching...

EDIT: SUCCESS!

It is not quite as simple as the above backup / restore but I was able to figure out what had to be done in order to make it work. Now when I go to create an email on the iPhone, clicking the + sign shows all of my personal contacts as well as the global address list which is contained in the "AddressList" account...which is a copy of the InternalGAL.

Now all I need to do is to figure out how to script everything and put it on a cron schedule...probably just once per day...or even every hour.

I'm still confused as to why CardDAV refuses to show the contents of a shared folder. It works perfectly for CalDAV (creating events on both sides)

EDIT: Solution incorporated into this thread

LHammonds
__________________
Type su - zimbra -c "zmcontrol -v" to get your version and copy that into your profile (more info here)

Last edited by LHammonds; 11-18-2011 at 10:22 AM..
Reply With Quote
  #7 (permalink)  
Old 10-27-2011, 01:28 PM
Moderator
 
Posts: 1,432
Default

Quote:
Originally Posted by Guest View Post
Use the Exchange connection on the iPhone to access the GAL... you can turn off the mail and calendars so it only has the contacts (GAL)...
This is what I would suggest to NE users, but LHammonds is using FOSS.
__________________
Elliot Wilen
Berkeley, CA

Don't forget to enter your Zimbra version in your forum profile.
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


Similar Threads

Why Join?

Registering let's you ask questions, makes it easier to search, displays any files attached to posts, and notifies you about replies.

blog.zimbra.com




 

SEO by vBSEO ©2011, Crawlability, Inc.