[SSSD] [PATCHES] IFP: add FindByCertificate method for User objects
Sumit Bose
sbose at redhat.com
Fri Jun 19 18:14:58 UTC 2015
On Fri, Jun 19, 2015 at 06:56:49PM +0200, Jakub Hrozek wrote:
> On Thu, Jun 18, 2015 at 05:51:08PM +0200, Jakub Hrozek wrote:
> > On Thu, Jun 18, 2015 at 05:35:54PM +0200, Sumit Bose wrote:
> > > On Thu, Jun 18, 2015 at 05:09:22PM +0200, Jakub Hrozek wrote:
> > > > On Thu, Jun 18, 2015 at 09:04:48AM +0200, Pavel Březina wrote:
> > > > > >>Thank you for the review, new version attached.
> > > > > >>
> > > > > >>bye,
> > > > > >>Sumit
> > > > > >
> > > > > >
> > > > > >ACK
> > > > >
> > > > > Those patches needs to be pushed *after* cached object patches land in since
> > > > > they depend on them -- even though they can be (wrongly) applied to master.
> > > >
> > > > Sorry, but the tests don't compile for me:
> > > > /home/remote/jhrozek/devel/sssd/src/tests/sysdb-tests.c: In function ‘test_sysdb_search_user_by_cert’:
> > > > /home/remote/jhrozek/devel/sssd/src/tests/sysdb-tests.c:5218:16: error: implicit declaration of function ‘sss_base64_decode’ [-Werror=implicit-function-declaration]
> > > > val.data = sss_base64_decode(test_ctx, TEST_USER_CERT_DERB64, &val.length);
> > > > ^
> > > > /home/remote/jhrozek/devel/sssd/src/tests/sysdb-tests.c:5218:14: warning: assignment makes pointer from integer without a cast [-Wint-conversion]
> > > > val.data = sss_base64_decode(test_ctx, TEST_USER_CERT_DERB64, &val.length);
> > >
> > >
> > > not sure why I (and CI) don't see this, but
> > >
> > > diff --git a/src/tests/sysdb-tests.c b/src/tests/sysdb-tests.c
> > > index 6dd299b..522a44a 100644
> > > --- a/src/tests/sysdb-tests.c
> > > +++ b/src/tests/sysdb-tests.c
> > > @@ -27,6 +27,7 @@
> > > #include <sys/stat.h>
> > > #include <sys/types.h>
> > > #include "util/util.h"
> > > +#include "util/crypto/sss_crypto.h"
> > > #include "confdb/confdb_setup.h"
> > > #include "db/sysdb_private.h"
> > > #include "db/sysdb_services.h"
> > >
> > > should fix it. Can you try?
> >
> > Yes it does, thanks. FWIW, I'm using GCC on F-22.
> >
> > I've squashed the one-liner into "sysdb: add sysdb_search_user_by_cert()
> > and sysdb_search_object_by_cert()" and submitted the patches to CI and
> > Coverity again, just to be sure.
>
> Coverity came clean, but CI was giving me some issues with rpmbuild and
> Debian builds. The attached interdiff takes care of the problems at
> least locally. I submitted the changes to CI and would like to push the
> patches if the results are OK.
The changes make sense, please squash them in if the tests are passing.
bye,
Sumit
> diff -u b/Makefile.am b/Makefile.am
> --- b/Makefile.am
> +++ b/Makefile.am
> @@ -737,7 +737,9 @@
> $(NULL)
> libsss_cert_la_LIBADD = \
> $(CRYPTO_LIBS) \
> + $(TALLOC_LIBS) \
> libsss_crypt.la \
> + libsss_debug.la \
> $(NULL)
> libsss_cert_la_LDFLAGS = \
> -avoid-version \
> @@ -2514,14 +2516,17 @@
> $(NULL)
> test_cert_utils_CFLAGS = \
> $(AM_CFLAGS) \
> + $(CRYPTO_CFLAGS) \
> $(NULL)
> test_cert_utils_LDADD = \
> $(CMOCKA_LIBS) \
> $(POPT_LIBS) \
> $(TALLOC_LIBS) \
> + $(CRYPTO_LIBS) \
> libsss_debug.la \
> libsss_test_common.la \
> libsss_cert.la \
> + libsss_crypt.la \
> $(NULL)
> endif # HAVE_CMOCKA
>
> only in patch2:
> unchanged:
> --- a/contrib/ci/deps.sh
> +++ b/contrib/ci/deps.sh
> @@ -105,6 +105,7 @@ if [[ "$DISTRO_BRANCH" == -debian-* ]]; then
> systemd
> xml-core
> xsltproc
> + libssl-dev
> )
> DEPS_INTGCHECK_SATISFIED=false
> fi
> only in patch2:
> unchanged:
> --- a/contrib/sssd.spec.in
> +++ b/contrib/sssd.spec.in
> @@ -106,6 +106,7 @@ BuildRequires: dbus-libs
> BuildRequires: openldap-devel
> BuildRequires: pam-devel
> BuildRequires: nss-devel
> +BuildRequires: openssl-devel
> BuildRequires: nspr-devel
> BuildRequires: pcre-devel
> BuildRequires: libxslt
> @@ -691,6 +692,7 @@ rm -rf $RPM_BUILD_ROOT
> #Internal shared libraries
> %{_libdir}/%{name}/libsss_child.so
> %{_libdir}/%{name}/libsss_crypt.so
> +%{_libdir}/%{name}/libsss_cert.so
> %{_libdir}/%{name}/libsss_debug.so
> %{_libdir}/%{name}/libsss_krb5_common.so
> %{_libdir}/%{name}/libsss_ldap_common.so
> _______________________________________________
> sssd-devel mailing list
> sssd-devel at lists.fedorahosted.org
> https://lists.fedorahosted.org/mailman/listinfo/sssd-devel
More information about the sssd-devel
mailing list