Merge remote-tracking branch 'origin/syncevolution-1-2-branch'
Conflicts: configure.ac src/syncevo-dbus-server.cpp src/syncevo/Cmdline.cpp test/ClientTest.cpp test/ClientTest.h test/generate-html.xsl test/runtests.py Conflicts caused by backporting + merging back slightly modified backports.
This commit is contained in:
commit
4fc6c3e2c4
79
NEWS
79
NEWS
|
@ -1,3 +1,82 @@
|
|||
SyncEvolution 1.2 -> 1.2.1, 25.11.2011
|
||||
======================================
|
||||
|
||||
Maintenance release with various bug fixes.
|
||||
|
||||
* GTK UI + config: fix "custom server" setup (BMC #13511)
|
||||
|
||||
When the "default" config template (= ScheduleWorld) was downgraded to
|
||||
"not consumer ready" in SyncEvolution 1.1.0.99.1, setting up a custom
|
||||
SyncML service in the GTK UI stopped working because the UI wouldn't
|
||||
show the "not consumer ready" config.
|
||||
|
||||
The problem described above is deterministic and fixed now.
|
||||
Initially the problem seemed to be random. So perhaps there is
|
||||
also another, related issue.
|
||||
|
||||
* phone sync: delete<->delete conflict + phone calendar+todo sync (BMC #23744)
|
||||
|
||||
When deleting an item on phone and locally, the next sync failed with
|
||||
ERROR messages about "object not found". Retrying the sync then worked.
|
||||
|
||||
* Nokia: prevent accidental usage of "calendar" or "todo" sources
|
||||
|
||||
Nokia phones use a combined "calendar+todo" source for syncing. The
|
||||
"calendar" and "todo" sources also exist because that is where local
|
||||
databases are configured.
|
||||
|
||||
In such a setup, syncing always has to use "calendar+todo". For example,
|
||||
to refresh from the Linux desktop to the phone, use:
|
||||
--sync refresh-from-server <config> calendar+todo
|
||||
|
||||
To work with items (restore, show local content), use the underlying sources,
|
||||
as in:
|
||||
--print-items <config> calendar
|
||||
|
||||
It was possible to accidentally sync with the "calendar". This commit
|
||||
prevents that by adding an invalid URI setting to the "calendar" and
|
||||
"todo" sources in the Nokia and Ovi templates. Existing configs are not
|
||||
touched, so beware when you already have configured your Nokia phone.
|
||||
|
||||
* vCard: X- chat extensions were limited to one instance per kind
|
||||
|
||||
For example, only one Jabber account could be synchronized. This
|
||||
was caused by an incomplete definition of the conversion to and from
|
||||
vCard.
|
||||
|
||||
* syncevo-dbus-server + phone sync: catch SIGPIPE to avoid premature exit
|
||||
|
||||
Frederik Elwert reported that running a local sync with a phone via
|
||||
Bluetooth caused the syncevo-dbus-server to shut down during a sync.
|
||||
Explicitly telling the process to ignore the SIGPIPE signal solved that
|
||||
problem.
|
||||
|
||||
* syncevo-http-server: support chained SSL certificates
|
||||
|
||||
So far, the file pointed to by --certificate-file had to
|
||||
contain the server certificated (signed by a CA known to the client)
|
||||
and (optionally) a client certificate. Now the file may also contain
|
||||
additional intermediate certificates which will be sent to the client
|
||||
(chained certificates).
|
||||
|
||||
* documentation: added glossary and command line conventions sections,
|
||||
improved listing of properties, embedd property definitions in man page,
|
||||
README and README.html
|
||||
|
||||
* EDS compatibility: fixed inconsistency in libecal check
|
||||
|
||||
The check for the _r variants in libical still used an older max
|
||||
version. This might have prevented using them (if not found) or
|
||||
could have led to a mixture of old and new libecal in the same
|
||||
process (probably crashed).
|
||||
|
||||
* glib: avoid including glib/*.h headers directly
|
||||
|
||||
Recent glib deprecates the direct inclusion of some of its headers,
|
||||
in favor of including glib.h. Doing that here whenever possible, so
|
||||
perhaps it now compiles on Fedora 17 (untested).
|
||||
|
||||
|
||||
SyncEvolution 1.1.1 -> 1.2, 13.10.2011
|
||||
======================================
|
||||
|
||||
|
|
|
@ -8,7 +8,7 @@ dnl Invoke autogen.sh to produce a configure script.
|
|||
#
|
||||
# Starting with the 1.1 release cycle, the rpm-style
|
||||
# .99 pseudo-version number is used to mark a pre-release.
|
||||
AC_INIT([syncevolution], [m4_esyscmd([build/gen-git-version.sh 1.2])])
|
||||
AC_INIT([syncevolution], [m4_esyscmd([build/gen-git-version.sh 1.2.1])])
|
||||
# STABLE_VERSION=1.0.1+
|
||||
AC_SUBST(STABLE_VERSION)
|
||||
|
||||
|
@ -25,7 +25,7 @@ SE_CHECK_FOR_STABLE_RELEASE
|
|||
|
||||
# Minimum version of libsynthesis as defined in its
|
||||
# configure script and thus .pc files:
|
||||
define([SYNTHESIS_MIN_VERSION], [3.4.0.16.5])
|
||||
define([SYNTHESIS_MIN_VERSION], [3.4.0.16.6])
|
||||
|
||||
# Line above is patched by gen-autotools.sh. Handle
|
||||
# both "yes" and "no".
|
||||
|
|
|
@ -27,6 +27,7 @@
|
|||
#include "syncevo/util.h"
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <glib.h>
|
||||
#include <glib/gi18n.h>
|
||||
#include <boost/algorithm/string/predicate.hpp>
|
||||
|
||||
|
|
|
@ -21,6 +21,7 @@
|
|||
#include "session.h"
|
||||
#include "server.h"
|
||||
|
||||
#include <glib.h>
|
||||
#include <glib/gi18n.h>
|
||||
|
||||
#include <boost/tokenizer.hpp>
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
*
|
||||
*/
|
||||
|
||||
#include <glib/gmessages.h>
|
||||
#include <glib.h>
|
||||
|
||||
//#define DBG(fmt, arg...) g_debug("%s: " fmt, __FUNCTION__ , ## arg)
|
||||
#define DBG(fmt, arg...)
|
||||
|
|
|
@ -22,6 +22,7 @@
|
|||
#endif
|
||||
|
||||
#include <gtk/gtk.h>
|
||||
#include <glib.h>
|
||||
#include <glib/gi18n.h>
|
||||
#include <bluetooth-plugin.h>
|
||||
#include <unistd.h>
|
||||
|
|
|
@ -18,6 +18,7 @@
|
|||
*/
|
||||
|
||||
#include <gtk/gtk.h>
|
||||
#include <glib.h>
|
||||
#include <glib/gi18n.h>
|
||||
|
||||
#include "config.h"
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <glib.h>
|
||||
#include <glib/gi18n.h>
|
||||
#include <dbus/dbus-glib.h>
|
||||
|
||||
|
|
|
@ -17,6 +17,7 @@
|
|||
* 02110-1301 USA
|
||||
*/
|
||||
|
||||
#include <glib.h>
|
||||
#include <glib/gi18n.h>
|
||||
|
||||
#include <string.h>
|
||||
|
|
|
@ -23,6 +23,7 @@
|
|||
#include <string.h>
|
||||
#include <gdk/gdkkeysyms.h>
|
||||
#include <gtk/gtk.h>
|
||||
#include <glib.h>
|
||||
#include <glib/gi18n.h>
|
||||
#include <gio/gio.h>
|
||||
#include <dbus/dbus-glib.h>
|
||||
|
|
|
@ -2664,9 +2664,9 @@ protected:
|
|||
NULL);
|
||||
cmdline.doit();
|
||||
string res = scanFiles(root, "some-other-server");
|
||||
string expected = ScheduleWorldConfig();
|
||||
string expected = DefaultConfig();
|
||||
sortConfig(expected);
|
||||
boost::replace_all(expected, "/scheduleworld/", "/some-other-server/");
|
||||
boost::replace_all(expected, "/syncevolution/", "/some-other-server/");
|
||||
CPPUNIT_ASSERT_EQUAL_DIFF(expected, res);
|
||||
}
|
||||
|
||||
|
@ -2914,7 +2914,7 @@ protected:
|
|||
CPPUNIT_ASSERT_EQUAL_DIFF("", cmdline.m_err.str());
|
||||
string actual = injectValues(filterConfig(cmdline.m_out.str()));
|
||||
CPPUNIT_ASSERT(boost::contains(actual, "deviceId = fixed-devid"));
|
||||
CPPUNIT_ASSERT_EQUAL_DIFF(filterConfig(internalToIni(ScheduleWorldConfig())),
|
||||
CPPUNIT_ASSERT_EQUAL_DIFF(filterConfig(internalToIni(DefaultConfig())),
|
||||
actual);
|
||||
}
|
||||
|
||||
|
@ -4428,6 +4428,24 @@ private:
|
|||
boost::scoped_array<const char *> m_argv;
|
||||
};
|
||||
|
||||
string DefaultConfig() {
|
||||
string config = ScheduleWorldConfig();
|
||||
boost::replace_first(config,
|
||||
"syncURL = http://sync.scheduleworld.com/funambol/ds",
|
||||
"syncURL = http://yourserver:port");
|
||||
boost::replace_first(config, "http://www.scheduleworld.com", "http://www.syncevolution.org");
|
||||
boost::replace_all(config, "ScheduleWorld", "SyncEvolution");
|
||||
boost::replace_all(config, "scheduleworld", "syncevolution");
|
||||
boost::replace_first(config, "PeerName = SyncEvolution", "# PeerName = ");
|
||||
boost::replace_first(config, "# ConsumerReady = 0", "ConsumerReady = 1");
|
||||
boost::replace_first(config, "uri = card3", "uri = addressbook");
|
||||
boost::replace_first(config, "uri = cal2", "uri = calendar");
|
||||
boost::replace_first(config, "uri = task2", "uri = todo");
|
||||
boost::replace_first(config, "uri = note", "uri = memo");
|
||||
boost::replace_first(config, "syncFormat = text/vcard", "# syncFormat = ");
|
||||
return config;
|
||||
}
|
||||
|
||||
string ScheduleWorldConfig(int contextMinVersion = CONFIG_CONTEXT_MIN_VERSION,
|
||||
int contextCurVersion = CONFIG_CONTEXT_CUR_VERSION,
|
||||
int peerMinVersion = CONFIG_PEER_MIN_VERSION,
|
||||
|
|
|
@ -31,7 +31,7 @@
|
|||
#include <fcntl.h>
|
||||
#include <errno.h>
|
||||
#include <sys/socket.h>
|
||||
#include <glib/giochannel.h>
|
||||
#include <glib.h>
|
||||
#include <syncevo/SyncContext.h>
|
||||
#include <syncevo/ObexTransportAgent.h>
|
||||
|
||||
|
|
|
@ -27,7 +27,7 @@
|
|||
#include <syncevo/TransportAgent.h>
|
||||
#include <syncevo/SmartPtr.h>
|
||||
#include <libsoup/soup.h>
|
||||
#include <glib/gmain.h>
|
||||
#include <glib.h>
|
||||
|
||||
#include <syncevo/declarations.h>
|
||||
SE_BEGIN_CXX
|
||||
|
|
|
@ -837,6 +837,17 @@ boost::shared_ptr<SyncConfig> SyncConfig::createPeerTemplate(const string &serve
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
// "default" maps to SyncEvolution server template, which is not
|
||||
// consumer ready. When used as "default" by the GTK sync UI,
|
||||
// the UI expects the "consumer ready" flag to be set. Do that
|
||||
// here. Also unset the peer name, because otherwise it shows
|
||||
// up in the UI.
|
||||
if (server == "default") {
|
||||
config->setConsumerReady(true);
|
||||
config->setUserPeerName("");
|
||||
}
|
||||
|
||||
return config;
|
||||
}
|
||||
|
||||
|
|
|
@ -2746,6 +2746,11 @@ void SyncContext::initMain(const char *appname)
|
|||
g_set_prgname(appname);
|
||||
#endif
|
||||
|
||||
struct sigaction sa;
|
||||
memset(&sa, 0, sizeof(sa));
|
||||
sa.sa_handler = SIG_IGN;
|
||||
sigaction(SIGPIPE, &sa, NULL);
|
||||
|
||||
// Initializing a potential use of EDS early is necessary for
|
||||
// libsynthesis when compiled with
|
||||
// --enable-evolution-compatibility: in that mode libical will
|
||||
|
|
|
@ -232,95 +232,112 @@
|
|||
<property name="X-AIM" suppressempty="yes" rule="KDE"/>
|
||||
<property name="X-AIM" suppressempty="yes" rule="other">
|
||||
<value field="AIM_HANDLE"/>
|
||||
<position field="AIM_HANDLE" repeat="array" increment="1" minshow="0"/>
|
||||
<parameter name="X-EVOLUTION-UI-SLOT" positional="no" show="no" rule="HAVE-EVOLUTION-UI-SLOT">
|
||||
<value field="AIM_SLOT"/>
|
||||
</parameter>
|
||||
</property>
|
||||
<property name="X-messaging/aim-All" suppressempty="yes" show="no" rule="KDE">
|
||||
<value field="AIM_HANDLE"/>
|
||||
<position field="AIM_HANDLE" repeat="array" increment="1" minshow="0"/>
|
||||
</property>
|
||||
|
||||
<property name="X-GADUGADU" suppressempty="yes" rule="KDE"/>
|
||||
<property name="X-GADUGADU" suppressempty="yes" rule="other">
|
||||
<value field="GADUGADU_HANDLE"/>
|
||||
<position field="GADUGADU_HANDLE" repeat="array" increment="1" minshow="0"/>
|
||||
<parameter name="X-EVOLUTION-UI-SLOT" positional="no" show="no" rule="HAVE-EVOLUTION-UI-SLOT">
|
||||
<value field="GADUGADU_SLOT"/>
|
||||
</parameter>
|
||||
</property>
|
||||
<property name="X-messaging/gadu-All" suppressempty="yes" show="no" rule="KDE">
|
||||
<value field="GADUGADU_HANDLE"/>
|
||||
<position field="GADUGADU_HANDLE" repeat="array" increment="1" minshow="0"/>
|
||||
</property>
|
||||
|
||||
|
||||
<property name="X-GROUPWISE" suppressempty="yes" rule="KDE"/>
|
||||
<property name="X-GROUPWISE" suppressempty="yes" rule="other">
|
||||
<value field="GROUPWISE_HANDLE"/>
|
||||
<position field="GROUPWISE_HANDLE" repeat="array" increment="1" minshow="0"/>
|
||||
<parameter name="X-EVOLUTION-UI-SLOT" positional="no" show="no" rule="HAVE-EVOLUTION-UI-SLOT">
|
||||
<value field="GROUPWISE_SLOT"/>
|
||||
</parameter>
|
||||
</property>
|
||||
<property name="X-messaging/groupwise-All" suppressempty="yes" show="no" rule="KDE">
|
||||
<value field="GROUPWISE_HANDLE"/>
|
||||
<position field="GROUPWISE_HANDLE" repeat="array" increment="1" minshow="0"/>
|
||||
</property>
|
||||
|
||||
<property name="X-ICQ" suppressempty="yes" rule="KDE"/>
|
||||
<property name="X-ICQ" suppressempty="yes" rule="other">
|
||||
<value field="ICQ_HANDLE"/>
|
||||
<position field="ICQ_HANDLE" repeat="array" increment="1" minshow="0"/>
|
||||
<parameter name="X-EVOLUTION-UI-SLOT" positional="no" show="no" rule="HAVE-EVOLUTION-UI-SLOT">
|
||||
<value field="ICQ_SLOT"/>
|
||||
</parameter>
|
||||
</property>
|
||||
<property name="X-messaging/icq-All" suppressempty="yes" show="no" rule="KDE">
|
||||
<value field="ICQ_HANDLE"/>
|
||||
<position field="ICQ_HANDLE" repeat="array" increment="1" minshow="0"/>
|
||||
</property>
|
||||
|
||||
<property name="X-JABBER" suppressempty="yes" rule="KDE"/>
|
||||
<property name="X-JABBER" suppressempty="yes" rule="other">
|
||||
<value field="JABBER_HANDLE"/>
|
||||
<position field="JABBER_HANDLE" repeat="array" increment="1" minshow="0"/>
|
||||
<parameter name="X-EVOLUTION-UI-SLOT" positional="no" show="no">
|
||||
<value field="JABBER_SLOT"/>
|
||||
</parameter>
|
||||
</property>
|
||||
<property name="X-messaging/xmpp-All" suppressempty="yes" show="no" rule="KDE">
|
||||
<value field="JABBER_HANDLE"/>
|
||||
<position field="JABBER_HANDLE" repeat="array" increment="1" minshow="0"/>
|
||||
</property>
|
||||
|
||||
<property name="X-MSN" suppressempty="yes" rule="KDE"/>
|
||||
<property name="X-MSN" suppressempty="yes" rule="other">
|
||||
<value field="MSN_HANDLE"/>
|
||||
<position field="MSN_HANDLE" repeat="array" increment="1" minshow="0"/>
|
||||
<parameter name="X-EVOLUTION-UI-SLOT" positional="no" show="no" rule="HAVE-EVOLUTION-UI-SLOT">
|
||||
<value field="MSN_SLOT"/>
|
||||
</parameter>
|
||||
</property>
|
||||
<property name="X-messaging/msn-All" suppressempty="yes" show="no" rule="KDE">
|
||||
<value field="MSN_HANDLE"/>
|
||||
<position field="MSN_HANDLE" repeat="array" increment="1" minshow="0"/>
|
||||
</property>
|
||||
|
||||
<property name="X-YAHOO" suppressempty="yes" rule="KDE"/>
|
||||
<property name="X-YAHOO" suppressempty="yes" rule="other">
|
||||
<value field="YAHOO_HANDLE"/>
|
||||
<position field="YAHOO_HANDLE" repeat="array" increment="1" minshow="0"/>
|
||||
<parameter name="X-EVOLUTION-UI-SLOT" positional="no" show="no" rule="HAVE-EVOLUTION-UI-SLOT">
|
||||
<value field="YAHOO_SLOT"/>
|
||||
</parameter>
|
||||
</property>
|
||||
<property name="X-messaging/yahoo-All" suppressempty="yes" show="no" rule="KDE">
|
||||
<value field="YAHOO_HANDLE"/>
|
||||
<position field="YAHOO_HANDLE" repeat="array" increment="1" minshow="0"/>
|
||||
</property>
|
||||
|
||||
<property name="X-SKYPE" suppressempty="yes" rule="KDE"/>
|
||||
<property name="X-SKYPE" suppressempty="yes" rule="other">
|
||||
<value field="SKYPE_HANDLE"/>
|
||||
<position field="SKYPE_HANDLE" repeat="array" increment="1" minshow="0"/>
|
||||
<parameter name="X-EVOLUTION-UI-SLOT" positional="no" show="no" rule="HAVE-EVOLUTION-UI-SLOT">
|
||||
<value field="SKYPE_SLOT"/>
|
||||
</parameter>
|
||||
</property>
|
||||
<property name="X-messaging/skype-All" suppressempty="yes" show="no" rule="KDE">
|
||||
<value field="SKYPE_HANDLE"/>
|
||||
<position field="SKYPE_HANDLE" repeat="array" increment="1" minshow="0"/>
|
||||
</property>
|
||||
|
||||
<!-- No X-messaging/sip-All in KDE?! Then let's use X-SIP for everyone. -->
|
||||
<property name="X-SIP" suppressempty="yes">
|
||||
<value field="SIP_HANDLE"/>
|
||||
<position field="SIP_HANDLE" repeat="array" increment="1" minshow="0"/>
|
||||
<parameter name="X-EVOLUTION-UI-SLOT" positional="no" show="no" rule="HAVE-EVOLUTION-UI-SLOT">
|
||||
<value field="SIP_SLOT"/>
|
||||
</parameter>
|
||||
|
@ -333,12 +350,15 @@
|
|||
-->
|
||||
<property name="X-messaging/irc-All" suppressempty="yes">
|
||||
<value field="IRC_HANDLE"/>
|
||||
<position field="IRC_HANDLE" repeat="array" increment="1" minshow="0"/>
|
||||
</property>
|
||||
<property name="X-messaging/meanwhile-All" suppressempty="yes">
|
||||
<value field="MEANWHILE_HANDLE"/>
|
||||
<position field="MEANWHILE_HANDLE" repeat="array" increment="1" minshow="0"/>
|
||||
</property>
|
||||
<property name="X-messaging/sms-All" suppressempty="yes">
|
||||
<value field="SMS_HANDLE"/>
|
||||
<position field="SMS_HANDLE" repeat="array" increment="1" minshow="0"/>
|
||||
</property>
|
||||
<property name="X-KADDRESSBOOK-CRYPTOENCRYPTPREF" suppressempty="yes">
|
||||
<value field="CRYPTOENCRYPTPREF" show="yes"/>
|
||||
|
|
|
@ -16,10 +16,12 @@ backend = addressbook
|
|||
|
||||
=== sources/calendar/config.ini ===
|
||||
sync = none
|
||||
uri = use-calendar+todo-for-sync-instead-of-calendar
|
||||
backend = calendar
|
||||
|
||||
=== sources/todo/config.ini ===
|
||||
sync = none
|
||||
uri = use-calendar+todo-for-sync-instead-of-todo
|
||||
backend = todo
|
||||
|
||||
=== sources/memo/config.ini ===
|
||||
|
|
|
@ -17,13 +17,13 @@ backend = addressbook
|
|||
|
||||
=== sources/calendar/config.ini ===
|
||||
sync = none
|
||||
uri =
|
||||
uri = use-calendar+todo-for-sync-instead-of-calendar
|
||||
syncFormat = text/x-vcalendar
|
||||
backend = calendar
|
||||
|
||||
=== sources/todo/config.ini ===
|
||||
sync = none
|
||||
uri =
|
||||
uri = use-calendar+todo-for-sync-instead-of-todo
|
||||
syncFormat = text/x-vcalendar
|
||||
backend = todo
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
=== template.ini ===
|
||||
fingerprint = ScheduleWorld, default
|
||||
fingerprint = ScheduleWorld
|
||||
description = server no longer in operation
|
||||
|
||||
=== config.ini ===
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
=== template.ini ===
|
||||
fingerprint = SyncEvolution
|
||||
fingerprint = SyncEvolution, default
|
||||
description = http://www.syncevolution.org
|
||||
|
||||
=== config.ini ===
|
||||
|
|
|
@ -312,11 +312,17 @@ def step2(resultdir, result, servers, indents, srcdir, shellprefix, backenddir):
|
|||
#======================================================================
|
||||
# FAIL: TestDBusServer.testGetConfigsTemplates - Server.GetConfigsTemplates()
|
||||
# ---------------------------------------------------------------------
|
||||
#
|
||||
# More recent Python 2.7 produces:
|
||||
# FAIL: testSyncSecondSession (__main__.TestSessionAPIsReal)
|
||||
|
||||
# first build list of all tests, assuming that they pass
|
||||
dbustests = {}
|
||||
test_start = re.compile(r'''^Test(?P<cl>.*)\.test(?P<func>[^ ]*)''')
|
||||
# FAIL/ERROR + description of test (old Python)
|
||||
test_fail = re.compile(r'''(?P<type>FAIL|ERROR): Test(?P<cl>.*)\.test(?P<func>[^ ]*)''')
|
||||
# FAIL/ERROR + function name of test (Python 2.7)
|
||||
test_fail_27 = re.compile(r'''(?P<type>FAIL|ERROR): test(?P<func>[^ ]*) \(.*\.(?:Test(?P<cl>.*))\)''')
|
||||
logfile = None
|
||||
sepcount = 0
|
||||
for line in open(rserver + "/output.txt"):
|
||||
|
@ -324,7 +330,7 @@ def step2(resultdir, result, servers, indents, srcdir, shellprefix, backenddir):
|
|||
if m:
|
||||
is_okay = True
|
||||
else:
|
||||
m = test_fail.search(line)
|
||||
m = test_fail.search(line) or test_fail_27.search(line)
|
||||
is_okay = False
|
||||
if m:
|
||||
# create log file
|
||||
|
|
|
@ -1448,7 +1448,7 @@ memotootest = SyncEvolutionTest("memotoo", compile,
|
|||
"Client::Sync::eds_event_eds_task_eds_memo_eds_contact::testDeleteAllRefresh,"
|
||||
"Client::Sync::eds_event_eds_task_eds_memo_eds_contact::Retry,"
|
||||
"Client::Sync::eds_event_eds_task_eds_memo_eds_contact::Suspend "
|
||||
"CLIENT_TEST_DELAY=5 "
|
||||
"CLIENT_TEST_DELAY=10 "
|
||||
"CLIENT_TEST_COMPARE_LOG=T "
|
||||
"CLIENT_TEST_RESEND_TIMEOUT=5 "
|
||||
"CLIENT_TEST_INTERRUPT_AT=1",
|
||||
|
|
|
@ -26,6 +26,7 @@ import twisted.web
|
|||
import twisted.python.log
|
||||
from twisted.web import server, resource, http
|
||||
from twisted.internet import ssl, reactor
|
||||
from OpenSSL import SSL
|
||||
|
||||
# for output from this script itself
|
||||
logger = logging.getLogger("syncevo-http")
|
||||
|
@ -33,6 +34,25 @@ logger = logging.getLogger("syncevo-http")
|
|||
# for output from core SyncEvolution
|
||||
loggerCore = logging.getLogger("sync")
|
||||
|
||||
class ChainedOpenSSLContextFactory(ssl.DefaultOpenSSLContextFactory):
|
||||
def __init__(self, privateKeyFileName, certificateChainFileName,
|
||||
sslmethod = SSL.SSLv3_METHOD):
|
||||
"""
|
||||
@param privateKeyFileName: Name of a file containing a private key
|
||||
@param certificateChainFileName: Name of a file containing a certificate chain
|
||||
@param sslmethod: The SSL method to use
|
||||
"""
|
||||
self.privateKeyFileName = privateKeyFileName
|
||||
self.certificateChainFileName = certificateChainFileName
|
||||
self.sslmethod = sslmethod
|
||||
self.cacheContext()
|
||||
|
||||
def cacheContext(self):
|
||||
ctx = SSL.Context(self.sslmethod)
|
||||
ctx.use_certificate_chain_file(self.certificateChainFileName)
|
||||
ctx.use_privatekey_file(self.privateKeyFileName)
|
||||
self._context = ctx
|
||||
|
||||
# cached information about previous POST and reply,
|
||||
# in case that we need to resend
|
||||
class OldRequest:
|
||||
|
@ -505,7 +525,7 @@ syncevo-http-server itself is installed""")
|
|||
logger.error("need server certificate for https")
|
||||
exit(1)
|
||||
reactor.listenSSL(url.port, site,
|
||||
ssl.DefaultOpenSSLContextFactory(options.key or options.cert, options.cert))
|
||||
ChainedOpenSSLContextFactory(options.key or options.cert, options.cert))
|
||||
else:
|
||||
reactor.listenTCP(url.port, site)
|
||||
reactor.run()
|
||||
|
|
|
@ -16,7 +16,7 @@
|
|||
X-EVOLUTION-ANNIVERSARY:2006-01-09
|
||||
X-EVOLUTION-SPOUSE:Joan Doe
|
||||
NOTE:This is a test case which uses almost all Evolution fields.
|
||||
@@ -198,8 +198,6 @@
|
||||
@@ -198,14 +198,14 @@
|
||||
TEL;TYPE=WORK;TYPE=FAX;X-EVOLUTION-UI-SLOT=4:businessfax 4
|
||||
TEL;TYPE=HOME;TYPE=FAX;X-EVOLUTION-UI-SLOT=5:homefax 5
|
||||
TEL;TYPE=PAGER;X-EVOLUTION-UI-SLOT=6:pager 6
|
||||
|
@ -25,3 +25,11 @@
|
|||
X-AIM;X-EVOLUTION-UI-SLOT=1:AIM JOHN
|
||||
X-YAHOO;X-EVOLUTION-UI-SLOT=2:YAHOO JDOE
|
||||
X-ICQ;X-EVOLUTION-UI-SLOT=3:ICQ JD
|
||||
X-GROUPWISE;X-EVOLUTION-UI-SLOT=4:GROUPWISE DOE
|
||||
+X-GROUPWISE;X-EVOLUTION-UI-SLOT=5:GROUPWISE DOE 2ND
|
||||
X-GADUGADU:GADUGADU DOE
|
||||
X-JABBER:JABBER DOE
|
||||
+X-JABBER:JABBER DOE 2ND
|
||||
X-MSN:MSN DOE
|
||||
X-SKYPE:SKYPE DOE
|
||||
X-SIP:SIP DOE
|
||||
|
|
Loading…
Reference in New Issue