Initial commit

master 0.1.0_el5
Daniel Berteaud 10 years ago
commit db0f2e62ca
  1. 1
      root/etc/e-smith/templates/var/service/qpsmtpd/config/peers/local/76drop_sogo_response
  2. 39
      root/usr/share/qpsmtpd/plugins/drop_sogo_response
  3. 43
      smeserver-qpsmtpd-oldwa.spec

@ -0,0 +1,39 @@
#!/usr/bin/perl -wT
=head1 NAME
drop_sogo_response
=head1 DESCRIPTION
Drop email if it's a SOGo response for an appointment
and set it to NEEDS-ADCTION
Work around a problem in outlook dav where invitaions status are not correctly synced
=head1 AUTHOR
Daniel Berteaud <daniel@firewall-services.com>
=head1 LICENSE
GNU GPL v2 (GNU General Public License)
=cut
sub register {
my ($self, $qp, %arg) = @_;
$self->register_hook("data_post", "drop_sogo_response");
}
sub drop_sogo_response {
my ($self, $transaction) = @_;
my $type = $transaction->header->get('X-SOGo-Message-Type') or return DECLINED;
$type =~ m/^calendar:invitation-reply$/ or return DECLINED;
my $subj = $transaction->header->get('Subject') or return DECLINED;
my $r = qr{=\?UTF-8\?q\?Sans_d=C3=A9cision};
$subj =~ m/$r/m or return DECLINED;
$self->log(LOGINFO, "SOGo response detected, droping email");
return DENY;
}

@ -0,0 +1,43 @@
%define name smeserver-qpsmtpd-oldwa
%define version 0.1.0
%define release 0.beta1
Summary: Work around for OutlookDAV
Name: %{name}
Version: %{version}
Release: %{release}%{?dist}
License: GNU GPL (GNU General Public License)
Group: Mail
Source: %{name}-%{version}.tar.gz
BuildRoot: /var/tmp/%{realname}-%{version}-buildroot/
BuildArch: noarch
Requires: smeserver-release >= 8
BuildRequires: e-smith-devtools
AutoReqProv: no
%description
Work Around a problem with OutlookDAV where invitations status are not synced correctly
with SOGo, which cause bogus meeting cancellations
%changelog
* Wed May 13 2015 Daniel Berteaud <daniel@firewall-services.com> - 0.1.0-1.sme
- initial release
%prep
%setup -q -n %{name}-%{version}
%build
%install
rm -rf $RPM_BUILD_ROOT
(cd root ; find . -depth -print | cpio -dump $RPM_BUILD_ROOT)
rm -f %{name}-%{version}-filelist
/sbin/e-smith/genfilelist $RPM_BUILD_ROOT > %{name}-%{version}-filelist
%clean
cd ..
rm -rf %{name}-%{version}
%files -f %{name}-%{version}-filelist
%defattr(-,root,root)
Loading…
Cancel
Save