mirror of
https://github.com/inverse-inc/sogo.git
synced 2026-07-11 11:25:12 +00:00
merge of '1d1c945ea058db7070c9b83c4c2bb60689c52f92'
and '74d6ae3bf39677a7d5083301f1c29c74b97b84dd' Monotone-Parent: 1d1c945ea058db7070c9b83c4c2bb60689c52f92 Monotone-Parent: 74d6ae3bf39677a7d5083301f1c29c74b97b84dd Monotone-Revision: b5081fb240f719d3a1ce2583dff3738a9ceb9d93 Monotone-Author: crobert@inverse.ca Monotone-Date: 2008-09-28T19:49:39 Monotone-Branch: ca.inverse.sogo
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
/* NSArray+Appointments.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2006 Inverse groupe conseil
|
||||
* Copyright (C) 2006 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* NSArray+Appointments.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2006 Inverse groupe conseil
|
||||
* Copyright (C) 2006 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoAppointmentFolders.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoAppointmentFolders.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoAppointmentOccurence.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2008 Inverse groupe conseil
|
||||
* Copyright (C) 2008 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoAppointmentOccurence.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2008 Inverse groupe conseil
|
||||
* Copyright (C) 2008 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoAptMailICalReply.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoAptMailICalReply - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoCalendarComponent.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2006 Inverse groupe conseil
|
||||
* Copyright (C) 2006 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoCalendarComponent.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2006 Inverse groupe conseil
|
||||
* Copyright (C) 2006 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
@@ -355,7 +355,7 @@ _occurenceHasID (iCalRepeatableEntityObject *occurence, NSString *recID)
|
||||
{
|
||||
ASSIGN (*calendar, [iCalCalendar groupWithTag: @"vcalendar"]);
|
||||
[*calendar setVersion: @"2.0"];
|
||||
[*calendar setProdID: @"-//Inverse groupe conseil//SOGo 0.9//EN"];
|
||||
[*calendar setProdID: @"-//Inverse inc.//SOGo 0.9//EN"];
|
||||
componentTag = [[self componentTag] uppercaseString];
|
||||
newComponent = [[*calendar classForTag: componentTag]
|
||||
groupWithTag: componentTag];
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoComponentOccurence.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2008 Inverse groupe conseil
|
||||
* Copyright (C) 2008 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoComponentOccurence.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2008 Inverse groupe conseil
|
||||
* Copyright (C) 2008 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -120,7 +120,7 @@ static unsigned int freebusyRangeEnd = 0;
|
||||
uid = [container ownerInContext: context];
|
||||
|
||||
calendar = [iCalCalendar groupWithTag: @"vcalendar"];
|
||||
[calendar setProdID: @"//Inverse groupe conseil/SOGo 0.9"];
|
||||
[calendar setProdID: @"//Inverse inc./SOGo 0.9"];
|
||||
[calendar setVersion: @"2.0"];
|
||||
if (method)
|
||||
[calendar setMethod: method];
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoTaskOccurence.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2008 Inverse groupe conseil
|
||||
* Copyright (C) 2008 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoTaskOccurence.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2008 Inverse groupe conseil
|
||||
* Copyright (C) 2008 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoUserFolder+Appointments.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2008 Inverse groupe conseil
|
||||
* Copyright (C) 2008 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoUserFolder+Appointments.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2008 Inverse groupe conseil
|
||||
* Copyright (C) 2008 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* iCalEntityObject+SOGo.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* iCalEntityObject+SOGo.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* iCalEvent+SOGo.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* iCalEvent+SOGo.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* iCalEventChanges+SOGo.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* iCalEventChanges+SOGo.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* iCalPerson+SOGo.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* iCalPerson+SOGo.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* iCalRepeatableEntityObject+SOGo.h - this file is part of SOGo
|
||||
Copyright (C) 2004-2005 SKYRIX Software AG
|
||||
Copyright (C) 2008 Inverse groupe conseil
|
||||
Copyright (C) 2008 Inverse inc.
|
||||
|
||||
This file is part of OpenGroupware.org.
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* iCalRepeatableEntityObject+SOGo.m - this file is part of SOGo
|
||||
Copyright (C) 2004-2005 SKYRIX Software AG
|
||||
Copyright (C) 2008 Inverse groupe conseil
|
||||
Copyright (C) 2008 Inverse inc.
|
||||
|
||||
This file is part of OpenGroupware.org.
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* iCalToDo+SOGo.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* iCalEvent+SOGo.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2008 Inverse groupe conseil
|
||||
* Copyright (C) 2008 Inverse inc.
|
||||
* Copyright (C) 2004-2005 SKYRIX Software AG
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoContactFolders.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2006, 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2006, 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoContactFolders.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2006, 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2006, 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoContactGCSEntry.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2006 Inverse groupe conseil
|
||||
* Copyright (C) 2006 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoContactGCSList.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2008 Inverse groupe conseil
|
||||
* Copyright (C) 2008 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoContactGCSList.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2008 Inverse groupe conseil
|
||||
* Copyright (C) 2008 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoContactLDAPFolder.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2006 Inverse groupe conseil
|
||||
* Copyright (C) 2006 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoContactLDAPFolder.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2006 Inverse groupe conseil
|
||||
* Copyright (C) 2006 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/* SOGoContactLDIFEntry.h - this file is part of SOGo
|
||||
* Copyright (C) 2006 Inverse groupe conseil
|
||||
* Copyright (C) 2006 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoContactLDIFEntry.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2006 Inverse groupe conseil
|
||||
* Copyright (C) 2006 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* NSObject+CardDAV.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Ludovic Marcotte <ludovic@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* NSObject+CardDAV.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Ludovic Marcotte <ludovic@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* NSData+Mail.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* NSString+Mail.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -181,7 +181,7 @@ static BOOL showTextAttachmentsInline = NO;
|
||||
{
|
||||
id headerValue;
|
||||
unsigned int count;
|
||||
NSString *messageID;
|
||||
NSString *messageID, *priority;
|
||||
|
||||
for (count = 0; count < 8; count++)
|
||||
{
|
||||
@@ -199,6 +199,29 @@ static BOOL showTextAttachmentsInline = NO;
|
||||
messageID = [self _generateMessageID];
|
||||
[headers setObject: messageID forKey: @"message-id"];
|
||||
}
|
||||
|
||||
priority = [newHeaders objectForKey: @"priority"];
|
||||
|
||||
if (!priority || [priority isEqualToString: @"NORMAL"])
|
||||
{
|
||||
[headers removeObjectForKey: @"X-Priority"];
|
||||
}
|
||||
else if ([priority isEqualToString: @"HIGHEST"])
|
||||
{
|
||||
[headers setObject: @"1 (Highest)" forKey: @"X-Priority"];
|
||||
}
|
||||
else if ([priority isEqualToString: @"HIGH"])
|
||||
{
|
||||
[headers setObject: @"2 (High)" forKey: @"X-Priority"];
|
||||
}
|
||||
else if ([priority isEqualToString: @"LOW"])
|
||||
{
|
||||
[headers setObject: @"4 (Low)" forKey: @"X-Priority"];
|
||||
}
|
||||
else
|
||||
{
|
||||
[headers setObject: @"5 (Lowest)" forKey: @"X-Priority"];
|
||||
}
|
||||
}
|
||||
|
||||
- (NSDictionary *) headers
|
||||
@@ -1235,8 +1258,10 @@ static BOOL showTextAttachmentsInline = NO;
|
||||
[map addObject: userAgent forKey: @"User-Agent"];
|
||||
|
||||
/* add custom headers */
|
||||
|
||||
// [self _addHeaders: [lInfo objectForKey: @"headers"] toHeaderMap:map];
|
||||
if ([(s = [headers objectForKey: @"X-Priority"]) length] > 0)
|
||||
[map setObject: s
|
||||
forKey: @"X-Priority"];
|
||||
|
||||
[self _addHeaders: _headers toHeaderMap: map];
|
||||
|
||||
return map;
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoDraftsFolder.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoDraftsFolder.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoHTMLMailBodyPart.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2008 Inverse groupe conseil
|
||||
* Copyright (C) 2008 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoMailForward.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoMailForward.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoMailObject+Draft.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoMailObject+Draft.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007-2008 Inverse groupe conseil
|
||||
* Copyright (C) 2007-2008 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoMailReply.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoMailReply.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* LDAPSource.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* LDAPUserManager.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* NSArray+DAV.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2008 Inverse groupe conseil
|
||||
* Copyright (C) 2008 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* NSArray+DAV.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2008 Inverse groupe conseil
|
||||
* Copyright (C) 2008 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* NSArray+Utilities.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2006 Inverse groupe conseil
|
||||
* Copyright (C) 2006 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* NSArray+Utilities.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2006 Inverse groupe conseil
|
||||
* Copyright (C) 2006 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* NSDictionary+DAV.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2008 Inverse groupe conseil
|
||||
* Copyright (C) 2008 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* NSDictionary+DAV.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2008 Inverse groupe conseil
|
||||
* Copyright (C) 2008 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* NSDictionary+URL.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2006 Inverse groupe conseil
|
||||
* Copyright (C) 2006 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* NSDictionary+URL.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2006 Inverse groupe conseil
|
||||
* Copyright (C) 2006 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* NSDictionary+Utilities.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* NSDictionary+Utilities.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* NSNull+Utilities.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* NSNull+Utilities.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse group conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* NSNumber+Utilities.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* NSNumber+Utilities.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse group conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* NSObject+DAV.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2008 Inverse groupe conseil
|
||||
* Copyright (C) 2008 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* NSObject+DAV.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2008 Inverse groupe conseil
|
||||
* Copyright (C) 2008 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* NSObject+Utilities.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* NSObject+Utilities.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* NSString+DAV.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2008 Inverse groupe conseil
|
||||
* Copyright (C) 2008 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* NSString+DAV.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2008 Inverse groupe conseil
|
||||
* Copyright (C) 2008 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* NSString+Utilities.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2006 Inverse groupe conseil
|
||||
* Copyright (C) 2006 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* NSURL+DAV.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2008 Inverse groupe conseil
|
||||
* Copyright (C) 2008 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* NSURL+DAV.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2008 Inverse groupe conseil
|
||||
* Copyright (C) 2008 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoAuthenticator.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoCache.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2008 Inverse groupe conseil
|
||||
* Copyright (C) 2008 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoCache.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2008 Inverse groupe conseil
|
||||
* Copyright (C) 2008 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoFolder.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoFolder.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/* SOGoGCSFolder.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2004-2005 SKYRIX Software AG
|
||||
* Copyright (C) 2006-2008 Inverse groupe conseil
|
||||
* Copyright (C) 2006-2008 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoLDAPUserDefaults.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2008 Inverse groupe conseil
|
||||
* Copyright (C) 2008 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoLDAPUserDefaults.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2008 Inverse groupe conseil
|
||||
* Copyright (C) 2008 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
@@ -20,8 +20,316 @@
|
||||
* Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
|
||||
#define LDAP_DEPRECATED 1
|
||||
|
||||
#import <ldap.h>
|
||||
|
||||
#import <Foundation/NSArray.h>
|
||||
#import <Foundation/NSDictionary.h>
|
||||
#import <Foundation/NSString.h>
|
||||
|
||||
#import <NGExtensions/NSObject+Logs.h>
|
||||
|
||||
#import "SOGoLDAPUserDefaults.h"
|
||||
|
||||
#define SOGoLDAPDescriptor @"/etc/sogo.conf"
|
||||
#define SOGoLDAPContainerSize 64
|
||||
|
||||
typedef enum _SOGoLDAPValueType {
|
||||
SOGoLDAPAtom,
|
||||
SOGoLDAPArray,
|
||||
SOGoLDAPDictionary,
|
||||
SOGoLDAPLastType
|
||||
} _SOGoLDAPValueType;
|
||||
|
||||
typedef struct _SOGoLDAPValue {
|
||||
_SOGoLDAPValueType type;
|
||||
void *value;
|
||||
unsigned int maxCount;
|
||||
char *key;
|
||||
} _SOGoLDAPValue;
|
||||
|
||||
@implementation SOGoLDAPUserDefaults
|
||||
|
||||
static _SOGoLDAPValue*
|
||||
_createAtom (_SOGoLDAPValueType type, void *value)
|
||||
{
|
||||
_SOGoLDAPValue *newAtom;
|
||||
|
||||
newAtom = calloc (sizeof (_SOGoLDAPValue), 1);
|
||||
newAtom->type = type;
|
||||
newAtom->value = value;
|
||||
|
||||
return newAtom;
|
||||
}
|
||||
|
||||
static _SOGoLDAPValue*
|
||||
_createContainer (_SOGoLDAPValueType type)
|
||||
{
|
||||
_SOGoLDAPValue *newContainer;
|
||||
_SOGoLDAPValue **array;
|
||||
|
||||
array = malloc (sizeof (_SOGoLDAPValue *) * SOGoLDAPContainerSize);
|
||||
*array = NULL;
|
||||
newContainer = _createAtom (type, array);
|
||||
newContainer->maxCount = SOGoLDAPContainerSize - 1; /* all values + NULL */
|
||||
|
||||
return newContainer;
|
||||
}
|
||||
|
||||
static void
|
||||
_appendAtomToContainer (_SOGoLDAPValue *atom, _SOGoLDAPValue *container)
|
||||
{
|
||||
unsigned int count;
|
||||
_SOGoLDAPValue **atoms, **currentAtom;
|
||||
|
||||
atoms = (_SOGoLDAPValue **) container->value;
|
||||
currentAtom = atoms;
|
||||
while (*currentAtom)
|
||||
currentAtom++;
|
||||
|
||||
count = (currentAtom - atoms);
|
||||
if (count > container->maxCount)
|
||||
{
|
||||
container->maxCount += SOGoLDAPContainerSize;
|
||||
container->value = realloc (container->value, container->maxCount + 1);
|
||||
}
|
||||
*currentAtom = atom;
|
||||
*(currentAtom + 1) = NULL;
|
||||
}
|
||||
|
||||
static _SOGoLDAPValue **
|
||||
_findAtomInDictionary (const char *key, const _SOGoLDAPValue *dictionary)
|
||||
{
|
||||
_SOGoLDAPValue **atom, **value;
|
||||
|
||||
atom = NULL;
|
||||
|
||||
value = dictionary->value;
|
||||
if (value)
|
||||
{
|
||||
while (!atom && *value)
|
||||
if (strcmp ((*value)->key, key) == 0)
|
||||
atom = value;
|
||||
else
|
||||
value++;
|
||||
}
|
||||
|
||||
return atom;
|
||||
}
|
||||
|
||||
static void
|
||||
_appendAtomToDictionary (_SOGoLDAPValue *atom, _SOGoLDAPValue *dictionary)
|
||||
{
|
||||
_SOGoLDAPValue **oldAtomPtr, *oldAtom, *container;
|
||||
|
||||
oldAtomPtr = _findAtomInDictionary (atom->key, dictionary);
|
||||
if (oldAtomPtr)
|
||||
{
|
||||
oldAtom = *oldAtomPtr;
|
||||
if (oldAtom->type == SOGoLDAPAtom)
|
||||
{
|
||||
container = _createContainer (SOGoLDAPArray);
|
||||
container->key = oldAtom->key;
|
||||
oldAtom->key = NULL;
|
||||
_appendAtomToContainer (oldAtom, container);
|
||||
*oldAtomPtr = container;
|
||||
}
|
||||
else if (oldAtom->type == SOGoLDAPArray)
|
||||
container = oldAtom;
|
||||
else
|
||||
{
|
||||
// some error handling here...
|
||||
}
|
||||
}
|
||||
else
|
||||
container = dictionary;
|
||||
|
||||
if (container->type == SOGoLDAPArray)
|
||||
{
|
||||
free (atom->key);
|
||||
atom->key = NULL;
|
||||
}
|
||||
_appendAtomToContainer (atom, container);
|
||||
}
|
||||
|
||||
static _SOGoLDAPValue *
|
||||
_readLDAPDictionaryWithHandle(const char *dn, LDAP *ldapHandle)
|
||||
{
|
||||
struct timeval timeout;
|
||||
int rc;
|
||||
_SOGoLDAPValue *atom, *dictionary;
|
||||
LDAPMessage *messages, *message;
|
||||
BerElement *element;
|
||||
BerValue **values, **value;
|
||||
const char *attribute;
|
||||
|
||||
dictionary = _createContainer (SOGoLDAPDictionary);
|
||||
|
||||
timeout.tv_sec = 100;
|
||||
timeout.tv_usec = 0;
|
||||
|
||||
rc = ldap_search_ext_s (ldapHandle, dn, LDAP_SCOPE_BASE, "(objectClass=*)",
|
||||
NULL, 0, NULL, NULL, &timeout, 0, &messages);
|
||||
fprintf (stderr, "code: %d, %s\n", rc, ldap_err2string (rc));
|
||||
if (rc == LDAP_SUCCESS)
|
||||
{
|
||||
message = ldap_first_entry (ldapHandle, messages);
|
||||
if (message)
|
||||
{
|
||||
attribute = ldap_first_attribute (ldapHandle, message, &element);
|
||||
while (attribute)
|
||||
{
|
||||
values = ldap_get_values_len (ldapHandle, message, attribute);
|
||||
value = values;
|
||||
while (*value)
|
||||
{
|
||||
if (strncmp ((*value)->bv_val, "dict-dn:", 8) == 0)
|
||||
atom
|
||||
= _readLDAPDictionaryWithHandle (((*value)->bv_val + 8),
|
||||
ldapHandle);
|
||||
else
|
||||
atom = _createAtom (SOGoLDAPAtom,
|
||||
strdup ((*value)->bv_val));
|
||||
atom->key = strdup (attribute);
|
||||
_appendAtomToDictionary (atom, dictionary);
|
||||
value++;
|
||||
}
|
||||
ldap_value_free_len (values);
|
||||
attribute = ldap_next_attribute (ldapHandle, message, element);
|
||||
}
|
||||
}
|
||||
ldap_msgfree (message);
|
||||
}
|
||||
|
||||
return dictionary;
|
||||
}
|
||||
|
||||
static NSString *_convertLDAPAtomToNSString (_SOGoLDAPValue *atom);
|
||||
static NSArray *_convertLDAPAtomToNSArray (_SOGoLDAPValue *atom);
|
||||
static NSDictionary *_convertLDAPAtomToNSDictionary (_SOGoLDAPValue *atom);
|
||||
|
||||
static id
|
||||
_convertLDAPAtomToNSObject (_SOGoLDAPValue *atom)
|
||||
{
|
||||
id ldapObject;
|
||||
|
||||
if (atom->type == SOGoLDAPAtom)
|
||||
ldapObject = _convertLDAPAtomToNSString (atom);
|
||||
else if (atom->type == SOGoLDAPArray)
|
||||
ldapObject = _convertLDAPAtomToNSArray (atom);
|
||||
else
|
||||
ldapObject = _convertLDAPAtomToNSDictionary (atom);
|
||||
|
||||
return ldapObject;
|
||||
}
|
||||
|
||||
static NSString *
|
||||
_convertLDAPAtomToNSString (_SOGoLDAPValue *atom)
|
||||
{
|
||||
NSString *ldapObject;
|
||||
|
||||
ldapObject = [[NSString alloc]
|
||||
initWithBytes: atom->value
|
||||
length: strlen (atom->value)
|
||||
encoding: NSUTF8StringEncoding];
|
||||
[ldapObject autorelease];
|
||||
|
||||
return ldapObject;
|
||||
}
|
||||
|
||||
static NSArray *
|
||||
_convertLDAPAtomToNSArray (_SOGoLDAPValue *atom)
|
||||
{
|
||||
_SOGoLDAPValue **currentSubAtom;
|
||||
NSMutableArray *ldapObject;
|
||||
|
||||
ldapObject = [NSMutableArray array];
|
||||
|
||||
currentSubAtom = atom->value;
|
||||
while (*currentSubAtom)
|
||||
{
|
||||
[ldapObject addObject: _convertLDAPAtomToNSObject (*currentSubAtom)];
|
||||
currentSubAtom++;
|
||||
}
|
||||
|
||||
return ldapObject;
|
||||
}
|
||||
|
||||
static NSDictionary *
|
||||
_convertLDAPAtomToNSDictionary (_SOGoLDAPValue *atom)
|
||||
{
|
||||
_SOGoLDAPValue **currentSubAtom;
|
||||
NSMutableDictionary *ldapObject;
|
||||
NSString *atomKey;
|
||||
|
||||
ldapObject = [NSMutableDictionary dictionary];
|
||||
|
||||
currentSubAtom = atom->value;
|
||||
while (*currentSubAtom)
|
||||
{
|
||||
atomKey = [[NSString alloc]
|
||||
initWithBytes: (*currentSubAtom)->key
|
||||
length: strlen ((*currentSubAtom)->key)
|
||||
encoding: NSUTF8StringEncoding];
|
||||
[atomKey autorelease];
|
||||
[ldapObject setObject: _convertLDAPAtomToNSObject (*currentSubAtom)
|
||||
forKey: atomKey];
|
||||
currentSubAtom++;
|
||||
}
|
||||
|
||||
return ldapObject;
|
||||
}
|
||||
|
||||
// dn = "cn=admin,dc=inverse,dc=ca";
|
||||
// password = "qwerty";
|
||||
// uri = "ldap://127.0.0.1";
|
||||
// configDN = @"cn=sogo-config,dc=inverse,dc=ca";
|
||||
|
||||
static _SOGoLDAPValue *
|
||||
_initLDAPDefaults ()
|
||||
{
|
||||
#error dn, password, uri, configDN should be defined
|
||||
const char *dn, *password, *uri, *configDN;
|
||||
LDAP *ldapHandle;
|
||||
int rc, opt;
|
||||
_SOGoLDAPValue *dictionary;
|
||||
|
||||
ldap_initialize (&ldapHandle, uri);
|
||||
|
||||
opt = LDAP_VERSION3;
|
||||
rc = ldap_set_option (ldapHandle, LDAP_OPT_PROTOCOL_VERSION, &opt);
|
||||
rc = ldap_set_option (ldapHandle, LDAP_OPT_REFERRALS, LDAP_OPT_OFF);
|
||||
// rc = ldap_sasl_bind_s (ldapHandle, dn, LDAP_SASL_NULL, password, NULL, NULL, &none);
|
||||
rc = ldap_simple_bind_s (ldapHandle, dn, password);
|
||||
if (rc == LDAP_SUCCESS)
|
||||
dictionary
|
||||
= _readLDAPDictionaryWithHandle (configDN, ldapHandle);
|
||||
else
|
||||
dictionary = _createContainer (SOGoLDAPDictionary);
|
||||
|
||||
return dictionary;
|
||||
}
|
||||
|
||||
- (id) objectForKey: (NSString *) key
|
||||
{
|
||||
static _SOGoLDAPValue *SOGoLDAPDefaults = NULL;
|
||||
_SOGoLDAPValue **atom;
|
||||
id ldapObject;
|
||||
|
||||
if (!SOGoLDAPDefaults)
|
||||
SOGoLDAPDefaults = _initLDAPDefaults ();
|
||||
|
||||
atom = _findAtomInDictionary ([key UTF8String], SOGoLDAPDefaults);
|
||||
if (atom)
|
||||
ldapObject = _convertLDAPAtomToNSObject (*atom);
|
||||
else
|
||||
ldapObject = nil;
|
||||
|
||||
if (!ldapObject)
|
||||
ldapObject = [super objectForKey: key];
|
||||
|
||||
return ldapObject;
|
||||
}
|
||||
|
||||
@end
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoMailer.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoMailer.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007-2008 Inverse groupe conseil
|
||||
* Copyright (C) 2007-2008 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/* SOGoGCSFolder.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2004-2005 SKYRIX Software AG
|
||||
* Copyright (C) 2006-2008 Inverse groupe conseil
|
||||
* Copyright (C) 2006-2008 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoParentFolder.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2006, 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2006, 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoParentFolder.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2006, 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2006, 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoPermissions.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2006 Inverse groupe conseil
|
||||
* Copyright (C) 2006 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoPermissions.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2006 Inverse groupe conseil
|
||||
* Copyright (C) 2006 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoWebAuthenticator.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoWebAuthenticator.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoWebDAVAclManager.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2008 Inverse groupe conseil
|
||||
* Copyright (C) 2008 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoWebDAVAclManager.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2008 Inverse groupe conseil
|
||||
* Copyright (C) 2008 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoWebDAVValue.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2008 Inverse groupe conseil
|
||||
* Copyright (C) 2008 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* SOGoWebDAVValue.m - this file is part of $PROJECT_NAME_HERE$
|
||||
*
|
||||
* Copyright (C) 2008 Inverse groupe conseil
|
||||
* Copyright (C) 2008 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* WORequest+SOGo.h - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* WORequest+SOGo.m - this file is part of SOGo
|
||||
*
|
||||
* Copyright (C) 2007 Inverse groupe conseil
|
||||
* Copyright (C) 2007 Inverse inc.
|
||||
*
|
||||
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
*
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user