Projects
Kolab:Winterfell
kolab-freebusy
Log In
Username
Password
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
Expand all
Collapse all
Changes of Revision 8
View file
kolab-freebusy.spec
Changed
@@ -23,8 +23,8 @@ %global _ap_sysconfdir %{_sysconfdir}/%{httpd_name} Name: kolab-freebusy -Version: 1.1 -Release: 0.20150706.git92624e4%{?dist} +Version: 1.1.0 +Release: 1%{?dist} Summary: Kolab Free/Busy Web Presentation Layer Group: Applications/Internet @@ -163,10 +163,13 @@ %attr(0770,root,%{httpd_group}) %{_localstatedir}/log/%{name} %changelog -* Thu May 25 2017 Timotheus Pokorra <tp@tbits.net> - 1.1.0.1 +* Thu Jun 15 2017 Jeroen van Meeuwen <vanmeeuwen@kolabsys.com> - 1.1.0-1 +- Release 1.1.0 + +* Thu May 25 2017 Timotheus Pokorra <tp@tbits.net> - 1.1-0.1 - Fix build error on Fedora 25, composer needs php-justinrainbow-json-schema4 -* Mon Feb 23 2015 Daniel Hoffend <dh@dotlan.net> - 1.0.7.3 +* Mon Feb 23 2015 Daniel Hoffend <dh@dotlan.net> - 1.0.7-3 - seperate httpd.conf from .spec file * Sun Feb 22 2015 Jeroen van Meeuwen <vanmeeuwen@kolabsys.com> - 1.0.7-2
View file
debian.changelog
Changed
@@ -1,3 +1,9 @@ +kolab-freebusy (1.1.0-0~kolab1) unstable; urgency=low + + * Release of version 1.1.0 + + -- Jeroen van Meeuwen <vanmeeuwen@kolabsys.com> Thu, 15 Jun 2017 12:00:22 +0200 + kolab-freebusy (1.1~dev20150706-0~kolab3) unstable; urgency=low * roundcubemail package has been renamed to roundcubemail-core
View file
kolab-freebusy-1.1.tar.gz/composer.json -> kolab-freebusy-1.1.0.tar.gz/composer.json
Changed
@@ -2,7 +2,7 @@ "name": "kolab/free-busy", "description": "Kolab Free/Busy Service", "license": "AGPL-3.0", - "version": "1.1-dev", + "version": "1.1.0", "repositories": [ { "type": "pear",
View file
kolab-freebusy-1.1.tar.gz/composer.json-dist -> kolab-freebusy-1.1.0.tar.gz/composer.json-dist
Changed
@@ -2,7 +2,7 @@ "name": "kolab/free-busy", "description": "Kolab Free/Busy Service", "license": "AGPL-3.0", - "version": "1.1-dev", + "version": "1.1.0", "autoload": { "psr-0": { "": "/usr/share/pear/"
View file
kolab-freebusy-1.1.tar.gz/lib/Kolab/FreeBusy/DirectoryLDAP.php -> kolab-freebusy-1.1.0.tar.gz/lib/Kolab/FreeBusy/DirectoryLDAP.php
Changed
@@ -46,9 +46,9 @@ $host = parse_url($config['host']); $ldap_config = array( - 'hosts' => array($host['host']), + 'hosts' => array($config['host']), 'port' => $host['port'] ?: 389, - 'use_tls' => $host['scheme'] == 'tls' || $host['scheme'] == 'ldaps', + 'use_tls' => $host['scheme'] == 'tls', 'root_dn' => $config['root_dn'] ?: $config['base_dn'], 'log_hook' => array($this, 'log'), ) + $config;
View file
kolab-freebusy-1.1.tar.gz/lib/Kolab/FreeBusy/HTTPAuth.php -> kolab-freebusy-1.1.0.tar.gz/lib/Kolab/FreeBusy/HTTPAuth.php
Changed
@@ -85,9 +85,9 @@ $host = parse_url($config['host']); $ldap_config = array( - 'hosts' => array($host['host']), + 'hosts' => array($config['host']), 'port' => $host['port'] ?: 389, - 'use_tls' => $host['scheme'] == 'tls' || $host['scheme'] == 'ldaps', + 'use_tls' => $host['scheme'] == 'tls', 'root_dn' => $config['base_dn'], 'filter' => $config['filter'], 'service_bind_dn' => $config['bind_dn'],
View file
kolab-freebusy-1.1.tar.gz/lib/Kolab/FreeBusy/SourceIMAP.php -> kolab-freebusy-1.1.0.tar.gz/lib/Kolab/FreeBusy/SourceIMAP.php
Changed
@@ -146,35 +146,11 @@ } // only consider shared namespace events if user is a confirmed participant (or organizer) - if (!$read_all && $folder->get_namespace() == 'shared') { - $participant = false; - if (is_array($event['organizer']) && !empty($event['organizer']['email'])) { - $participant = in_array($event['organizer']['email'], $user_email); - } - else if (is_array($event['attendees'])) { - foreach ($event['attendees'] as $attendee) { - if (in_array($attendee['email'], $user_email)) { - if ($attendee['status'] == 'ACCEPTED') { - $participant = true; - break; - } - else if ($attendee['status'] == 'TENTATIVE') { - $event['free_busy'] = 'tentative'; - $participant = true; - break; - } - } - } - } - - if (!$participant) { - $log->debug('Skip shared event', array($event['uid'], $event['title'])); - continue; - } - } // skip declined events - else if (is_array($event['attendees']) && !$this->check_participation($event, $user_email)) { - $log->debug('Skip declined event', array($event['uid'], $event['title'])); + if (!$this->check_participation($event, $user_email, $status) + || ($status != 'ACCEPTED' && $status != 'TENTATIVE') + ) { + $log->debug('Skip shared/declined event', array($event['uid'], $event['title'])); continue; } @@ -200,7 +176,7 @@ } // copied from libvcalendar::_to_ical() - $ve = $this->to_vevent($event, $calendar); + $ve = $this->to_vevent($event, $calendar, $user_email); if ($event['recurrence']) { if ($exdates = $event['recurrence']['EXDATE']) @@ -219,8 +195,8 @@ $exdates[] = $exception['recurrence_date']; } // add exception to vcalendar container - if (!$exception['cancelled'] && $this->check_participation($exception, $user_email)) { - $vex = $this->to_vevent($exception, $calendar); + if (!$exception['cancelled'] && $this->check_participation($exception, $user_email, $status) && $status != 'DECLINED') { + $vex = $this->to_vevent($exception, $calendar, $user_email); $vex->UID = $event['uid'] . '-' . $i; $calendar->add($vex); $log->debug("Adding event exception for processing:\n" . $vex->serialize()); @@ -335,7 +311,7 @@ /** * Helper method to build a Sabre/VObject from the gieven event data */ - private function to_vevent($event, $cal) + private function to_vevent($event, $cal, $user_email) { // copied from libvcalendar::_to_ical() $ve = $cal->create('VEVENT'); @@ -349,10 +325,9 @@ if (!empty($event['free_busy'])) $ve->add('TRANSP', $event['free_busy'] == 'free' ? 'TRANSPARENT' : 'OPAQUE'); - if ($event['free_busy'] == 'tentative') - $ve->add('STATUS', 'TENTATIVE'); - else if (!empty($event['status'])) - $ve->add('STATUS', $event['status']); + if ($this->check_participation($event, $user_email, $status) && $status) { + $ve->add('STATUS', $status); + } return $ve; } @@ -360,19 +335,31 @@ /** * Helper method to check the participation status of the requested user */ - private function check_participation($event, $user_email) + private function check_participation($event, $user_email, &$status = null) { - $result = true; + if (is_array($event['organizer']) && !empty($event['organizer']['email'])) { + if (in_array($event['organizer']['email'], $user_email)) { + $status = 'ACCEPTED'; + if ($event['free_busy'] == 'tentative') { + $status = 'TENTATIVE'; + } + else if (!empty($event['status'])) { + $status = $event['status']; + } + + return true; + } + } if (is_array($event['attendees'])) { foreach ($event['attendees'] as $attendee) { - if (in_array($attendee['email'], $user_email) && $attendee['status'] == 'DECLINED') { - $result = false; - break; + if (in_array($attendee['email'], $user_email)) { + $status = $attendee['status']; + return true; } } } - return $result; + return false; } }
View file
kolab-freebusy-1.1.tar.gz/lib/Kolab/FreeBusy/Utils.php -> kolab-freebusy-1.1.0.tar.gz/lib/Kolab/FreeBusy/Utils.php
Changed
@@ -178,7 +178,7 @@ { // use date from HTTP query if (!empty($_GET['dtstart'])) { - return self::periodStartDT()->format('u'); + return self::periodStartDT()->format('U'); } // Should probably be a setting. For now, do 8 weeks in the past @@ -194,8 +194,14 @@ { // use date from HTTP query if (!empty($_GET['dtstart']) && - ($dtstart = \rcube_utils::anytodatetime(filter_input(INPUT_GET, 'dtstart', FILTER_SANITIZE_STRING)))) { - return $dtstart; + ($dtstart = filter_input(INPUT_GET, 'dtstart', FILTER_SANITIZE_STRING)) + ) { + try { + return new \DateTime($dtstart, new \DateTimezone('UTC')); + } + catch (Exception $e) { + // ignore + } } // Should probably be a setting. For now, do 8 weeks in the past @@ -211,7 +217,7 @@ { // use date from HTTP query if (!empty($_GET['dtend'])) { - return self::periodEndDT()->format('u'); + return self::periodEndDT()->format('U'); } // Should probably be a setting. For now, do 16 weeks into the future @@ -227,8 +233,14 @@ { // use date from HTTP query if (!empty($_GET['dtend']) && - ($dtend = \rcube_utils::anytodatetime(filter_input(INPUT_GET, 'dtend', FILTER_SANITIZE_STRING)))) { - return $dtend; + ($dtend = filter_input(INPUT_GET, 'dtend', FILTER_SANITIZE_STRING)) + ) { + try { + return new \DateTime($dtend, new \DateTimezone('UTC')); + } + catch (Exception $e) { + // ignore + } } // Should probably be a setting. For now, do 8 weeks in the past @@ -259,4 +271,4 @@ return $dummy; } -} \ No newline at end of file +}
View file
kolab-freebusy-1.1.tar.gz/public_html/index.php -> kolab-freebusy-1.1.0.tar.gz/public_html/index.php
Changed
@@ -74,6 +74,8 @@ #header('Content-type: text/calendar; charset=utf-8', true); header('Content-type: text/plain; charset=utf-8', true); + list($uri, $args) = explode('?', $uri); + // analyse request $url = array_filter(explode('/', $uri)); $user = strtolower(array_pop($url));
View file
kolab-freebusy.dsc
Changed
@@ -2,7 +2,7 @@ Source: kolab-freebusy Binary: kolab-freebusy Architecture: all -Version: 1.1~dev20150706-0~kolab3 +Version: 1.1.0-0~kolab1 Maintainer: Jeroen van Meeuwen <vanmeeuwen@kolabsys.com> Homepage: http://www.kolab.org Standards-Version: 3.9.3 @@ -12,5 +12,5 @@ Package-List: kolab-freebusy deb mail extra Files: - 00000000000000000000000000000000 0 kolab-freebusy-1.1.tar.gz + 00000000000000000000000000000000 0 kolab-freebusy-1.1.0.tar.gz 00000000000000000000000000000000 0 debian.tar.gz
Locations
Projects
Search
Status Monitor
Help
Open Build Service
OBS Manuals
API Documentation
OBS Portal
Reporting a Bug
Contact
Mailing List
Forums
Chat (IRC)
Twitter
Open Build Service (OBS)
is an
openSUSE project
.