Hello community,
here is the log from the commit of package yast2-ldap-server for openSUSE:Factory
checked in at Sun Sep 27 00:22:33 CEST 2009.
--------
--- yast2-ldap-server/yast2-ldap-server.changes 2009-09-14 15:51:12.000000000 +0200
+++ /mounts/work_src_done/STABLE/yast2-ldap-server/yast2-ldap-server.changes 2009-09-25 15:55:22.000000000 +0200
@@ -1,0 +2,7 @@
+Fri Sep 25 13:48:52 UTC 2009 - rhafer@novell.com
+
+- Version 2.18.3
+ * Fixed crasher and improved sanity checks when adding new
+ schema elements (bnc#541819)
+
+-------------------------------------------------------------------
calling whatdependson for head-i586
Old:
----
yast2-ldap-server-2.18.2.tar.bz2
New:
----
yast2-ldap-server-2.18.3.tar.bz2
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ yast2-ldap-server.spec ++++++
--- /var/tmp/diff_new_pack.OPTcXX/_old 2009-09-27 00:22:28.000000000 +0200
+++ /var/tmp/diff_new_pack.OPTcXX/_new 2009-09-27 00:22:28.000000000 +0200
@@ -1,5 +1,5 @@
#
-# spec file for package yast2-ldap-server (Version 2.18.2)
+# spec file for package yast2-ldap-server (Version 2.18.3)
#
# Copyright (c) 2009 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
@@ -19,10 +19,10 @@
Name: yast2-ldap-server
-Version: 2.18.2
+Version: 2.18.3
Release: 1
BuildRoot: %{_tmppath}/%{name}-%{version}-build
-Source0: yast2-ldap-server-2.18.2.tar.bz2
+Source0: yast2-ldap-server-2.18.3.tar.bz2
Prefix: /usr
Group: System/YaST
License: GPL v2 or later X11/MIT
@@ -35,7 +35,7 @@
Center and during installation.
%prep
-%setup -n yast2-ldap-server-2.18.2
+%setup -n yast2-ldap-server-2.18.3
%build
%{prefix}/bin/y2tool y2autoconf
++++++ yast2-ldap-server-2.18.2.tar.bz2 -> yast2-ldap-server-2.18.3.tar.bz2 ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-ldap-server-2.18.2/VERSION new/yast2-ldap-server-2.18.3/VERSION
--- old/yast2-ldap-server-2.18.2/VERSION 2009-09-14 15:31:39.000000000 +0200
+++ new/yast2-ldap-server-2.18.3/VERSION 2009-09-25 15:00:23.000000000 +0200
@@ -1 +1 @@
-2.18.2
+2.18.3
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-ldap-server-2.18.2/configure new/yast2-ldap-server-2.18.3/configure
--- old/yast2-ldap-server-2.18.2/configure 2009-09-14 15:15:12.000000000 +0200
+++ new/yast2-ldap-server-2.18.3/configure 2009-09-25 12:20:41.000000000 +0200
@@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.63 for yast2-ldap-server 2.18.1.
+# Generated by GNU Autoconf 2.63 for yast2-ldap-server 2.18.2.
#
# Report bugs to http://bugs.opensuse.org/.
#
@@ -745,8 +745,8 @@
# Identity of this package.
PACKAGE_NAME='yast2-ldap-server'
PACKAGE_TARNAME='yast2-ldap-server'
-PACKAGE_VERSION='2.18.1'
-PACKAGE_STRING='yast2-ldap-server 2.18.1'
+PACKAGE_VERSION='2.18.2'
+PACKAGE_STRING='yast2-ldap-server 2.18.2'
PACKAGE_BUGREPORT='http://bugs.opensuse.org/'
ac_unique_file="RPMNAME"
@@ -1532,7 +1532,7 @@
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
-\`configure' configures yast2-ldap-server 2.18.1 to adapt to many kinds of systems.
+\`configure' configures yast2-ldap-server 2.18.2 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
@@ -1604,7 +1604,7 @@
if test -n "$ac_init_help"; then
case $ac_init_help in
- short | recursive ) echo "Configuration of yast2-ldap-server 2.18.1:";;
+ short | recursive ) echo "Configuration of yast2-ldap-server 2.18.2:";;
esac
cat <<\_ACEOF
@@ -1716,7 +1716,7 @@
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
-yast2-ldap-server configure 2.18.1
+yast2-ldap-server configure 2.18.2
generated by GNU Autoconf 2.63
Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
@@ -1730,7 +1730,7 @@
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
-It was created by yast2-ldap-server $as_me 2.18.1, which was
+It was created by yast2-ldap-server $as_me 2.18.2, which was
generated by GNU Autoconf 2.63. Invocation command line was
$ $0 $@
@@ -2710,7 +2710,7 @@
# Define the identity of the package.
PACKAGE='yast2-ldap-server'
- VERSION='2.18.1'
+ VERSION='2.18.2'
cat >>confdefs.h <<_ACEOF
@@ -2832,7 +2832,7 @@
-VERSION="2.18.1"
+VERSION="2.18.2"
RPMNAME="yast2-ldap-server"
MAINTAINER="Ralf Haferkamp "
@@ -17566,7 +17566,7 @@
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
-This file was extended by yast2-ldap-server $as_me 2.18.1, which was
+This file was extended by yast2-ldap-server $as_me 2.18.2, which was
generated by GNU Autoconf 2.63. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
@@ -17629,7 +17629,7 @@
_ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_version="\\
-yast2-ldap-server config.status 2.18.1
+yast2-ldap-server config.status 2.18.2
configured by $0, generated by GNU Autoconf 2.63,
with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-ldap-server-2.18.2/configure.in new/yast2-ldap-server-2.18.3/configure.in
--- old/yast2-ldap-server-2.18.2/configure.in 2009-09-14 15:15:02.000000000 +0200
+++ new/yast2-ldap-server-2.18.3/configure.in 2009-09-25 12:20:33.000000000 +0200
@@ -3,7 +3,7 @@
dnl -- This file is generated by y2autoconf 2.18.10 - DO NOT EDIT! --
dnl (edit configure.in.in instead)
-AC_INIT(yast2-ldap-server, 2.18.1, http://bugs.opensuse.org/, yast2-ldap-server)
+AC_INIT(yast2-ldap-server, 2.18.2, http://bugs.opensuse.org/, yast2-ldap-server)
dnl Check for presence of file 'RPMNAME'
AC_CONFIG_SRCDIR([RPMNAME])
@@ -18,7 +18,7 @@
AM_INIT_AUTOMAKE(tar-ustar -Wno-portability)
dnl Important YaST2 variables
-VERSION="2.18.1"
+VERSION="2.18.2"
RPMNAME="yast2-ldap-server"
MAINTAINER="Ralf Haferkamp "
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-ldap-server-2.18.2/src/lib/slapd-config.cpp new/yast2-ldap-server-2.18.3/src/lib/slapd-config.cpp
--- old/yast2-ldap-server-2.18.2/src/lib/slapd-config.cpp 2009-04-29 15:47:59.000000000 +0200
+++ new/yast2-ldap-server-2.18.3/src/lib/slapd-config.cpp 2009-09-25 14:59:39.000000000 +0200
@@ -5,7 +5,7 @@
*
* Author: Ralf Haferkamp
*
- * $Id: slapd-config.cpp 57029 2009-04-29 11:04:19Z lslezak $
+ * $Id: slapd-config.cpp 58780 2009-09-25 12:59:49Z rhafer $
*/
#include
@@ -1253,6 +1253,8 @@
tls.applySettings( *this );
}
+const std::string OlcSchemaConfig::schemabase = "cn=schema,cn=config";
+
OlcSchemaConfig::OlcSchemaConfig() : OlcConfigEntry()
{
m_dbEntryChanged.setDN("cn=schema,cn=config");
@@ -1264,21 +1266,44 @@
{
log_it(SLAPD_LOG_INFO, "OlcSchemaConfig::OlcSchemaConfig(const LDAPEntry &e) : OlcConfigEntry(e)");
std::string name(this->getStringValue("cn"));
- if ( name[0] == '{' )
+ std::string dn(e.getDN() );
+ if ( name.empty() )
{
- std::string::size_type pos = name.find('}');
- std::istringstream indexstr(name.substr(1, pos-1));
- indexstr >> entryIndex;
- m_name = name.substr( pos+1, std::string::npos );
- } else {
- m_name = name;
- entryIndex = 0;
+ throw std::runtime_error( "Entry '" + dn + "' has no 'cn' Attribute." );
+ }
+ if ( (dn.size() < schemabase.size()) ||
+ (dn.compare( dn.size()-schemabase.size(), schemabase.size(), schemabase )) )
+ {
+ throw std::runtime_error( "Entry '" + dn + "' is not a child of '" + schemabase + "'." );
}
+ if ( this->getStringValues("olcobjectclasses").empty() &&
+ this->getStringValues("olcattributetypes").empty() )
+ {
+ throw std::runtime_error( "Entry '" + dn + "' does not define any objectclasses or attributetypes." );
+ }
+
+ entryIndex = splitIndexFromString( name, m_name );
}
OlcSchemaConfig::OlcSchemaConfig(const LDAPEntry &e1, const LDAPEntry &e2) : OlcConfigEntry(e1, e2)
{
- log_it(SLAPD_LOG_INFO, "OlcSchemaConfig::OlcSchemaConfig(const LDAPEntry &e) : OlcConfigEntry(e)");
+ log_it(SLAPD_LOG_INFO, "OlcSchemaConfig::OlcSchemaConfig(const LDAPEntry &e1, const LDAPEntry &e2) : OlcConfigEntry(e1, e2)" );
std::string name(this->getStringValue("cn"));
+ std::string dn(e2.getDN() );
+ if ( name.empty() )
+ {
+ throw std::runtime_error( "Entry '" + dn + "' has no 'cn' Attribute." );
+ }
+ if ( (dn.size() < schemabase.size()) ||
+ (dn.compare( dn.size()-schemabase.size(), schemabase.size(), schemabase )) )
+ {
+ throw std::runtime_error( "Entry '" + dn + "' is not a child of '" + schemabase + "'." );
+ }
+ if ( this->getStringValues("olcobjectclasses").empty() &&
+ this->getStringValues("olcattributetypes").empty() )
+ {
+ throw std::runtime_error( "Entry '" + dn + "' does not define any objectclasses or attributetypes." );
+ }
+
entryIndex = splitIndexFromString( name, m_name );
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-ldap-server-2.18.2/src/lib/slapd-config.h new/yast2-ldap-server-2.18.3/src/lib/slapd-config.h
--- old/yast2-ldap-server-2.18.2/src/lib/slapd-config.h 2009-05-11 14:18:54.000000000 +0200
+++ new/yast2-ldap-server-2.18.3/src/lib/slapd-config.h 2009-09-25 14:48:52.000000000 +0200
@@ -5,7 +5,7 @@
*
* Author: Ralf Haferkamp
*
- * $Id: slapd-config.h 57115 2009-05-11 12:18:52Z rhafer $
+ * $Id: slapd-config.h 58775 2009-09-25 12:49:02Z rhafer $
*
*/
@@ -292,6 +292,7 @@
virtual void clearChangedEntry();
const std::string& getName() const;
const std::vector<LDAPAttrType> getAttributeTypes() const;
+ static const std::string schemabase;
protected:
virtual void updateEntryDn( bool origEntry = false);
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Remember to have fun...
--
To unsubscribe, e-mail: opensuse-commit+unsubscribe@opensuse.org
For additional commands, e-mail: opensuse-commit+help@opensuse.org