rebuilt with current openssl and shared library [release 2007f-2mamba;Thu May 28 2020]
This commit is contained in:
parent
c0f1e158b8
commit
7098b4b7ac
@ -1,4 +1,5 @@
|
|||||||
# libimap-c-client
|
# libimap-c-client
|
||||||
|
|
||||||
University of Washington IMAP client library.
|
University of Washington IMAP client library.
|
||||||
|
This package contains the shared libraries.
|
||||||
|
|
||||||
|
58
libimap-c-client-2007f-libopenssl-1.1.patch
Normal file
58
libimap-c-client-2007f-libopenssl-1.1.patch
Normal file
@ -0,0 +1,58 @@
|
|||||||
|
Description: Support OpenSSL 1.1
|
||||||
|
When building with OpenSSL 1.1 and newer, use the new built-in
|
||||||
|
hostname verification instead of code that doesn't compile due to
|
||||||
|
structs having been made opaque.
|
||||||
|
Bug-Debian: https://bugs.debian.org/828589
|
||||||
|
|
||||||
|
--- a/src/osdep/unix/ssl_unix.c
|
||||||
|
+++ b/src/osdep/unix/ssl_unix.c
|
||||||
|
@@ -227,8 +227,16 @@ static char *ssl_start_work (SSLSTREAM *
|
||||||
|
/* disable certificate validation? */
|
||||||
|
if (flags & NET_NOVALIDATECERT)
|
||||||
|
SSL_CTX_set_verify (stream->context,SSL_VERIFY_NONE,NIL);
|
||||||
|
- else SSL_CTX_set_verify (stream->context,SSL_VERIFY_PEER,ssl_open_verify);
|
||||||
|
+ else {
|
||||||
|
+#if OPENSSL_VERSION_NUMBER >= 0x10100000
|
||||||
|
+ X509_VERIFY_PARAM *param = SSL_CTX_get0_param(stream->context);
|
||||||
|
+ X509_VERIFY_PARAM_set_hostflags(param, X509_CHECK_FLAG_NO_PARTIAL_WILDCARDS);
|
||||||
|
+ X509_VERIFY_PARAM_set1_host(param, host, 0);
|
||||||
|
+#endif
|
||||||
|
+
|
||||||
|
+ SSL_CTX_set_verify (stream->context,SSL_VERIFY_PEER,ssl_open_verify);
|
||||||
|
/* set default paths to CAs... */
|
||||||
|
+ }
|
||||||
|
SSL_CTX_set_default_verify_paths (stream->context);
|
||||||
|
/* ...unless a non-standard path desired */
|
||||||
|
if (s = (char *) mail_parameters (NIL,GET_SSLCAPATH,NIL))
|
||||||
|
@@ -266,6 +274,7 @@ static char *ssl_start_work (SSLSTREAM *
|
||||||
|
if (SSL_write (stream->con,"",0) < 0)
|
||||||
|
return ssl_last_error ? ssl_last_error : "SSL negotiation failed";
|
||||||
|
/* need to validate host names? */
|
||||||
|
+#if OPENSSL_VERSION_NUMBER < 0x10100000
|
||||||
|
if (!(flags & NET_NOVALIDATECERT) &&
|
||||||
|
(err = ssl_validate_cert (cert = SSL_get_peer_certificate (stream->con),
|
||||||
|
host))) {
|
||||||
|
@@ -275,6 +284,7 @@ static char *ssl_start_work (SSLSTREAM *
|
||||||
|
sprintf (tmp,"*%.128s: %.255s",err,cert ? cert->name : "???");
|
||||||
|
return ssl_last_error = cpystr (tmp);
|
||||||
|
}
|
||||||
|
+#endif
|
||||||
|
return NIL;
|
||||||
|
}
|
||||||
|
|
||||||
|
@@ -313,6 +323,7 @@ static int ssl_open_verify (int ok,X509_
|
||||||
|
* Returns: NIL if validated, else string of error message
|
||||||
|
*/
|
||||||
|
|
||||||
|
+#if OPENSSL_VERSION_NUMBER < 0x10100000
|
||||||
|
static char *ssl_validate_cert (X509 *cert,char *host)
|
||||||
|
{
|
||||||
|
int i,n;
|
||||||
|
@@ -342,6 +353,7 @@ static char *ssl_validate_cert (X509 *ce
|
||||||
|
else ret = "Unable to locate common name in certificate";
|
||||||
|
return ret;
|
||||||
|
}
|
||||||
|
+#endif
|
||||||
|
|
||||||
|
/* Case-independent wildcard pattern match
|
||||||
|
* Accepts: base string
|
13
libimap-c-client-2007f-shared-library.patch
Normal file
13
libimap-c-client-2007f-shared-library.patch
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
diff -r 7c3e6c6ef2ba src/osdep/unix/Makefile
|
||||||
|
--- a/src/osdep/unix/Makefile Thu Feb 21 18:51:32 2008 +0100
|
||||||
|
+++ b/src/osdep/unix/Makefile Thu Feb 21 18:53:15 2008 +0100
|
||||||
|
@@ -962,6 +962,9 @@ onceenv:
|
||||||
|
-DRSHPATH=\"$(RSHPATH)\" -DLOCKPGM=\"$(LOCKPGM)\" > OSCFLAGS
|
||||||
|
echo $(BASELDFLAGS) $(EXTRALDFLAGS) > LDFLAGS
|
||||||
|
echo "$(ARRC) $(ARCHIVE) $(BINARIES);$(RANLIB) $(ARCHIVE)" > ARCHIVE
|
||||||
|
+ echo "`$(CAT) CCTYPE` `$(CAT) CFLAGS` `$(CAT) OSFLAGS` -shared \
|
||||||
|
+ -Wl,-soname,libc-client.so.1 -o libc-client.so.1.0.0 $(BINARIES)" \
|
||||||
|
+ >> ARCHIVE
|
||||||
|
echo $(OS) > OSTYPE
|
||||||
|
./drivers $(EXTRADRIVERS) $(DEFAULTDRIVERS) dummy
|
||||||
|
./mkauths $(EXTRAAUTHENTICATORS) $(DEFAULTAUTHENTICATORS)
|
@ -1,6 +1,6 @@
|
|||||||
Name: libimap-c-client
|
Name: libimap-c-client
|
||||||
Version: 2007f
|
Version: 2007f
|
||||||
Release: 1mamba
|
Release: 2mamba
|
||||||
Summary: University of Washington IMAP client library
|
Summary: University of Washington IMAP client library
|
||||||
Group: Network/Libraries
|
Group: Network/Libraries
|
||||||
Vendor: openmamba
|
Vendor: openmamba
|
||||||
@ -8,52 +8,123 @@ Distribution: openmamba
|
|||||||
Packager: Silvan Calarco <silvan.calarco@mambasoft.it>
|
Packager: Silvan Calarco <silvan.calarco@mambasoft.it>
|
||||||
URL: http://www.washington.edu/imap/
|
URL: http://www.washington.edu/imap/
|
||||||
Source: ftp://ftp.cac.washington.edu/imap/imap-%{version}.tar.gz
|
Source: ftp://ftp.cac.washington.edu/imap/imap-%{version}.tar.gz
|
||||||
|
Patch0: libimap-c-client-2007f-libopenssl-1.1.patch
|
||||||
|
Patch1: libimap-c-client-2007f-shared-library.patch
|
||||||
License: Free-Fork License
|
License: Free-Fork License
|
||||||
Requires: libopenssl-devel >= 0.9.7b
|
## AUTOBUILDREQ-BEGIN
|
||||||
|
BuildRequires: glibc-devel
|
||||||
|
BuildRequires: ldconfig
|
||||||
|
BuildRequires: libe2fs-devel
|
||||||
|
BuildRequires: libkrb5-devel
|
||||||
|
BuildRequires: libopenssl-devel
|
||||||
|
BuildRequires: libpam-devel
|
||||||
|
## AUTOBUILDREQ-END
|
||||||
|
BuildRequires: libopenssl-devel >= 1.1.1.g
|
||||||
BuildRoot: %{_tmppath}/%{name}-%{version}-root
|
BuildRoot: %{_tmppath}/%{name}-%{version}-root
|
||||||
|
|
||||||
%description
|
%description
|
||||||
University of Washington IMAP client library.
|
University of Washington IMAP client library.
|
||||||
|
This package contains the shared libraries.
|
||||||
|
|
||||||
|
%package -n imap
|
||||||
|
Summary: Imap C-Client
|
||||||
|
Group: Applications/Networking
|
||||||
|
Requires: %{name} = %{?epoch:%epoch:}%{version}-%{release}
|
||||||
|
|
||||||
|
%description -n imap
|
||||||
|
University of Washington IMAP client library.
|
||||||
|
|
||||||
%package devel
|
%package devel
|
||||||
Summary: Development package of %{name}
|
Summary: Development package of %{name}
|
||||||
Group: Development/Libraries
|
Group: Development/Libraries
|
||||||
|
Requires: %{name} = %{?epoch:%epoch:}%{version}-%{release}
|
||||||
|
|
||||||
%description devel
|
%description devel
|
||||||
University of Washington IMAP client library.
|
University of Washington IMAP client library.
|
||||||
|
This package contains static libraries and header files needed for development.
|
||||||
|
|
||||||
This package contains static libraries and header files need for development.
|
%debug_package
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q -n imap-%{version}
|
%setup -q -n imap-%{version}
|
||||||
|
%patch0 -p1
|
||||||
|
%patch1 -p1
|
||||||
|
|
||||||
|
sed \
|
||||||
|
-e "s:-g -fno-omit-frame-pointer -O6:\${optflags}:" \
|
||||||
|
-e "s:SSLDIR=/usr/local/ssl:SSLDIR=%{_prefix}:" \
|
||||||
|
-e "s:SSLCERTS=\$(SSLDIR)/certs:SSLCERTS=/etc/ssl/certs:" \
|
||||||
|
-i src/osdep/unix/Makefile
|
||||||
|
|
||||||
%build
|
%build
|
||||||
make slx SSLDIR=%{_prefix} GCCOPTLEVEL="%{optflags}"
|
#make slx SSLDIR=%{_prefix} GCCOPTLEVEL="%{optflags}"
|
||||||
|
|
||||||
|
echo "y" | make lnp \
|
||||||
|
EXTRAAUTHENTICATORS=gss \
|
||||||
|
PASSWDTYPE=pam \
|
||||||
|
SPECIALAUTHENTICATORS=ssl \
|
||||||
|
SSLTYPE=unix \
|
||||||
|
EXTRACFLAGS="${optflags} -fPIC -lgssapi_krb5 -lkrb5 -lk5crypto -lcom_err -lpam"
|
||||||
|
|
||||||
|
#\
|
||||||
|
# EXTRALDFLAGS="${LDFLAGS}"
|
||||||
|
|
||||||
%install
|
%install
|
||||||
[ "%{buildroot}" != "/" ] && rm -rf "%{buildroot}"
|
[ "%{buildroot}" != "/" ] && rm -rf "%{buildroot}"
|
||||||
|
|
||||||
install -d %{buildroot}%{_libdir}/imap-%{version}/{%{_lib},include}
|
# server
|
||||||
install -m 644 c-client/*.h \
|
install -d %{buildroot}%{_bindir}
|
||||||
%{buildroot}%{_libdir}/imap-%{version}/include
|
install -D -m755 imapd/imapd %{buildroot}%{_bindir}/imapd
|
||||||
install -m 644 c-client/*.c \
|
install -D -m755 ipopd/ipop2d %{buildroot}%{_bindir}/ipop2d
|
||||||
%{buildroot}%{_libdir}/imap-%{version}/%{_lib}
|
install -D -m755 ipopd/ipop3d %{buildroot}%{_bindir}/ipop3d
|
||||||
install -m 644 c-client/*.a \
|
|
||||||
%{buildroot}%{_libdir}/imap-%{version}/%{_lib}
|
|
||||||
|
|
||||||
ln -sf imap-%{version} %{buildroot}%{_libdir}/imap
|
## install xinetd.d configs
|
||||||
ln -sf c-client.a %{buildroot}%{_libdir}/imap-%{version}/%{_lib}/libc-client.a
|
#install -D -m644 ../imap $pkgdir/etc/xinetd.d/imap
|
||||||
|
#install -D -m644 ../ipop2 $pkgdir/etc/xinetd.d/ipop2
|
||||||
|
#install -D -m644 ../ipop3 $pkgdir/etc/xinetd.d/ipop3
|
||||||
|
|
||||||
|
# lib
|
||||||
|
install -d %{buildroot}%{_includedir}/imap
|
||||||
|
|
||||||
|
install -m 644 c-client/*.h \
|
||||||
|
%{buildroot}%{_includedir}/imap
|
||||||
|
|
||||||
|
install -D -m 644 c-client/c-client.a \
|
||||||
|
%{buildroot}%{_libdir}/c-client.a
|
||||||
|
ln -sf c-client.a %{buildroot}%{_libdir}/libc-client.a
|
||||||
|
|
||||||
|
install -D -m755 c-client/libc-client.so.1.0.0 %{buildroot}%{_libdir}/libc-client.so.1.0.0
|
||||||
|
ln -sf %{_libdir}/libc-client.so.1.0.0 %{buildroot}%{_libdir}/libc-client.so.1
|
||||||
|
ln -sf %{_libdir}/libc-client.so.1.0.0 %{buildroot}%{_libdir}/libc-client.so
|
||||||
|
|
||||||
|
%post -p /sbin/ldconfig
|
||||||
|
%postun -p /sbin/ldconfig
|
||||||
|
|
||||||
%clean
|
%clean
|
||||||
[ "%{buildroot}" != "/" ] && rm -rf "%{buildroot}"
|
[ "%{buildroot}" != "/" ] && rm -rf "%{buildroot}"
|
||||||
|
|
||||||
|
%files
|
||||||
|
%defattr(-,root,root)
|
||||||
|
%{_libdir}/libc-client.so.*
|
||||||
|
|
||||||
%files devel
|
%files devel
|
||||||
%defattr(-,root,root)
|
%defattr(-,root,root)
|
||||||
%dir %{_libdir}/imap-%{version}/
|
%dir %{_includedir}/imap
|
||||||
%{_libdir}/imap-%{version}/*
|
%{_includedir}/imap/*.h
|
||||||
%{_libdir}/imap
|
%{_libdir}/libc-client.so
|
||||||
|
%{_libdir}/c-client.a
|
||||||
|
%{_libdir}/libc-client.a
|
||||||
|
|
||||||
|
%files -n imap
|
||||||
|
%defattr(-,root,root)
|
||||||
|
%{_bindir}/imapd
|
||||||
|
%{_bindir}/ipop2d
|
||||||
|
%{_bindir}/ipop3d
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Thu May 28 2020 Silvan Calarco <silvan.calarco@mambasoft.it> 2007f-2mamba
|
||||||
|
- rebuilt with current openssl and shared library
|
||||||
|
|
||||||
* Wed Jul 11 2012 Automatic Build System <autodist@mambasoft.it> 2007f-1mamba
|
* Wed Jul 11 2012 Automatic Build System <autodist@mambasoft.it> 2007f-1mamba
|
||||||
- automatic version update by autodist
|
- automatic version update by autodist
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user