Permalink
Browse files

*** empty log message ***

  • Loading branch information...
1 parent 6d8186b commit d041411b33036ceb643d50da68e222ee6079198c @gbarr gbarr committed Sep 12, 2000
View
@@ -1,3 +1,58 @@
+Change 597 on 2000/09/12 by <gbarr@pobox.com> (Graham Barr)
+
+ Release 0.21
+
+Change 596 on 2000/09/12 by <gbarr@pobox.com> (Graham Barr)
+
+ FAQ updates from Clif Harden
+
+Change 595 on 2000/09/11 by <gbarr@pobox.com> (Graham Barr)
+
+ Net::LDAP::ASN
+ - Add missing context tags to sort control
+
+Change 594 on 2000/09/11 by <gbarr@pobox.com> (Graham Barr)
+
+ Examples.pod
+ - Patch from Clif Harden
+
+Change 593 on 2000/09/08 by <gbarr@pobox.com> (Graham Barr)
+
+ Net::LDAP::Entry
+ - Document that the CLIENT is not optional to ->update and that
+ ->update cannot be used to change the RDN.
+ - Handle the case when ->update is called an there are no changes
+ to be made,
+
+Change 592 on 2000/09/08 by <gbarr@pobox.com> (Graham Barr)
+
+ New FAQ from Clif Harden
+
+Change 591 on 2000/09/08 by <gbarr@pobox.com> (Graham Barr)
+
+ Net::LDAP::Entry
+ - revert ->get back to 0.19 semantics
+
+Change 590 on 2000/09/08 by <gbarr@pobox.com> (Graham Barr)
+
+ Net::LDAP
+ - Fix ->modify to allow single values to be passed without []
+
+Change 570 on 2000/08/20 by <gbarr@pobox.com> (Graham Barr)
+
+ Net::LDAP::Control::Sort
+ - Doc updates
+
+Change 569 on 2000/08/20 by <gbarr@pobox.com> (Graham Barr)
+
+ Net::LDAP::Util
+ - Added ldap_error_desc() for short error descriptions
+
+ Net::LDAP::Message
+ - Changed ->error() to use ldap_error_desc if the server did not return
+ a message.
+ - Added ->server_error() to return the server error message or undef.
+
Change 568 on 2000/08/16 by <gbarr@pobox.com> (Graham Barr)
Net::LDAP::Schema
View
@@ -1,3 +1,12 @@
+perl-ldap 0.21 September 12 2000
+================================
+
+* Change ->get back to return what 0.19 returned
+* Depricate ->get in favor of ->get_value
+* Net::LDAP::Schema now supports matchingRules
+* Added experimental onerror option to ->new
+* New FAQ by Clif Harden
+
perl-ldap 0.20 August 3 2000
============================
View
@@ -22,7 +22,7 @@ use Net::LDAP::Constant qw(LDAP_SUCCESS
LDAP_INAPPROPRIATE_AUTH
);
-$VERSION = 0.20_03;
+$VERSION = 0.21;
$LDAP_VERSION = 2; # default LDAP protocol version
@@ -59,14 +59,9 @@ sub _dn_options {
sub _err_msg {
my $mesg = shift;
- my $errstr = $mesg->error;
- unless ($errstr) {
- require Net::LDAP::Util;
- $errstr = Net::LDAP::Util::ldap_error_name($mesg->code);
- }
- my $dn = $mesg->dn || '';
- $errstr = "$dn: $errstr" if $dn;
- $errstr;
+ my $errstr = $mesg->dn || '';
+ $errstr .= ": " if $errstr;
+ $errstr . $mesg->error;
}
my %onerror = (
@@ -81,8 +76,8 @@ my %onerror = (
sub _error {
my ($ldap, $mesg) = splice(@_,0,2);
- $mesg->set_error($ldap, @_);
- $ldap->{net_ldap_onerror} and !$ldap->{net_ldap_async}
+ $mesg->set_error(@_);
+ $ldap->{net_ldap_onerror} && !$ldap->{net_ldap_async}
? scalar &{$ldap->{net_ldap_onerror}}($mesg)
: $mesg;
}
@@ -352,7 +347,7 @@ sub modify {
operation => $opcode,
modification => {
type => $chg->[$i],
- vals => $chg->[$i+1]
+ vals => ref($chg->[$i+1]) ? $chg->[$i+1] : [$chg->[$i+1]]
}
};
$i += 2;
View
@@ -1,4 +1,4 @@
-# $Id: ASN.pm,v 1.2 2000/06/29 06:07:52 gbarr Exp $
+# $Id: ASN.pm,v 1.3 2000/09/12 09:17:09 gbarr Exp $
package Net::LDAP::ASN;
@@ -322,8 +322,8 @@ $asn->prepare(<<LDAP_ASN) or die $asn->error;
SortRequestDummy ::= SEQUENCE {
order SEQUENCE OF SEQUENCE {
type OCTET STRING,
- orderingRule OCTET STRING OPTIONAL,
- reverseOrder BOOLEAN OPTIONAL } }
+ orderingRule [0] OCTET STRING OPTIONAL,
+ reverseOrder [1] BOOLEAN OPTIONAL } }
SortRequest ::= COMPONENTS OF SortRequestDummy
@@ -1,4 +1,4 @@
-# $Id: Sort.pm,v 1.4 2000/07/30 21:03:50 gbarr Exp $
+# $Id: Sort.pm,v 1.5 2000/09/12 09:17:09 gbarr Exp $
# Copyright (c) 1999-2000 Graham Barr <gbarr@pobox.com>. All rights reserved.
# This program is free software; you can redistribute it and/or
# modify it under the same terms as Perl itself.
@@ -112,7 +112,7 @@ __END__
=head1 NAME
-Net::LDAP::Control::Sort - LDAPv3 sort control object
+Net::LDAP::Control::Sort - Server Side Sort (SSS) control object
=head1 SYNOPSIS
@@ -131,11 +131,14 @@ Net::LDAP::Control::Sort - LDAPv3 sort control object
=head1 DESCRIPTION
-C<Net::LDAP::Control::Sort> is a sub-class of L<Net::LDAP::Control|Net::LDAP::Control>.
-It provides a class for manipulating the LDAP sort request control C<1.2.840.113556.1.4.473>
+C<Net::LDAP::Control::Sort> is a sub-class of
+L<Net::LDAP::Control|Net::LDAP::Control>. It provides a class
+for manipulating the LDAP Server Side Sort (SSS) request control
+C<1.2.840.113556.1.4.473> as defined in RFC-2891
-If the server supports sorting, then the response from a search operation will
-include a sort result control. This control is handled by L<Net::LDAP::Control::SortResult>.
+If the server supports sorting, then the response from a search
+operation will include a sort result control. This control is handled
+by L<Net::LDAP::Control::SortResult|Net::LDAP::Control::SortResult>.
=head1 CONSTRUCTOR ARGUMENTS
@@ -179,7 +182,8 @@ and set a new value for the attribute if called with an argument.
L<Net::LDAP|Net::LDAP>,
L<Net::LDAP::Control::SortResult|Net::LDAP::Control::SortResult>,
-L<Net::LDAP::Control|Net::LDAP::Control>
+L<Net::LDAP::Control|Net::LDAP::Control>,
+http://info.internet.isi.edu/in-notes/rfc/files/rfc2891.txt
=head1 AUTHOR
@@ -196,6 +200,6 @@ terms as Perl itself.
=for html <hr>
-I<$Id: Sort.pm,v 1.4 2000/07/30 21:03:50 gbarr Exp $>
+I<$Id: Sort.pm,v 1.5 2000/09/12 09:17:09 gbarr Exp $>
=cut
@@ -1,4 +1,4 @@
-# $Id: SortResult.pm,v 1.3 2000/07/30 21:03:50 gbarr Exp $
+# $Id: SortResult.pm,v 1.4 2000/09/12 09:17:10 gbarr Exp $
# Copyright (c) 1999-2000 Graham Barr <gbarr@pobox.com>. All rights reserved.
# This program is free software; you can redistribute it and/or
# modify it under the same terms as Perl itself.
@@ -52,7 +52,7 @@ __END__
=head1 NAME
-Net::LDAP::Control::SortResult - LDAPv3 sort result control object
+Net::LDAP::Control::SortResult - Server Side Sort (SSS) result control object
=head1 SYNOPSIS
@@ -85,12 +85,15 @@ Net::LDAP::Control::SortResult - LDAPv3 sort result control object
=head1 DESCRIPTION
-C<Net::LDAP::Control::SortResult> is a sub-class of L<Net::LDAP::Control|Net::LDAP::Control>.
-It provides a class for manipulating the LDAP sort request control C<1.2.840.113556.1.4.474>
+C<Net::LDAP::Control::SortResult> is a sub-class of
+L<Net::LDAP::Control|Net::LDAP::Control>. It provides a class for
+manipulating the LDAP sort request control C<1.2.840.113556.1.4.474>
+as defined in RFC-2891
-A sort result control will be returned by the server in response to a search with a sort
-control. If a sort result control is not returned then the user may assume that the
-server does not support sorting and the results are not sorted.
+A sort result control will be returned by the server in response to
+a search with a Server Side Sort control. If a sort result control is
+not returned then the user may assume that the server does not support
+sorting and the results are not sorted.
=head1 CONSTRUCTOR ARGUMENTS
@@ -152,7 +155,8 @@ a definition of each.
L<Net::LDAP|Net::LDAP>,
L<Net::LDAP::Control::Sort|Net::LDAP::Control::Sort>,
-L<Net::LDAP::Control|Net::LDAP::Control>
+L<Net::LDAP::Control|Net::LDAP::Control>,
+http://info.internet.isi.edu/in-notes/rfc/files/rfc2891.txt
=head1 AUTHOR
@@ -169,6 +173,6 @@ terms as Perl itself.
=for html <hr>
-I<$Id: SortResult.pm,v 1.3 2000/07/30 21:03:50 gbarr Exp $>
+I<$Id: SortResult.pm,v 1.4 2000/09/12 09:17:10 gbarr Exp $>
=cut
View
@@ -6,9 +6,10 @@ package Net::LDAP::Entry;
use strict;
use Net::LDAP::ASN qw(LDAPEntry);
+use Net::LDAP::Constant qw(LDAP_LOCAL_ERROR);
use vars qw($VERSION);
-$VERSION = "0.11";
+$VERSION = "0.12";
sub new {
my $self = shift;
@@ -52,13 +53,13 @@ sub dn {
sub get_attribute {
require Carp;
Carp::carp("->get_attribute depricated, use ->get_value") if $^W;
- shift->get_value(@_, asref => 1);
+ shift->get_value(@_, asref => !wantarray);
}
sub get {
require Carp;
Carp::carp("->get depricated, use ->get_value") if $^W;
- shift->get_value(@_, asref => 1);
+ shift->get_value(@_, asref => !wantarray);
}
@@ -209,9 +210,14 @@ sub update {
elsif ($self->{'changetype'} eq 'delete') {
$mesg = $ldap->delete($self, 'callback' => $cb);
}
- else {
+ elsif (defined $self->{'changes'}) {
$mesg = $ldap->modify($self, 'changes' => $self->{'changes'}, 'callback' => $cb);
}
+ else {
+ require Net::LDAP::Message;
+ $mesg = Net::LDAP::Message->new( {} );
+ $mesg->set_error(LDAP_LOCAL_ERROR,"No attributes to update");
+ }
return $mesg;
}
View
@@ -218,21 +218,21 @@ is called.
-=item update ( [ CLIENT ] )
+=item update ( CLIENT )
-Update the directory server with any changes that have been made
-locally. This means any calls that have been made to add, replace
-or delete since the last call to changetype or update was made.
+Update the directory server with any changes that have been made locally
+to the attributes of this entry. This means any calls that have been
+made to add, replace or delete since the last call to changetype or
+update was made.
-CLIENT should be a C<Net::LDAP> object where the update
-should be sent to.
+This method B<cannot> be used to modify the DN of the entry on the server,
+for that see the C<moddn> method in L<Net::LDAP|Net::LDAP>.
-CLIENT is only optional is the B<Net::LDAP::Entry> object was created
-by a search on a directory server. In which case, if omitted, the
-update will be sent back to the same server.
+CLIENT is a C<Net::LDAP> object where the update will be sent to.
-The result will be an object of type L<Net::LDAP::Message|Net::LDAP::Message> as returned
-by the add, modify or delete method called on CLIENT.
+The result will be an object of type
+L<Net::LDAP::Message|Net::LDAP::Message> as returned by the add, modify
+or delete method called on CLIENT.
=back
@@ -256,6 +256,6 @@ terms as Perl itself.
=for html <hr>
-I<$Id: Entry.pod,v 1.4 2000/08/16 11:07:34 gbarr Exp $>
+I<$Id: Entry.pod,v 1.5 2000/09/12 09:17:09 gbarr Exp $>
=cut
@@ -492,6 +492,12 @@ information about returned attributes.
foreach ( @attributes)
{
print "attributeType\n";
+
+ #
+ # Get and display the oid number of the objectclass.
+ #
+ $oid = $schema->name2oid( "$_" );
+
#
# Get the various items associated with
# this attribute.
@@ -544,7 +550,7 @@ All rights to this document are hereby relinquished to Graham Barr.
=for html <hr>
-I<$Id: Examples.pod,v 1.3 2000/08/16 11:07:34 gbarr Exp $>
+I<$Id: Examples.pod,v 1.4 2000/09/12 09:17:09 gbarr Exp $>
=cut
Oops, something went wrong.

0 comments on commit d041411

Please sign in to comment.