Hello community,
here is the log from the commit of package perl-ldap for openSUSE:Factory
checked in at Tue Apr 6 22:40:28 CEST 2010.
--------
--- perl-ldap/perl-ldap.changes 2010-01-10 16:10:12.000000000 +0100
+++ perl-ldap/perl-ldap.changes 2010-03-24 20:50:34.000000000 +0100
@@ -1,0 +2,26 @@
+Wed Mar 24 19:36:29 UTC 2010 - rbos@opensuse.org
+
+- update to 0.40
+ * Avoid 'cookie parsing error' on OpenLDAP 2.3 [Mathieu Parent]
+ * Added e-syncRefreshRequired constant [Mathieu Parent]
+ * Minor typo fix in documentation [Quanah Gibson-Mount]
+ * Update CREDITS for Mathieu Parent
+ * Remove runtime dependency on DATA handle for constants
+ * Clarify documentation for gen_password
+ * Allow caller to pass Authen::SASL client_new object
+ * fix typo [Peter Marschall]
+ * use current IO::Socket::SSL's method start_SSL instead of deprecated function socketToSSL; raise required IO::Socket:SSL version appropriately [Peter Marschall]
+ * FilterMatch.pm: fix regex treatment in _{cis,exact}_substrings(). [Peter Marschall]
+ * FilterMatch.pm: correct # of args in function declarations/definitions [Peter Marschall]
+ * Don't duplicate documentation [Mathieu Parent]
+ * Added numcmp option to compare attributes numerically. [Kartik Subbarao]
+ * Avoid infinite loop when authenticating with EXTERNAL mechanism
+ * Add Net::LDAP::Extension::Refresh as described in RFC2589 [Etienne Bagnoud]
+ * RT#40068 Fix tests to work with 2.4.11
+ * Add ldif method to Net::LDAP::Entry
+ * RT#46111 Make LWP::Protocol::ldap return ldif when requested
+ * RT#51165 Compact multiple consecutive spaces in Net::LDAP::Util::canonical_dn
+ * RT#46125 Add LWP::Protocol::ldaps to support ldaps: urls
+ * RT#44110 Fix Net::LDAP::LDIF->current_lines
+
+-------------------------------------------------------------------
@@ -7 +33 @@
-Tue Jul 28 09:52:19 CEST 2009 - richard.bos@xs4all.nl
+Tue Jul 28 09:52:19 CEST 2009 - rbos@opensuse.org
calling whatdependson for head-i586
Old:
----
SyncRequestCookie.patch
perl-ldap-0.39.tar.bz2
New:
----
perl-ldap-0.40.tar.bz2
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ perl-ldap.spec ++++++
--- /var/tmp/diff_new_pack.hGdG6X/_old 2010-04-06 22:39:50.000000000 +0200
+++ /var/tmp/diff_new_pack.hGdG6X/_new 2010-04-06 22:39:50.000000000 +0200
@@ -1,5 +1,5 @@
#
-# spec file for package perl-ldap (Version 0.39)
+# spec file for package perl-ldap (Version 0.40)
#
# Copyright (c) 2010 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
@@ -20,8 +20,8 @@
Name: perl-ldap
BuildRequires: perl-Authen-SASL perl-Convert-ASN1 perl-IO-Socket-SSL perl-XML-Parser
-Version: 0.39
-Release: 3
+Version: 0.40
+Release: 1
Provides: perl_ldp perl-Net-LDAP = %{version}
Obsoletes: perl_ldp perl-Net-LDAP < %{version}
Requires: perl-URI perl-XML-Parser perl-Convert-ASN1
@@ -32,7 +32,6 @@
Url: http://cpan.org/modules/by-module/Net/
Summary: Client Interface for LDAP Servers
Source: perl-ldap-%{version}.tar.bz2
-Patch0: SyncRequestCookie.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%description
@@ -65,7 +64,6 @@
%prep
%setup -q -n perl-ldap-%{version}
-%patch0 -p1
%build
# Prevent rpmlint warning script-without-shebang
++++++ perl-ldap-0.39.tar.bz2 -> perl-ldap-0.40.tar.bz2 ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/perl-ldap-0.39/.gitignore new/perl-ldap-0.40/.gitignore
--- old/perl-ldap-0.39/.gitignore 2008-10-27 21:05:58.000000000 +0100
+++ new/perl-ldap-0.40/.gitignore 2010-03-12 04:00:45.000000000 +0100
@@ -3,3 +3,7 @@
_test
temp
*.bak
+.*.swp
+my.cfg
+MANIFEST
+SIGNATURE
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/perl-ldap-0.39/CREDITS new/perl-ldap-0.40/CREDITS
--- old/perl-ldap-0.39/CREDITS 2008-10-27 21:05:58.000000000 +0100
+++ new/perl-ldap-0.40/CREDITS 2010-03-11 22:21:45.000000000 +0100
@@ -13,7 +13,7 @@
---------------
To give due honor to those who have made perl-ldap what is is today, here
-are some of the people who have contributed, either in code, documentaion
+are some of the people who have contributed, either in code, documentation
or just ideas/feedback. If I have missed anyone, please let me know.
Graham Barr
@@ -35,3 +35,4 @@
Peter Marschall
Paul David Fardy
Derik Pates
+Mathieu Parent
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/perl-ldap-0.39/Changes new/perl-ldap-0.40/Changes
--- old/perl-ldap-0.39/Changes 2008-10-27 21:05:58.000000000 +0100
+++ new/perl-ldap-0.40/Changes 2010-03-12 03:57:24.000000000 +0100
@@ -1,3 +1,28 @@
+0.40 -- Thu Mar 11 20:56:28 CST 2010
+
+ * Avoid 'cookie parsing error' on OpenLDAP 2.3 [Mathieu Parent]
+ * Added e-syncRefreshRequired constant [Mathieu Parent]
+ * Minor typo fix in documentation [Quanah Gibson-Mount]
+ * Update CREDITS for Mathieu Parent
+ * Remove runtime dependency on DATA handle for constants
+ * Clarify documentation for gen_password
+ * Allow caller to pass Authen::SASL client_new object
+ * fix typo [Peter Marschall]
+ * use current IO::Socket::SSL's method start_SSL instead of deprecated function socketToSSL; raise required IO::Socket:SSL version appropriately [Peter Marschall]
+ * FilterMatch.pm: fix regex treatment in _{cis,exact}_substrings(). [Peter Marschall]
+ * FilterMatch.pm: correct # of args in function declarations/definitions [Peter Marschall]
+ * Don't duplicate documentation [Mathieu Parent]
+ * Added numcmp option to compare attributes numerically. [Kartik Subbarao]
+ * Avoid infinite loop when authenticating with EXTERNAL mechanism
+ * Add Net::LDAP::Extension::Refresh as described in RFC2589 [Etienne Bagnoud]
+ * RT#40068 Fix tests to work with 2.4.11
+ * Add ldif method to Net::LDAP::Entry
+ * RT#46111 Make LWP::Protocol::ldap return ldif when requested
+ * RT#51165 Compact multiple consecutive spaces in Net::LDAP::Util::canonical_dn
+ * RT#46125 Add LWP::Protocol::ldaps to support ldaps: urls
+ * RT#44110 Fix Net::LDAP::LDIF->current_lines
+
+
perl-ldap 0.39 -- Mon Oct 27 15:02:37 CDT 2008
==============================================
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/perl-ldap-0.39/MANIFEST new/perl-ldap-0.40/MANIFEST
--- old/perl-ldap-0.39/MANIFEST 2008-10-27 21:05:58.000000000 +0100
+++ new/perl-ldap-0.40/MANIFEST 2010-03-12 04:00:55.000000000 +0100
@@ -60,6 +60,7 @@
install-nomake
lib/Bundle/Net/LDAP.pm
lib/LWP/Protocol/ldap.pm
+lib/LWP/Protocol/ldaps.pm
lib/Net/LDAP.pm
lib/Net/LDAP.pod
lib/Net/LDAP/ASN.pm
@@ -86,6 +87,7 @@
lib/Net/LDAP/Entry.pod
lib/Net/LDAP/Examples.pod
lib/Net/LDAP/Extension.pm
+lib/Net/LDAP/Extension/Refresh.pm
lib/Net/LDAP/Extension/SetPassword.pm
lib/Net/LDAP/Extension/WhoAmI.pm
lib/Net/LDAP/Extra.pm
@@ -111,9 +113,8 @@
lib/Net/LDAPI.pm
lib/Net/LDAPS.pm
Makefile.PL
-MANIFEST
+MANIFEST This list of files
MANIFEST.SKIP
-META.yml
README
SIGNATURE
t/00ldif-entry.t
@@ -131,6 +132,7 @@
t/55ssl.t
t/56ipc.t
t/57url.t
+t/58lwp.t
t/70sortctrl.t
t/common.pl
test.cfg
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/perl-ldap-0.39/MANIFEST.SKIP new/perl-ldap-0.40/MANIFEST.SKIP
--- old/perl-ldap-0.39/MANIFEST.SKIP 2008-10-27 21:05:58.000000000 +0100
+++ new/perl-ldap-0.40/MANIFEST.SKIP 2010-03-12 03:58:49.000000000 +0100
@@ -19,6 +19,7 @@
# Avoid Module::Build generated and utility files.
\bBuild$
\b_build/
+\b_dev/
# Avoid temp and backup files.
~$
@@ -31,3 +32,6 @@
\bcover_db\b
\b_test/
\btemp/
+
+\bperl-ldap-\d.*gz$
+\bmy.cfg$
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/perl-ldap-0.39/META.yml new/perl-ldap-0.40/META.yml
--- old/perl-ldap-0.39/META.yml 2008-10-27 21:05:58.000000000 +0100
+++ new/perl-ldap-0.40/META.yml 1970-01-01 01:00:00.000000000 +0100
@@ -1,25 +0,0 @@
----
-abstract: 'LDAP client library'
-author:
- - 'Graham Barr '
-distribution_type: module
-generated_by: 'Module::Install version 0.75'
-license: perl
-meta-spec:
- url: http://module-build.sourceforge.net/META-spec-v1.3.html
- version: 1.3
-module_name: Net::LDAP
-name: perl-ldap
-no_index:
- directory:
- - inc
- - t
-requires:
- Convert::ASN1: 0.07
- perl: 5.004
-resources:
- ListArchive: http://perl.markmail.org/search/list:perl-ldap
- MailingList: http://lists.cpan.org/showlist.cgi?name=perl-ldap
- homepage: http://ldap.perl.org/
- repository: http://git.goingon.net/?p=perl-lda.git;a=summary
-version: 0.39
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/perl-ldap-0.39/Makefile.PL new/perl-ldap-0.40/Makefile.PL
--- old/perl-ldap-0.39/Makefile.PL 2008-10-27 21:05:58.000000000 +0100
+++ new/perl-ldap-0.40/Makefile.PL 2010-03-12 03:14:20.000000000 +0100
@@ -2,7 +2,7 @@
use inc::Module::Install;
-perl_version 5.004;
+perl_version 5.008;
name ('perl-ldap');
module_name ('Net::LDAP');
@@ -12,7 +12,7 @@
abstract ('LDAP client library');
resources homepage => 'http://ldap.perl.org/';
-resources repository => 'http://git.goingon.net/?p=perl-lda.git;a=summary';
+resources repository => 'http://git.goingon.net/?p=perl-ldap.git;a=summary';
resources MailingList => 'http://lists.cpan.org/showlist.cgi?name=perl-ldap';
resources ListArchive => 'http://perl.markmail.org/search/list:perl-ldap';
@@ -39,7 +39,7 @@
],
'LDAPS' => [
-default => 0,
- 'IO::Socket::SSL' => 0.81,
+ 'IO::Socket::SSL' => 0.93,
],
'Read/Write DSML files' => [
-default => 0,
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/perl-ldap-0.39/SIGNATURE new/perl-ldap-0.40/SIGNATURE
--- old/perl-ldap-0.39/SIGNATURE 2008-10-27 21:05:58.000000000 +0100
+++ new/perl-ldap-0.40/SIGNATURE 2010-03-12 04:00:58.000000000 +0100
@@ -14,14 +14,13 @@
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
-SHA1 24a5cce207ec42358c1cff40639e6dff8d7e8d6b .gitignore
-SHA1 d0b391ea67d4af1e877c4476490c95cf3f8783e6 CREDITS
-SHA1 9ef4f162ea6a8a1807778503c3119ad70a8bc6b3 Changes
+SHA1 dea95c7ba0dfc056a3bdaffcff2ea076fe031bc7 .gitignore
+SHA1 b3d7b971ea6fc7fbb96cdf4cea3d1cdf68f4d24f CREDITS
+SHA1 68ecb7fc82cf6533c7de371191e34e292265a190 Changes
SHA1 18422f27b2f17b10e9d18b4e482d7bfc95c8df86 INSTALL
-SHA1 c2bec936399190520629d3a2e25b313c471c241e MANIFEST
-SHA1 88cb906904179e0adf52007f0679a294294ea021 MANIFEST.SKIP
-SHA1 b8ced17ca37131e36ae5fbdf57a58bbd21656afb META.yml
-SHA1 7767423201733f281c8b344b2b9079b2f545af2e Makefile.PL
+SHA1 c22efbfe2c9dda6f54ea0ef8d6fac7b934bcb547 MANIFEST
+SHA1 b3370755529928e0db0a449e3b618f258b85a952 MANIFEST.SKIP
+SHA1 5d4c016d3a7ceb12df84c8bb40bbd9aadd64519a Makefile.PL
SHA1 f3b66414a0872801f3c4c38a93499d0fe48509ef README
SHA1 6c5729e4c6bb46c66fcc33dbb8231292d1c14dee TODO
SHA1 8e15e7abefa826736358685aa1115810baaa9b4a bin/ldapdelete
@@ -33,7 +32,7 @@
SHA1 1b11ae1f3e5cde0d577988fd8936c4895e0c6096 contrib/jpegDisplay.pl
SHA1 45be5e0f79345b5e55e8b1b97c25615c8b43d547 contrib/jpegLoad.pl
SHA1 848646da05eed8b27cb7d498cfb421ed1a67a5c5 contrib/ldapmodify.pl
-SHA1 ed46c80d99a70d1516dba41e396b369cad078800 contrib/ldifdiff.pl
+SHA1 7778a94013ab82173598e9a306ad9a356058502f contrib/ldifdiff.pl
SHA1 eb6932a765ae6f1ba47f75b1919dd1335cbb82f8 contrib/ldifsort.pl
SHA1 9823ffdc3c2d75d0d4af5f3c1ec60bf6e8c5e037 contrib/ldifuniq.pl
SHA1 eacb3515921f5843240603f949c83e3b1c1f725e contrib/printMembers.pl
@@ -81,12 +80,13 @@
SHA1 a3b43f30a4aa19adb8cda1ceaf5b19da0a5e1cae inc/attributes.pm
SHA1 4dde3f6e30c239c15c234309b7c32dd5a7d409a9 install-nomake
SHA1 da956a83d04192b551118b6ddffc32977cff5427 lib/Bundle/Net/LDAP.pm
-SHA1 3637699c1d2e0427a74aa5e44ef0f61a725a83f4 lib/LWP/Protocol/ldap.pm
-SHA1 635cdcfa7a5a631ba6a2b25a9d125b6cfd7f781c lib/Net/LDAP.pm
-SHA1 a4f08a76aa0da5c2c5af06207b230aff3a429c41 lib/Net/LDAP.pod
+SHA1 804cae1ef32a88a678304650084d28992bdd369f lib/LWP/Protocol/ldap.pm
+SHA1 e12371df37feae4a8c6b3d5bcc6a91df37ca47c6 lib/LWP/Protocol/ldaps.pm
+SHA1 60122649f15c02195494d280d93b97461c8c39ab lib/Net/LDAP.pm
+SHA1 b8cac35d692658f82aeb6ccda5cdb57102e0ec30 lib/Net/LDAP.pod
SHA1 1fb74f66d0ed5ba26e468d6a2b99e5eb769c2411 lib/Net/LDAP/ASN.pm
SHA1 4b1f29fd2ca60e4bf1bcf6ae8d97f56c2442eb56 lib/Net/LDAP/Bind.pm
-SHA1 8b37856e342f814ff7ad3f7906ccf9025ca54bdd lib/Net/LDAP/Constant.pm
+SHA1 4e98b81fdd2d7aebdd9c03084d6979c8e6b87aa2 lib/Net/LDAP/Constant.pm
SHA1 75265c14cc727900c1cb21aeac3dc8d09bceda8a lib/Net/LDAP/Control.pm
SHA1 ab3a966de9724b2ce4197757fec087a766bb4a09 lib/Net/LDAP/Control/EntryChange.pm
SHA1 f2db11b80336a47c8bc5a1ebeb2ad0228838275c lib/Net/LDAP/Control/ManageDsaIT.pm
@@ -98,28 +98,29 @@
SHA1 7171701e5043314e5ce026847fb42111065af2ec lib/Net/LDAP/Control/ProxyAuth.pm
SHA1 ffd5e5f5035b4aa5b3c64f018791e338a4c98372 lib/Net/LDAP/Control/Sort.pm
SHA1 9e0e84ea6eb7cefd13caa9788a3ffa24c8017d4d lib/Net/LDAP/Control/SortResult.pm
-SHA1 3ae73fb52dbeb7c2992c578c2d73181fef8fd26f lib/Net/LDAP/Control/SyncDone.pm
-SHA1 3d7933131dee9892f0aadf18becb16fa50d3a9c1 lib/Net/LDAP/Control/SyncRequest.pm
-SHA1 a140a8ec88d15a89b8d2fcda76d05e01ce8b2255 lib/Net/LDAP/Control/SyncState.pm
+SHA1 828a2dafde4bca5ebdb5dd5280181ea22a081592 lib/Net/LDAP/Control/SyncDone.pm
+SHA1 fef1796be7d311b292448ff2990679e242f8ec32 lib/Net/LDAP/Control/SyncRequest.pm
+SHA1 0ff9fb9644b127b9e4a68bbfd1ccc6955f06f2a0 lib/Net/LDAP/Control/SyncState.pm
SHA1 bccc55cb200ec061790cef7420dff28e0c15eb54 lib/Net/LDAP/Control/VLV.pm
SHA1 bb9ff3dde55d0f40d69a51db611c113abe994247 lib/Net/LDAP/Control/VLVResponse.pm
SHA1 3aa62f4c9ce94ead75f633a7fa1ced2a2bf9f4dc lib/Net/LDAP/DSML.pm
-SHA1 9bbe4edd5987aacc832b09a2d4ed043752f7ebdd lib/Net/LDAP/Entry.pm
-SHA1 19e9a756153d83d4f31cc821826f84125933a2e0 lib/Net/LDAP/Entry.pod
+SHA1 0ba2291b2abc68c9a75031ac1aef374ea462642c lib/Net/LDAP/Entry.pm
+SHA1 9c7fa51e1a6cd225b4868784ae617c000278abad lib/Net/LDAP/Entry.pod
SHA1 f9a7c3e2ad3e9398c7c142ce6e015af2a7060f17 lib/Net/LDAP/Examples.pod
SHA1 b3ad85252ac3fa97bd63149cbe1fc94302b2acea lib/Net/LDAP/Extension.pm
-SHA1 acc63277837285411078a27ed73c575316fa6717 lib/Net/LDAP/Extension/SetPassword.pm
+SHA1 82ef64eeb0d71da365610f6a7e0c9ca3fd823051 lib/Net/LDAP/Extension/Refresh.pm
+SHA1 fe62bd88b43c20da127db668aa57c82b06dc35d6 lib/Net/LDAP/Extension/SetPassword.pm
SHA1 e701488dfea2250b60bf1a5e58d556ab173f57a8 lib/Net/LDAP/Extension/WhoAmI.pm
SHA1 1d0e9a195cec05800c9ad9d4fcb2d567bf4dc116 lib/Net/LDAP/Extra.pm
SHA1 ff4ff38435edd72be15178a7afceb486a560a804 lib/Net/LDAP/FAQ.pod
SHA1 9509f50030b3609b993117ce8f9dc00231343002 lib/Net/LDAP/Filter.pm
SHA1 56ff107733bf97c57b339f78e4525719689dccac lib/Net/LDAP/Filter.pod
-SHA1 7e541bc6e29f1148f75d8f47f888c2716b57d294 lib/Net/LDAP/FilterMatch.pm
+SHA1 a8a7ca2b8b24a5eede42d198ccb4da630759dfd7 lib/Net/LDAP/FilterMatch.pm
SHA1 5cabe2f34c7aa04c301002f1af9bfc0a9c036ac8 lib/Net/LDAP/Intermediate.pm
-SHA1 ed17717ec4df7bcb432adfe203c5c4a31e25ecdb lib/Net/LDAP/Intermediate/SyncInfo.pm
-SHA1 f6208ff00d3d611c171be7d2c022fd5dd5bca4cc lib/Net/LDAP/LDIF.pm
+SHA1 fc989489663d70ee2866e4b729c820dd401685f9 lib/Net/LDAP/Intermediate/SyncInfo.pm
+SHA1 93579cdcda7da555d7fefd7f400cc662bc366cbf lib/Net/LDAP/LDIF.pm
SHA1 f7f354fb4e0f3bf13a215579b8aa0842a4768dfa lib/Net/LDAP/LDIF.pod
-SHA1 51c60e66777834451da018b7310d193a27d77278 lib/Net/LDAP/Message.pm
+SHA1 cedfa64c73c054b0170e1c8649534394cf414e5e lib/Net/LDAP/Message.pm
SHA1 6a8b2d30a43d6295de37771c2576cb66c7f10bfd lib/Net/LDAP/Message.pod
SHA1 1ae5e4d10afff9f5d6cd8262a294db331fb461d5 lib/Net/LDAP/RFC.pod
SHA1 4921a9eb85f595aaa4c5c2bf7261feae54440763 lib/Net/LDAP/Reference.pod
@@ -129,11 +130,11 @@
SHA1 205d45feba6b42d72d1013a120c7bd255e5ad663 lib/Net/LDAP/Search.pm
SHA1 15021444c87d36bbb22755766c0554ef7f633165 lib/Net/LDAP/Search.pod
SHA1 118c4b8e7f937fa5e9abe1cb2bfff9e7d8445471 lib/Net/LDAP/Security.pod
-SHA1 19892d74ed36da101a9060e0de2915ed2a4da28d lib/Net/LDAP/Util.pm
+SHA1 9087525b3764071ebec3acd71c117f508df03c0f lib/Net/LDAP/Util.pm
SHA1 06f526f6bc250ab6b9749c4fe402b2ed20b88b31 lib/Net/LDAPI.pm
SHA1 ccc12f936613216c1dd5ed191df950e9364075ac lib/Net/LDAPS.pm
-SHA1 75969973755cde2af99389a5cc654ac70d4fb89a t/00ldif-entry.t
-SHA1 4e1601ad167d1db136af53d42aaa9242099ab8d0 t/01canon_dn.t
+SHA1 17d274ba48ad661c8bb165ebbcfd3ec9c75ce49a t/00ldif-entry.t
+SHA1 d52463b2ae97da2404f0a8daad42930331c320bd t/01canon_dn.t
SHA1 67604a71b08d134734b07e9f5971bff62ad8bd46 t/02filter.t
SHA1 6afb905b4d8583a2f3dbeef2068cc953dffe7c25 t/03schema.t
SHA1 9b58a5eb0ec7b9ef4cb3c79d63704f986359b2ed t/04refloop.t
@@ -147,13 +148,14 @@
SHA1 0ca00731c9955275b80ab84539a094e361c9ba56 t/55ssl.t
SHA1 78620427839f55c27f33f32e56239f01aadcb6be t/56ipc.t
SHA1 b5f9fbf8baa8ddd9d97331037725d183ef856ae0 t/57url.t
+SHA1 65f3b6307aedc0f4e0fc787dc8d791ec49b872b8 t/58lwp.t
SHA1 a564d8de4711120f62f8dd8e472b04fe340f50c8 t/70sortctrl.t
-SHA1 6a00f8ca8ee8fd12a89e0f7304d7f09650893cfa t/common.pl
-SHA1 5fc1dc6f5ec7a7ef372585f154f3c9a6020d3134 test.cfg
+SHA1 13921ac88ca9a10a9fcc66b65c7f45ccfc1c9005 t/common.pl
+SHA1 f42fd99bb5a5a42c95423ff0b971ef2808e389f0 test.cfg
-----BEGIN PGP SIGNATURE-----
-Version: GnuPG v1.4.9 (Darwin)
+Version: GnuPG v1.4.10 (Darwin)
-iEYEARECAAYFAkkGHugACgkQR0BL4gbYw3SHSgCeIixCAdfWByO+qroI84cdsj4Y
-PYUAnixrLKXplCiv2XJH8LJqdN+VdV8F
-=cNnE
+iEYEARECAAYFAkuZrmcACgkQR0BL4gbYw3StVwCdGfMHapcWGwDdHUw8RFVJC+7I
+FAUAoJND0XB6Sd2Tld6PiapxuFl5XbXW
+=W7dG
-----END PGP SIGNATURE-----
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/perl-ldap-0.39/contrib/ldifdiff.pl new/perl-ldap-0.40/contrib/ldifdiff.pl
--- old/perl-ldap-0.39/contrib/ldifdiff.pl 2008-10-27 21:05:58.000000000 +0100
+++ new/perl-ldap-0.40/contrib/ldifdiff.pl 2010-03-11 22:21:45.000000000 +0100
@@ -1,5 +1,4 @@
#! /usr/bin/perl
-# $Id: ldifdiff.pl,v 3.7 2005/03/15 14:22:45 subbarao Exp $
=head1 NAME
@@ -13,7 +12,7 @@
=head1 SYNOPSIS
-ldifdiff.pl B<-k|--keyattr keyattr> [B<-a|--sourceattrs attr1,attr2,...>] [B<-c|--ciscmp attr1,...>] [B<--dnattrs attr1,...>] [B<--sharedattrs attr1,...>] B<sourcefile> B<targetfile>
+ldifdiff.pl B<-k|--keyattr keyattr> [B<-a|--sourceattrs attr1,attr2,...>] [B<-c|--ciscmp attr1,...>] [B<-n|--numcmp attr1,...>] [B<--dnattrs attr1,...>] [B<--sharedattrs attr1,...>] B<sourcefile> B<targetfile>
=head1 OPTIONS
@@ -36,6 +35,11 @@
(Optional) Compare values of the specified attributes case-insensitively. The
default set is: mail manager member objectclass owner uid uniqueMember
+=item B<-n|--numcmp attr1,...>
+
+(Optional) Compare values of the specified attributes numerically. The
+default set is: employeeNumber
+
=item B<--dnattrs attr1,...>
(Optional) Specifies a list of attributes to be treated as DNs when being
@@ -68,18 +72,23 @@
use strict;
my @sourceattrs;
-my (%ciscmp, %dnattrs, %sharedattrs);
+my (%ciscmp, %numcmp, %dnattrs, %sharedattrs);
my $keyattr;
GetOptions('a|sourceattrs=s' => sub { @sourceattrs = split(/,/, $_[1]) },
'c|ciscmp=s' => sub { my @a = split(/,/,lc $_[1]); @ciscmp{@a} = (1) x @a },
'dnattrs=s' => sub { my @a = split(/,/,lc $_[1]); @dnattrs{@a} = (1) x @a },
'k|keyattr=s' => \$keyattr,
+ 'n|numcmp=s' => sub { my @a = split(/,/,lc $_[1]); @numcmp{@a} = (1) x @a },
'sharedattrs=s' => sub {my @a=split(/,/,lc $_[1]);@sharedattrs{@a}=(1) x @a}
);
unless (keys %ciscmp) {
foreach (qw(mail manager member objectclass owner uid uniquemember))
{ $ciscmp{$_} = 1 }
}
+unless (keys %numcmp) {
+ foreach (qw(employeenumber))
+ { $numcmp{$_} = 1 }
+}
unless (keys %dnattrs) {
foreach (qw(manager member owner uniquemember))
{ $dnattrs{$_} = 1 }
@@ -122,9 +131,10 @@
my ($adn, $bdn) = @_;
my $cadn = canonical_dn($adn, casefold => 'lower');
my $cbdn = canonical_dn($bdn, casefold => 'lower');
- if ($ciscmp{lc rdnattr($cadn)}) { $cadn = lc($cadn), $cbdn = lc($cbdn) }
+ my $rdnattr = lc rdnattr($cadn);
+ if ($ciscmp{$rdnattr}) { $cadn = lc($cadn), $cbdn = lc($cbdn) }
- $cadn cmp $cbdn;
+ return $numcmp{$rdnattr} ? $cadn <=> $cbdn : $cadn cmp $cbdn;
}
sub cmpEntries
@@ -142,7 +152,7 @@
$aval = lc($aval);
$bval = lc($bval);
}
- return($aval cmp $bval, $dncmp);
+ return($numcmp{$keyattr} ? $aval <=> $bval : $aval cmp $bval, $dncmp);
}
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/perl-ldap-0.39/lib/LWP/Protocol/ldap.pm new/perl-ldap-0.40/lib/LWP/Protocol/ldap.pm
--- old/perl-ldap-0.39/lib/LWP/Protocol/ldap.pm 2008-10-27 21:05:58.000000000 +0100
+++ new/perl-ldap-0.40/lib/LWP/Protocol/ldap.pm 2010-03-12 03:53:16.000000000 +0100
@@ -13,7 +13,7 @@
require LWP::Protocol;
@ISA = qw(LWP::Protocol);
-$VERSION = "1.10";
+$VERSION = "1.11";
use strict;
eval {
@@ -26,7 +26,7 @@
$size = 4096 unless $size;
- LWP::Debug::trace('()');
+ LWP::Debug::trace('()') if defined &LWP::Debug::trace;
# check proxy
if (defined $proxy)
@@ -58,7 +58,8 @@
my $host = $url->host;
my $port = $url->port;
- my ($user, $password) = split(":", $url->userinfo, 2);
+ my $userinfo = $url->userinfo;
+ my ($user, $password) = defined($userinfo) ? split(":", $userinfo, 2) : ();
# Create an initial response object
my $response = new HTTP::Response &HTTP::Status::RC_OK, "Document follows";
@@ -66,14 +67,15 @@
my $ldap = new Net::LDAP($host, port => $port);
- my $mesg = $ldap->bind($user, password => $password);
+ if ($user) {
+ my $mesg = $ldap->bind($user, password => $password);
- if ($mesg->code) {
- my $res = new HTTP::Response &HTTP::Status::RC_BAD_REQUEST,
- "LDAP return code " . $ldap->code;
- $res->content_type("text/plain");
- $res->content($ldap->error);
- return $res;
+ if ($mesg->code) {
+ my $res = new HTTP::Response &HTTP::Status::RC_BAD_REQUEST, "LDAP return code " . $mesg->code;
+ $res->content_type("text/plain");
+ $res->content($mesg->error);
+ return $res;
+ }
}
my $dn = $url->dn;
@@ -81,12 +83,18 @@
my $scope = $url->scope || "base";
my $filter = $url->filter;
my @opts = (scope => $scope);
+ my %extn = $url->extensions;
+ my $format = lc($extn{'x-format'} || 'html');
+
+ if (my $accept = $request->header('Accept')) {
+ $format = 'ldif' if $accept =~ m!\btext/ldif\b!;
+ }
push @opts, "base" => $dn if $dn;
push @opts, "filter" => $filter if $filter;
push @opts, "attrs" => \@attrs if @attrs;
- $mesg = $ldap->search(@opts);
+ my $mesg = $ldap->search(@opts);
if ($mesg->code) {
my $res = new HTTP::Response &HTTP::Status::RC_BAD_REQUEST,
"LDAP return code " . $ldap->code;
@@ -94,6 +102,20 @@
$res->content($ldap->error);
return $res;
}
+ elsif ($format eq 'ldif') {
+ require Net::LDAP::LDIF;
+ open(my $fh, ">", \my $content);
+ my $ldif = Net::LDAP::LDIF->new($fh,"w", version => 1);
+ while(my $entry = $mesg->shift_entry) {
+ $ldif->write_entry($entry);
+ }
+ $ldif->done;
+ close($fh);
+ $response->header('Content-Type' => 'text/ldif');
+ $response->header('Content-Length', length($content));
+ $response = $self->collect_once($arg, $response, $content)
+ if ($method ne 'HEAD');
+ }
else {
my $content = "<head><title>Directory Search Results</title></head>\n<body>";
my $entry;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/perl-ldap-0.39/lib/LWP/Protocol/ldaps.pm new/perl-ldap-0.40/lib/LWP/Protocol/ldaps.pm
--- old/perl-ldap-0.39/lib/LWP/Protocol/ldaps.pm 1970-01-01 01:00:00.000000000 +0100
+++ new/perl-ldap-0.40/lib/LWP/Protocol/ldaps.pm 2010-03-12 03:53:04.000000000 +0100
@@ -0,0 +1,6 @@
+package LWP::Protocol::ldaps;
+
+use strict ;
+use base 'LWP::Protocol::ldap' ;
+
+1;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/perl-ldap-0.39/lib/Net/LDAP/Constant.pm new/perl-ldap-0.40/lib/Net/LDAP/Constant.pm
--- old/perl-ldap-0.39/lib/Net/LDAP/Constant.pm 2008-10-27 21:05:58.000000000 +0100
+++ new/perl-ldap-0.40/lib/Net/LDAP/Constant.pm 2010-03-12 03:53:16.000000000 +0100
@@ -1,78 +1,33 @@
-# Copyright (c) 1998-2008 Graham Barr . All rights reserved.
+# Copyright (c) 1998-2009 Graham Barr . All rights reserved.
# This program is free software; you can redistribute it and/or
# modify it under the same terms as Perl itself.
package Net::LDAP::Constant;
-$VERSION = "0.07";
+$VERSION = "0.08";
-use Carp;
+use Exporter qw(import);
-my %const;
-
-sub import {
- shift;
- my $callpkg = caller(0);
- _find(@_);
- my $oops;
- my $all = grep /:all/, @_;
- foreach my $sym ($all ? keys %const : @_) {
- if (my $sub = $const{$sym}) {
- *{$callpkg . "::$sym"} = $sub;
- }
- else {
- ++$oops;
- carp(qq["$sym" is not exported by the Net::LDAP::Constant module]);
- }
- }
- croak("Can't continue after import errors") if $oops;
-}
+my @err2name;
-sub _find {
- if (my @need = grep { ! $const{$_} } @_) {
- my %need; @need{@need} = ();
- my $all = exists $need{':all'};
- seek(DATA,0,0);
- local $/=''; # paragraph mode
- local $_;
- while(<DATA>) {
- next unless /^=item\s+(LDAP_\S+)\s+\((.*)\)/ and ($all or exists $need{$1});
- my ($name, $value) = ($1,$2);
- delete $need{$name};
- $const{$name} = sub () { $value };
- last unless keys %need;
- }
- }
- @const{@_};
+while(<DATA>) {
+ last if /^=cut/;
+ my $protocol_const = /^=head2 Protocol Constants/ ... /^=head2/;
+ next unless /^=item\s+(LDAP_\S+)\s+\((.*)\)/;
+ my ($name, $value) = ($1,$2);
+ *{$name} = sub () { $value };
+ push @EXPORT_OK, $name;
+ $err2name[$value] = $name if $protocol_const;
}
-sub AUTOLOAD {
- (my $name = $AUTOLOAD) =~ s/^.*:://;
- my $sub = _find($name) or croak("Undefined subroutine &$AUTOLOAD");
- my $val = &$sub; # Avoid prototype error caused by *$AUTOLOAD = $sub
- *$AUTOLOAD = sub { $val };
- goto &$AUTOLOAD;
-}
# These subs are really in Net::LDAP::Util, but need to access <DATA>
# so its easier for them to be here.
-my @err2name;
sub Net::LDAP::Util::ldap_error_name {
my $code = 0 + (ref($_[0]) ? $_[0]->code : $_[0]);
- unless (@err2name) {
- seek(DATA,0,0);
- local $/=''; # paragraph mode
- local $_;
- my $n = -1;
- while(<DATA>) {
- last if /^=head2/ and ++$n;
- next if $n;
- $err2name[$2] = $1 if /^=item\s+(LDAP_\S+)\s+\((\d+)\)/;
- }
- }
$err2name[$code] || sprintf("LDAP error code %d(0x%02X)",$code,$code);
}
@@ -87,6 +42,7 @@
my $n = -1;
while(<DATA>) {
last if /^=head2/ and ++$n;
+ last if /^=cut/;
next if $n;
if (/^=item\s+(LDAP_\S+)\s+\((\d+)\)/) {
last if defined $text;
@@ -437,6 +393,10 @@
The referral hop limit has been exceeded.
+=item LDAP_SYNC_REFRESH_REQUIRED (4096)
+
+Refresh Required.
+
=back
=head2 Control OIDs
@@ -586,7 +546,11 @@
=item LDAP_EXTENSION_WHO_AM_I (1.3.6.1.4.1.4203.1.11.3)
-Indicates that the server supports the "Who am I?" extension (draft-zeilenga-ldap-authzid-09)
+Indicates that the server supports the "Who am I?" extension (RFC 4532)
+
+=item LDAP_EXTENSION_REFRESH (1.3.6.1.4.1.1466.101.119.1)
+
+Indicates that the server supports the Refresh extension (RFC 2589)
=back
@@ -622,8 +586,9 @@
=head1 COPYRIGHT
-Copyright (c) 1998-2008 Graham Barr. All rights reserved. This program is
+Copyright (c) 1998-2009 Graham Barr. All rights reserved. This program is
free software; you can redistribute it and/or modify it under the same
terms as Perl itself.
=cut
+
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/perl-ldap-0.39/lib/Net/LDAP/Control/SyncDone.pm new/perl-ldap-0.40/lib/Net/LDAP/Control/SyncDone.pm
--- old/perl-ldap-0.39/lib/Net/LDAP/Control/SyncDone.pm 2008-10-27 21:05:58.000000000 +0100
+++ new/perl-ldap-0.40/lib/Net/LDAP/Control/SyncDone.pm 2010-03-12 03:53:16.000000000 +0100
@@ -67,36 +67,7 @@
=head1 SYNOPSIS
- use Net::LDAP;
- use Net::LDAP::Control::SyncRequest;
- use Net::LDAP::Constant qw(
- LDAP_SYNC_REFRESH_ONLY
- LDAP_SYNC_REFRESH_AND_PERSIST
- LDAP_SUCCESS );
-
- $ldap = Net::LDAP->new( "ldap.mydomain.eg" );
-
- $req = Net::LDAP::Control::SyncRequest->new( mode => LDAP_SYNC_REFRESH_ONLY );
- my $mesg = $ldap->search(base=> 'dc=mydomain,dc='eg',
- scope => 'sub',
- control => [ $req ],
- callback => \&searchCallback, # call for each entry
- filter => "(objectClass=*)",
- attrs => [ '*']);
- sub searchCallback {
- my $message = shift;
- my $entry = shift;
- my @controls = $message->control;
-
- if($controls[0]->isa('Net::LDAP::Control::SyncState')) {
- print "Received Sync State Control\n";
- print $entry->dn()."\n";
- print 'State: '.$controls[0]->state."\n".', entryUUID: '.$controls[0]->entryUUID.', cookie: '.$controls[0]->cookie;
- } elsif($controls[0]->isa('Net::LDAP::Control::SyncDone')) {
- print "Received Sync Done Control\n";
- print 'Cookie: '.$controls[0]->cookie.', refreshDeletes: '.$controls[0]->refreshDeletes;
- }
- }
+See LNet::LDAP::Control::SyncRequest
=head1 DESCRIPTION
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/perl-ldap-0.39/lib/Net/LDAP/Control/SyncRequest.pm new/perl-ldap-0.40/lib/Net/LDAP/Control/SyncRequest.pm
--- old/perl-ldap-0.39/lib/Net/LDAP/Control/SyncRequest.pm 2008-10-27 21:05:58.000000000 +0100
+++ new/perl-ldap-0.40/lib/Net/LDAP/Control/SyncRequest.pm 2010-03-12 03:53:16.000000000 +0100
@@ -21,7 +21,7 @@
unless (exists $self->{value}) {
$self->{asn} = {
mode => $self->{mode} || '1',
- cookie => $self->{cookie} || '',
+ cookie => $self->{cookie} || undef,
reloadHint => $self->{reloadHint} || '0',
};
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/perl-ldap-0.39/lib/Net/LDAP/Control/SyncState.pm new/perl-ldap-0.40/lib/Net/LDAP/Control/SyncState.pm
--- old/perl-ldap-0.39/lib/Net/LDAP/Control/SyncState.pm 2008-10-27 21:05:58.000000000 +0100
+++ new/perl-ldap-0.40/lib/Net/LDAP/Control/SyncState.pm 2010-03-12 03:53:16.000000000 +0100
@@ -78,36 +78,7 @@
=head1 SYNOPSIS
- use Net::LDAP;
- use Net::LDAP::Control::SyncRequest;
- use Net::LDAP::Constant qw(
- LDAP_SYNC_REFRESH_ONLY
- LDAP_SYNC_REFRESH_AND_PERSIST
- LDAP_SUCCESS );
-
- $ldap = Net::LDAP->new( "ldap.mydomain.eg" );
-
- $req = Net::LDAP::Control::SyncRequest->new( mode => LDAP_SYNC_REFRESH_ONLY );
- my $mesg = $ldap->search(base=> 'dc=mydomain,dc='eg',
- scope => 'sub',
- control => [ $req ],
- callback => \&searchCallback, # call for each entry
- filter => "(objectClass=*)",
- attrs => [ '*']);
- sub searchCallback {
- my $message = shift;
- my $entry = shift;
- my @controls = $message->control;
-
- if($controls[0]->isa('Net::LDAP::Control::SyncState')) {
- print "Received Sync State Control\n";
- print $entry->dn()."\n";
- print 'State: '.$controls[0]->state."\n".', entryUUID: '.$controls[0]->entryUUID.', cookie: '.$controls[0]->cookie;
- } elsif($controls[0]->isa('Net::LDAP::Control::SyncDone')) {
- print "Received Sync Done Control\n";
- print 'Cookie: '.$controls[0]->cookie.', refreshDeletes: '.$controls[0]->refreshDeletes;
- }
- }
+See LNet::LDAP::Control::SyncRequest
=head1 DESCRIPTION
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/perl-ldap-0.39/lib/Net/LDAP/Entry.pm new/perl-ldap-0.40/lib/Net/LDAP/Entry.pm
--- old/perl-ldap-0.39/lib/Net/LDAP/Entry.pm 2008-10-27 21:05:58.000000000 +0100
+++ new/perl-ldap-0.40/lib/Net/LDAP/Entry.pm 2010-03-12 03:53:16.000000000 +0100
@@ -290,6 +290,17 @@
return $mesg;
}
+sub ldif {
+ my $self = shift;
+ my %opt = @_;
+
+ require Net::LDAP::LDIF;
+ open(my $fh, ">", \my $buffer);
+ my $change = exists $opt{change} ? $opt{change} : $self->changes ? 1 : 0;
+ my $ldif = Net::LDAP::LDIF->new($fh, "w", change => $change);
+ $ldif->write_entry($self);
+ return $buffer;
+}
# Just for debugging
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/perl-ldap-0.39/lib/Net/LDAP/Entry.pod new/perl-ldap-0.40/lib/Net/LDAP/Entry.pod
--- old/perl-ldap-0.39/lib/Net/LDAP/Entry.pod 2008-10-27 21:05:58.000000000 +0100
+++ new/perl-ldap-0.40/lib/Net/LDAP/Entry.pod 2010-03-12 03:14:20.000000000 +0100
@@ -217,6 +217,21 @@
B<NOTE>: these changes are local to the client and will not appear on
the directory server until the C<update> method is called.
+=item ldif ( OPTION =E<gt> VALUE, ... )
+
+Returns the entry as an LDIF string. possible options
+
+=over
+
+=item change =E<gt> VALUE
+
+If given a true value then the LDIF will be generated as a change record.
+If flase, then the LDIF generated will represent the entry content. If
+unspecified then it will fefault to true if the entry has changes and
+false if no changes have been applied to the entry.
+
+=back
+
=item dump ( [ FILEHANDLE ] )
Dump the entry to the given filehandle.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/perl-ldap-0.39/lib/Net/LDAP/Extension/Refresh.pm new/perl-ldap-0.40/lib/Net/LDAP/Extension/Refresh.pm
--- old/perl-ldap-0.39/lib/Net/LDAP/Extension/Refresh.pm 1970-01-01 01:00:00.000000000 +0100
+++ new/perl-ldap-0.40/lib/Net/LDAP/Extension/Refresh.pm 2010-03-12 03:53:16.000000000 +0100
@@ -0,0 +1,120 @@
+package Net::LDAP::Extension::Refresh;
+require Net::LDAP::Extension;
+
+$VERSION = "0.01";
+@ISA = qw(Net::LDAP::Extension);
+
+use Convert::ASN1;
+
+my $refreshReq = Convert::ASN1->new;
+$refreshReq->prepare(q);
+
+my $refreshResp = Convert::ASN1->new;
+$refreshResp->prepare(q);
+
+sub Net::LDAP::refresh {
+ my $ldap = shift;
+ my %opt = @_;
+
+ my $res = $ldap->extension (
+ name => '1.3.6.1.4.1.1466.101.119.1',
+ value => $refreshReq->encode(\%opt),
+ ($opt{control} ? (control => $opt{control}) : ())
+ );
+
+ bless $res;
+}
+
+sub get_ttl {
+ my $self = shift;
+ my $out = $refreshResp->decode($self->response);
+ $out->{responseTtl};
+}
+1;
+
+__END__
+
+=head1 NAME
+
+Net::LDAP::Extension::Refresh - LDAPv3 Refresh extension object (RFC 2589)
+
+=head1 SYNOPSIS
+
+ use Net::LDAP;
+ use Net::LDAP::Extension::Refresh;
+
+ $ldap = Net::LDAP->new('localhost');
+ $ldap->bind('cn=admin,dc=example,dc=com', password => 'password');
+
+ $mesg = $ldap->refresh(entryName => 'cn=dynamic,dc=example,dc=com',
+ requestTtl => 100);
+ die "error :", $mesg->code(), ": ", $mesg->error() if($mesg->code());
+ print "TTL changed to ", $mesg->get_ttl(), "\n";
+
+=head1 DESCRIPTION
+
+CNet::LDAP::Extension::Refresh implements the C<Refresh> extended LDAPv3
+operation as described in RFC 2589
+
+It implements no object by itself but extends the LNet::LDAP object
+by another method:
+
+=head1 METHODS
+
+=over 4
+
+=item refresh ( OPTIONS )
+
+Send a refresh operation for an object.
+
+OPTIONS is a list of key/value pairs. The following keys are reconized:
+
+=over 4
+
+=item entryName
+
+This option contains the object to refresh. It must be a DN.
+
+=item requestTtl
+
+This option contains the TTL in seconds requested. The server may choose to
+set another value as stated in RFC 2589
+
+=back
+
+=item get_ttl ( )
+
+Return the TTL set by the server during the previous C<refresh> call.
+
+This method is a method of the LNet::LDAP::Message response object
+returned in reply to C in case the C call succeeded.
+
+=back
+
+=head1 SEE ALSO
+
+LNet::LDAP,
+LNet::LDAP::Extension
+
+=head1 AUTHOR
+
+Etienne Bagnoud E<lt>etienne.bagnoud@irovision.chE<gt>
+Adapted from Graham Barr LNet::LDAP::Extension::SetPassword
+Documentation adapted from Peter Marschall LNet::LDAP::Extension::SetPassword
+
+Please report any bugs, or post any suggestions, to the perl-ldap
+mailing list E<lt>perl-ldap@perl.orgE<gt>
+
+=head1 COPYRIGHT
+
+Copyright (c) 2010 Etienne Bagnoud. All rights reserved. This program is
+free software; you can redistribute it and/or modify it under the same
+terms as Perl itself.
+
+=cut
+
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/perl-ldap-0.39/lib/Net/LDAP/Extension/SetPassword.pm new/perl-ldap-0.40/lib/Net/LDAP/Extension/SetPassword.pm
--- old/perl-ldap-0.39/lib/Net/LDAP/Extension/SetPassword.pm 2008-10-27 21:05:58.000000000 +0100
+++ new/perl-ldap-0.40/lib/Net/LDAP/Extension/SetPassword.pm 2010-03-12 03:53:16.000000000 +0100
@@ -115,7 +115,9 @@
=item gen_password ( )
-Return the password generated in the previous C call.
+Return the password generated by the server in response to the
+C call when applicable. The server will not generate
+a new password if C<newpasswd> was passed to C.
This method is a method of the LNet::LDAP::Message response object
returned in reply to C in case the C
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/perl-ldap-0.39/lib/Net/LDAP/FilterMatch.pm new/perl-ldap-0.40/lib/Net/LDAP/FilterMatch.pm
--- old/perl-ldap-0.39/lib/Net/LDAP/FilterMatch.pm 2008-10-27 21:05:58.000000000 +0100
+++ new/perl-ldap-0.40/lib/Net/LDAP/FilterMatch.pm 2010-03-12 03:54:28.000000000 +0100
@@ -17,7 +17,7 @@
use Net::LDAP::Schema;
use vars qw($VERSION);
-$VERSION = '0.17';
+$VERSION = '0.18';
sub import {
shift;
@@ -37,16 +37,16 @@
sub _filterMatch($@);
-sub _cis_equalityMatch($@);
-sub _exact_equalityMatch($@);
-sub _numeric_equalityMatch($@);
-sub _cis_orderingMatch($@);
-sub _numeric_orderingMatch($@);
-sub _cis_greaterOrEqual($@);
-sub _cis_lessOrEqual($@);
-sub _cis_approxMatch($@);
-sub _cis_substrings($@);
-sub _exact_substrings($@);
+sub _cis_equalityMatch($$@);
+sub _exact_equalityMatch($$@);
+sub _numeric_equalityMatch($$@);
+sub _cis_orderingMatch($$@);
+sub _numeric_orderingMatch($$@);
+sub _cis_greaterOrEqual($$@);
+sub _cis_lessOrEqual($$@);
+sub _cis_approxMatch($$@);
+sub _cis_substrings($$@);
+sub _exact_substrings($$@);
# all known matches from the OL 2.2 schema,
*_bitStringMatch = \&_exact_equalityMatch;
@@ -168,7 +168,7 @@
return undef; # all other filters => fail with error
}
-sub _cis_equalityMatch($@)
+sub _cis_equalityMatch($$@)
{
my $assertion = shift;
my $op = shift;
@@ -176,7 +176,7 @@
return grep(/^\Q$assertion\E$/i, @_) ? 1 : 0;
}
-sub _exact_equalityMatch($@)
+sub _exact_equalityMatch($$@)
{
my $assertion = shift;
my $op = shift;
@@ -184,7 +184,7 @@
return grep(/^\Q$assertion\E$/, @_) ? 1 : 0;
}
-sub _numeric_equalityMatch($@)
+sub _numeric_equalityMatch($$@)
{
my $assertion = shift;
my $op = shift;
@@ -192,7 +192,7 @@
return grep(/^\Q$assertion\E$/, @_) ? 1 : 0;
}
-sub _cis_orderingMatch($@)
+sub _cis_orderingMatch($$@)
{
my $assertion = shift;
my $op = shift;
@@ -208,7 +208,7 @@
};
}
-sub _exact_orderingMatch($@)
+sub _exact_orderingMatch($$@)
{
my $assertion = shift;
my $op = shift;
@@ -224,7 +224,7 @@
};
}
-sub _numeric_orderingMatch($@)
+sub _numeric_orderingMatch($$@)
{
my $assertion = shift;
my $op = shift;
@@ -240,25 +240,27 @@
};
}
-sub _cis_substrings($@)
+sub _cis_substrings($$@)
{
my $regex=shift;
my $op=shift;
+
return 1 if ($regex =~ /^$/);
- return grep(/\Q$regex\E/i, @_) ? 1 : 0;
+ return grep(/$regex/i, @_) ? 1 : 0;
}
-sub _exact_substrings($@)
+sub _exact_substrings($$@)
{
my $regex=shift;
my $op=shift;
+
return 1 if ($regex =~ /^$/);
- return grep(/\Q$regex\E/, @_) ? 1 : 0;
+ return grep(/$regex/, @_) ? 1 : 0;
}
# this one is here in case we don't use schema
-sub _cis_greaterOrEqual($@)
+sub _cis_greaterOrEqual($$@)
{
my $assertion=shift;
my $op=shift;
@@ -273,7 +275,7 @@
*_cis_lessOrEqual = \&_cis_greaterOrEqual;
-sub _cis_approxMatch($@)
+sub _cis_approxMatch($$@)
{
my $assertion=shift;
my $op=shift;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/perl-ldap-0.39/lib/Net/LDAP/Intermediate/SyncInfo.pm new/perl-ldap-0.40/lib/Net/LDAP/Intermediate/SyncInfo.pm
--- old/perl-ldap-0.39/lib/Net/LDAP/Intermediate/SyncInfo.pm 2008-10-27 21:05:58.000000000 +0100
+++ new/perl-ldap-0.40/lib/Net/LDAP/Intermediate/SyncInfo.pm 2010-03-12 03:53:16.000000000 +0100
@@ -80,36 +80,7 @@
=head1 SYNOPSIS
- use Net::LDAP;
- use Net::LDAP::Control::SyncRequest;
- use Net::LDAP::Constant qw(
- LDAP_SYNC_REFRESH_ONLY
- LDAP_SYNC_REFRESH_AND_PERSIST
- LDAP_SUCCESS );
-
- $ldap = Net::LDAP->new( "ldap.mydomain.eg" );
-
- $req = Net::LDAP::Control::SyncRequest->new( mode => LDAP_SYNC_REFRESH_ONLY );
- my $mesg = $ldap->search(base=> 'dc=mydomain,dc='eg',
- scope => 'sub',
- control => [ $req ],
- callback => \&searchCallback, # call for each entry
- filter => "(objectClass=*)",
- attrs => [ '*']);
- sub searchCallback {
- my $message = shift;
- my $entry = shift;
- my @controls = $message->control;
-
- if($controls[0]->isa('Net::LDAP::Control::SyncState')) {
- print "Received Sync State Control\n";
- print $entry->dn()."\n";
- print 'State: '.$controls[0]->state."\n".', entryUUID: '.$controls[0]->entryUUID.', cookie: '.$controls[0]->cookie;
- } elsif($controls[0]->isa('Net::LDAP::Control::SyncDone')) {
- print "Received Sync Done Control\n";
- print 'Cookie: '.$controls[0]->cookie.', refreshDeletes: '.$controls[0]->refreshDeletes;
- }
- }
+See LNet::LDAP::Control::SyncRequest
=head1 DESCRIPTION
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/perl-ldap-0.39/lib/Net/LDAP/LDIF.pm new/perl-ldap-0.40/lib/Net/LDAP/LDIF.pm
--- old/perl-ldap-0.39/lib/Net/LDAP/LDIF.pm 2008-10-27 21:05:58.000000000 +0100
+++ new/perl-ldap-0.40/lib/Net/LDAP/LDIF.pm 2010-03-12 03:53:16.000000000 +0100
@@ -126,6 +126,7 @@
}
}
$self->eof(1) if (!defined($ln));
+ $self->{_current_lines} = $entry;
$entry =~ s/\r?\n //sgo; # un-wrap wrapped lines
$entry =~ s/\r?\n\t/ /sgo; # OpenLDAP extension !!!
@ldif = split(/^/, $entry);
@@ -445,6 +446,7 @@
# Canonicalizer won't fix leading spaces, colons or less-thans, which
# are special in LDIF, so we fix those up here.
$dn =~ s/^([ :<])/\\$1/;
+ $dn = "dn: $dn";
} elsif ($encode =~ /base64/i) {
require MIME::Base64;
$dn = "dn:: " . MIME::Base64::encode($dn,"");
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/perl-ldap-0.39/lib/Net/LDAP/Message.pm new/perl-ldap-0.40/lib/Net/LDAP/Message.pm
--- old/perl-ldap-0.39/lib/Net/LDAP/Message.pm 2008-10-27 21:05:58.000000000 +0100
+++ new/perl-ldap-0.40/lib/Net/LDAP/Message.pm 2010-03-12 03:53:16.000000000 +0100
@@ -210,12 +210,15 @@
}
}
- return unless $self->{ctrl_hash};
+ my $ctrl_hash = $self->{ctrl_hash}
+ or return;
- @_ ? exists $self->{ctrl_hash}{$_[0]}
- ? @{$self->{ctrl_hash}{$_[0]}}
- : ()
- : map { @$_ } values %{$self->{ctrl_hash}};
+ my @oid = @_ ? @_ : keys %$ctrl_hash;
+ my @control = map {@$_} grep $_, @{$ctrl_hash}{@oid}
+ or return;
+
+ # return a list, so in a scalar context we do not just get array length
+ return @control[0 .. $#control];
}
sub pdu { shift->{pdu} }
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/perl-ldap-0.39/lib/Net/LDAP/Util.pm new/perl-ldap-0.40/lib/Net/LDAP/Util.pm
--- old/perl-ldap-0.39/lib/Net/LDAP/Util.pm 2008-10-27 21:05:58.000000000 +0100
+++ new/perl-ldap-0.40/lib/Net/LDAP/Util.pm 2010-03-12 03:53:16.000000000 +0100
@@ -309,6 +309,8 @@
#escape leading and trailing whitespace
$val =~ s/(^\s+|\s+$)/
"\\20" x length $1/xeg;
+ #compact multiple spaces
+ $val =~ s/\s+/ /g;
}
# case fold attribute type and create return value
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/perl-ldap-0.39/lib/Net/LDAP.pm new/perl-ldap-0.40/lib/Net/LDAP.pm
--- old/perl-ldap-0.39/lib/Net/LDAP.pm 2008-10-27 21:05:58.000000000 +0100
+++ new/perl-ldap-0.40/lib/Net/LDAP.pm 2010-03-12 03:53:38.000000000 +0100
@@ -28,7 +28,7 @@
LDAP_UNAVAILABLE
);
-$VERSION = "0.39";
+$VERSION = "0.40";
@ISA = qw(Tie::StdHash Net::LDAP::Extra);
$LDAP_VERSION = 3; # default LDAP protocol version
@@ -377,17 +377,24 @@
if $ldap->{net_ldap_version} < 3;
my $sasl = $passwd;
+ my $sasl_conn;
- # If we're talking to a round-robin, the canonical name of
- # the host we are talking to might not match the name we
- # requested
- my $connected_name = $ldap->{net_ldap_socket}->peerhost;
- $connected_name ||= $ldap->{net_ldap_host};
-
- my $sasl_conn = eval {
- local($SIG{__DIE__});
- $sasl->client_new("ldap",$connected_name);
- };
+ if (ref($sasl) and $sasl->isa('Authen::SASL')) {
+
+ # If we're talking to a round-robin, the canonical name of
+ # the host we are talking to might not match the name we
+ # requested
+ my $connected_name = $ldap->{net_ldap_socket}->peerhost;
+ $connected_name ||= $ldap->{net_ldap_host};
+
+ $sasl_conn = eval {
+ local ($SIG{__DIE__});
+ $sasl->client_new("ldap", $connected_name);
+ };
+ }
+ else {
+ $sasl_conn = $sasl;
+ }
return _error($ldap, $mesg, LDAP_LOCAL_ERROR, "$@")
unless defined($sasl_conn);
@@ -405,7 +412,7 @@
$passwd = {
mechanism => $sasl_conn->mechanism,
- credentials => (length($initial) ? $initial : undef)
+ credentials => $initial,
};
# Save data, we will need it later
@@ -1024,7 +1031,7 @@
my $sock_class = ref($sock);
return $mesg
- if IO::Socket::SSL::socketToSSL($sock, {_SSL_context_init_args($arg)});
+ if IO::Socket::SSL->start_SSL($sock, {_SSL_context_init_args($arg)});
my $err = $@ || $IO::Socket::SSL::SSL_ERROR || $IO::Socket::SSL::SSL_ERROR || ''; # avoid use on once warning
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/perl-ldap-0.39/lib/Net/LDAP.pod new/perl-ldap-0.40/lib/Net/LDAP.pod
--- old/perl-ldap-0.39/lib/Net/LDAP.pod 2008-10-27 21:05:58.000000000 +0100
+++ new/perl-ldap-0.40/lib/Net/LDAP.pod 2010-03-11 22:21:45.000000000 +0100
@@ -298,7 +298,14 @@
=item sasl =E<gt> SASLOBJ
Bind using a SASL mechanism. The argument given should be a sub-class
-of LAuthen::SASL.
+of LAuthen::SASL or an LAuthen::SASL client connection by calling
+C on an LAuthen::SASL object.
+
+If passed an LAuthen::SASL object then C will be
+called to create a client connection object. The hostname passed
+by CNet::LDAP to C is the result of calling C<peerhost>
+on the socket. If this is not correct for your environment, consider
+calling C and passing the client connection object.
=back
@@ -382,7 +389,7 @@
=item deleteoldrdn =E<gt> 1
-This option should be passwd if the existing RDN is to be deleted.
+This option should be passed if the existing RDN is to be deleted.
=item newsuperior =E<gt> NEWDN
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/perl-ldap-0.39/t/00ldif-entry.t new/perl-ldap-0.40/t/00ldif-entry.t
--- old/perl-ldap-0.39/t/00ldif-entry.t 2008-10-27 21:05:58.000000000 +0100
+++ new/perl-ldap-0.40/t/00ldif-entry.t 2010-03-12 03:51:24.000000000 +0100
@@ -5,7 +5,7 @@
}
-print "1..11\n";
+print "1..16\n";
use Net::LDAP::LDIF;
@@ -17,7 +17,35 @@
my $ldif = Net::LDAP::LDIF->new($infile,"r");
-@entry = $ldif->read;
+my $entry0_ldif = <<'LDIF';
+dn: o=University of Michigan, c=US
+objectclass: top
+objectclass: organization
+objectclass: domainRelatedObject
+objectclass: quipuObject
+objectclass: quipuNonLeafObject
+l: Ann Arbor, Michigan
+st: Michigan
+streetaddress: 535 West William St.
+o: University of Michigan
+o: UMICH
+o: UM
+o: U-M
+o: U of M
+description: The University of Michigan at Ann Arbor
+postaladdress: University of Michigan $ 535 W. William St. $ Ann Arbor, MI 481
+ 09 $ USpostalcode: 48109
+telephonenumber: +1 313 764-1817
+lastmodifiedtime: 930106182800Z
+lastmodifiedby: cn=manager, o=university of michigan, c=US
+associateddomain: umich.edu
+LDIF
+
+my $e = $ldif->read_entry;
+my @lines = $ldif->current_lines;
+is(join("",@lines),$entry0_ldif,"ldif lines");
+
+my @entry = ($e, $ldif->read);
ok($ldif->version == 1, "version == 1");
@@ -28,7 +56,36 @@
ok(!compare($cmpfile2,$outfile2), $cmpfile2);
-$e = $entry[0];
+
+is($e->ldif, "\n$entry0_ldif", "ldif method");
+
+
+is($e->ldif(change => 1), <<'LDIF', "ldif method");
+
+dn: o=University of Michigan, c=US
+changetype: add
+objectclass: top
+objectclass: organization
+objectclass: domainRelatedObject
+objectclass: quipuObject
+objectclass: quipuNonLeafObject
+l: Ann Arbor, Michigan
+st: Michigan
+streetaddress: 535 West William St.
+o: University of Michigan
+o: UMICH
+o: UM
+o: U-M
+o: U of M
+description: The University of Michigan at Ann Arbor
+postaladdress: University of Michigan $ 535 W. William St. $ Ann Arbor, MI 481
+ 09 $ USpostalcode: 48109
+telephonenumber: +1 313 764-1817
+lastmodifiedtime: 930106182800Z
+lastmodifiedby: cn=manager, o=university of michigan, c=US
+associateddomain: umich.edu
+LDIF
+
$e->changetype('modify');
$e->delete('objectclass');
@@ -37,6 +94,62 @@
$e->add('first',[qw(1 2 3)], 'second',[qw(a b c)]);
$e->replace('telephonenumber' => ['911']);
+is($e->ldif, <<'LDIF',"changes ldif");
+
+dn: o=University of Michigan, c=US
+changetype: modify
+delete: objectclass
+-
+delete: o
+o: UM
+-
+add: counting
+counting: one
+counting: two
+counting: three
+-
+add: first
+first: 1
+first: 2
+first: 3
+-
+add: second
+second: a
+second: b
+second: c
+-
+replace: telephonenumber
+telephonenumber: 911
+LDIF
+
+is($e->ldif(change => 0), <<'LDIF',"changes ldif");
+
+dn: o=University of Michigan, c=US
+l: Ann Arbor, Michigan
+st: Michigan
+streetaddress: 535 West William St.
+o: University of Michigan
+o: UMICH
+o: U-M
+o: U of M
+description: The University of Michigan at Ann Arbor
+postaladdress: University of Michigan $ 535 W. William St. $ Ann Arbor, MI 481
+ 09 $ USpostalcode: 48109
+telephonenumber: 911
+lastmodifiedtime: 930106182800Z
+lastmodifiedby: cn=manager, o=university of michigan, c=US
+associateddomain: umich.edu
+counting: one
+counting: two
+counting: three
+first: 1
+first: 2
+first: 3
+second: a
+second: b
+second: c
+LDIF
+
$outfile = "$TEMPDIR/00-out3.ldif";
$cmpfile = "data/00-cmp2.ldif";
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/perl-ldap-0.39/t/01canon_dn.t new/perl-ldap-0.40/t/01canon_dn.t
--- old/perl-ldap-0.39/t/01canon_dn.t 2008-10-27 21:05:58.000000000 +0100
+++ new/perl-ldap-0.40/t/01canon_dn.t 2010-03-12 03:51:24.000000000 +0100
@@ -53,6 +53,7 @@
print +($failed ? "not ok " : "ok "),++$testno,"\n";
}
+
__DATA__
bad OU=Sales+CN=J. Smith,O=Widget Inc.,C=US,
@@ -90,7 +91,7 @@
same cn=Clif Harden+IDNumber="a0125589 ",ou=tiPerson,ou=person,o=ti,c=us
-ref CN=\20\20Graham Barr\20\20,OU=person,O=vc,C=us
+ref CN=\20\20Graham Barr\20\20,OU=person,O=vc,C=us
same Cn=" Graham Barr ",OU=person,O=vc,C=us
same cn=" Graham \20Barr\20 ",OU=person,O=vc,C=us
@@ -195,3 +196,7 @@
ref DISTINGUISHEDNAMETABLEKEY=cn\3dDSA\2c c\3dGB,CN=bilateral table,CN=DSA,C=US
same distinguishedNameTableKey=cn\=DSA\, c\=GB, cn=bilateral table, cn=DSA, c=US
+
+# RT 51165
+ref CN=tester\2c karl,OU=test,DC=example,DC=com
+same cn=tester\, karl,ou=test,dc=example,dc=com
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/perl-ldap-0.39/t/58lwp.t new/perl-ldap-0.40/t/58lwp.t
--- old/perl-ldap-0.39/t/58lwp.t 1970-01-01 01:00:00.000000000 +0100
+++ new/perl-ldap-0.40/t/58lwp.t 2010-03-12 03:51:19.000000000 +0100
@@ -0,0 +1,100 @@
+#!perl
+
+BEGIN {
+ unless (eval { require LWP::UserAgent; 1 }) {
+ print "1..0 # Skip Need LWP::UserAgent\n";
+ exit;
+ }
+ require "t/common.pl";
+ start_server();
+}
+
+
+print "1..6\n";
+
+$ldap = client();
+ok($ldap, "client");
+
+$mesg = $ldap->bind($MANAGERDN, password => $PASSWD);
+
+ok(!$mesg->code, "bind: " . $mesg->code . ": " . $mesg->error);
+
+ok(ldif_populate($ldap, "data/51-in.ldif"), "data/51-in.ldif");
+
+my $ua = LWP::UserAgent->new;
+my $res;
+
+# now search the database
+
+$res = $ua->get("ldap://${HOST}:$PORT/$BASEDN??sub?sn=jensen");
+ok($res->content =~ /2 Matches found/);
+
+my $expect = <<'LDIF';
+version: 1
+
+dn: cn=Barbara Jensen,ou=Information Technology Division,ou=People,o=Universit
+ y of Michigan,c=US
+objectClass: OpenLDAPperson
+cn: Barbara Jensen
+cn: Babs Jensen
+uid: babs
+sn: Jensen
+title: Mythical Manager, Research Systems
+postalAddress: ITD Prod Dev & Deployment $ 535 W. William St. Room 4212 $ Ann
+ Arbor, MI 48103-4943
+seeAlso: cn=All Staff,ou=Groups,o=University of Michigan,c=US
+userPassword: bjensen
+mail: bjensen@mailgw.umich.edu
+homePostalAddress: 123 Wesley $ Ann Arbor, MI 48103
+description: Mythical manager of the rsdd unix project
+drink: water
+homePhone: +1 313 555 2333
+pager: +1 313 555 3233
+facsimileTelephoneNumber: +1 313 555 2274
+telephoneNumber: +1 313 555 9022
+
+dn: cn=Bjorn Jensen,ou=Information Technology Division,ou=People,o=University
+ of Michigan,c=US
+objectClass: OpenLDAPperson
+cn: Bjorn Jensen
+cn: Biiff Jensen
+uid: bjorn
+sn: Jensen
+seeAlso: cn=All Staff,ou=Groups,o=University of Michigan,c=US
+userPassword: bjorn
+homePostalAddress: 19923 Seven Mile Rd. $ South Lyon, MI 49999
+drink: Iced Tea
+description: Hiker, biker
+title: Director, Embedded Systems
+postalAddress: Info Tech Division $ 535 W. William St. $ Ann Arbor, MI 48103
+mail: bjorn@mailgw.umich.edu
+homePhone: +1 313 555 5444
+pager: +1 313 555 4474
+facsimileTelephoneNumber: +1 313 555 2177
+telephoneNumber: +1 313 555 0355
+LDIF
+
+$res = $ua->get("ldap://${HOST}:$PORT/$BASEDN??sub?(sn=jensen)", Accept => 'text/ldif');
+is($res->content,$expect,'ldif result');
+
+$res = $ua->get("ldap://${HOST}:$PORT/$BASEDN??sub?(sn=jensen)?x-format=ldif");
+is($res->content,$expect,'ldif result');
+
+__END__
+
+# Exact searching
+$mesg = $ldap->search(base => $BASEDN, filter => 'sn=jensen');
+compare_ldif("51a",$mesg,$mesg->sorted);
+
+# Or searching
+$mesg = $ldap->search(base => $BASEDN, filter => '(|(objectclass=groupofnames)(sn=jones))');
+compare_ldif("51b",$mesg,$mesg->sorted);
+
+# And searching
+$mesg = $ldap->search(base => $BASEDN, filter => '(&(objectclass=groupofnames)(cn=A*))');
+compare_ldif("51c",$mesg,$mesg->sorted);
+
+# Not searching
+$mesg = $ldap->search(base => $BASEDN, filter => '(!(objectclass=person))');
+compare_ldif("51d",$mesg,$mesg->sorted);
+
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/perl-ldap-0.39/t/common.pl new/perl-ldap-0.40/t/common.pl
--- old/perl-ldap-0.39/t/common.pl 2008-10-27 21:05:58.000000000 +0100
+++ new/perl-ldap-0.40/t/common.pl 2010-03-12 03:14:20.000000000 +0100
@@ -14,6 +14,7 @@
$TEMPDIR = "./temp";
$SCHEMA_DIR ||= "./data";
$SLAPD_DB ||= 'ldbm';
+ $SCHEMA_CHECK = 1 unless defined $SCHEMA_CHECK;
$TESTDB = "$TEMPDIR/test-db";
$CONF = "$TEMPDIR/conf";
@@ -80,6 +81,7 @@
s/\$([A-Z]\w*)/${$1}/g;
s/^TLS/#TLS/ unless $SSL_PORT;
s/^(sasl.*)/#$1/ unless $SASL;
+ s/^schemacheck.*// unless $SCHEMA_CHECK;
print CONFO;
}
close(CONFI);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/perl-ldap-0.39/test.cfg new/perl-ldap-0.40/test.cfg
--- old/perl-ldap-0.39/test.cfg 2008-10-27 21:05:58.000000000 +0100
+++ new/perl-ldap-0.40/test.cfg 2010-03-12 03:14:20.000000000 +0100
@@ -17,6 +17,10 @@
# to your installation schema dir (eg /usr/local/etc/openldap/schema)
$SCHEMA_DIR = "";
+# for OpenLDAP 2.4.11
+# $SLAPD_DB = 'bdb'; # default is ldbm
+# $SCHEMA_CHECK = 0; # default is to check but 2.4.11 does not like it
+
$EXTERNAL_TESTS = 0;
# %sortctrl = (
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Remember to have fun...
--
To unsubscribe, e-mail: opensuse-commit+unsubscribe@opensuse.org
For additional commands, e-mail: opensuse-commit+help@opensuse.org