From 4130dc841ca68e16f5d97e89653fa49b16f4e793 Mon Sep 17 00:00:00 2001 From: Daniel White Date: Mon, 20 Oct 2014 08:43:40 +1100 Subject: eldap: Add support for modifying passwords This implements the LDAP Password Modify Extended Operation (RFC 3062) with two new functions modify_password/3 and modify_password/4. The former is for directly setting passwords, and the latter is for users to change their own passwords. Since all three parameters are optional, I've opted to support this with the empty string rather than a property list. This seems consistent with other functions in the module (i.e. modify_dn/5). --- lib/eldap/doc/src/eldap.xml | 40 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) (limited to 'lib/eldap/doc/src/eldap.xml') diff --git a/lib/eldap/doc/src/eldap.xml b/lib/eldap/doc/src/eldap.xml index dbd478fb17..d1a948437a 100644 --- a/lib/eldap/doc/src/eldap.xml +++ b/lib/eldap/doc/src/eldap.xml @@ -213,6 +213,46 @@ filter() See present/1, substrings/2, + + modify_password(Handle, Dn, NewPasswd) -> ok | {ok, GenPasswd} | {error, Reason} + Modify the password of a user. + + Dn = string() + NewPasswd = string() + + +

Modify the password of a user. See modify_password/4.

+
+
+ + modify_password(Handle, Dn, NewPasswd, OldPasswd) -> ok | {ok, GenPasswd} | {error, Reason} + Modify the password of a user. + + Dn = string() + NewPasswd = string() + OldPasswd = string() + GenPasswd = string() + + +

Modify the password of a user.

+ + +

Dn. The user to modify. Should be "" if the + modify request is for the user of the LDAP session.

+
+ +

NewPasswd. The new password to set. Should be "" + if the server is to generate the password. In this case, + the result will be {ok, GenPasswd}.

+
+ +

OldPasswd. Sometimes required by server policy + for a user to change their password. If not required, use + modify_password/3.

+
+
+
+
modify_dn(Handle, Dn, NewRDN, DeleteOldRDN, NewSupDN) -> ok | {error, Reason} Modify the DN of an entry. -- cgit v1.2.3 From 0a4ef21233b03a551e06798f763b4b817d973d1c Mon Sep 17 00:00:00 2001 From: jeffweiss Date: Sat, 9 May 2015 00:17:51 -0700 Subject: Correct module in eldap timeout docs Prior to this commit, the `eldap` documentation for the timeouts of `search/2` and `start_tls/3` referenced `erl_tar:open/2` instead of `eldap:open/2`. The relative link was correct, only the link label mistakenly pointed to `erl_tar`. This error was introduced in e9a97c3cfd7615e3efd0cbf1632a78b868fda49c. This commit corrects that mistake. --- lib/eldap/doc/src/eldap.xml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib/eldap/doc/src/eldap.xml') diff --git a/lib/eldap/doc/src/eldap.xml b/lib/eldap/doc/src/eldap.xml index 945379d5d2..fbeb4540b7 100644 --- a/lib/eldap/doc/src/eldap.xml +++ b/lib/eldap/doc/src/eldap.xml @@ -121,7 +121,7 @@ filter() See present/1, substrings/2, Any error responded from ssl:connect/3

The Timeout parameter is for the actual tls upgrade (phase 2) while the timeout in - erl_tar:open/2 is used for the initial negotiation about + eldap:open/2 is used for the initial negotiation about upgrade (phase 1).

@@ -258,7 +258,7 @@ filter() See present/1, substrings/2, search(Handle, [{base, "dc=example, dc=com"}, {filter, Filter}, {attributes, ["cn"]}]),

The timeout option in the SearchOptions is for the ldap server, while - the timeout in erl_tar:open/2 is used for each + the timeout in eldap:open/2 is used for each individual request in the search operation.

-- cgit v1.2.3 From 05efdc8e2db3d7d3d845166424d71e4b061049e5 Mon Sep 17 00:00:00 2001 From: Hans Nilsson Date: Mon, 11 May 2015 13:33:39 +0200 Subject: eldap: Remove doc man.3 warning --- lib/eldap/doc/src/eldap.xml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'lib/eldap/doc/src/eldap.xml') diff --git a/lib/eldap/doc/src/eldap.xml b/lib/eldap/doc/src/eldap.xml index ed35ee3a9c..a6fad8a857 100644 --- a/lib/eldap/doc/src/eldap.xml +++ b/lib/eldap/doc/src/eldap.xml @@ -403,7 +403,11 @@ filter() See present/1, substrings/2, OptionalAttrs = [Attr] Attr = {matchingRule,string()} | {type,string()} | {dnAttributes,boolean()} -

Creates an extensible match filter. For example, eldap:extensibleMatch("Bar",[{type,"sn"},{matchingRule,"caseExactMatch"}])) creates a filter which performs a caseExactMatch on the attribute sn and matches with the value "Bar". The default value of dnAttributes is false.

+

Creates an extensible match filter. For example,

+ + eldap:extensibleMatch("Bar", [{type,"sn"}, {matchingRule,"caseExactMatch"}])) + +

creates a filter which performs a caseExactMatch on the attribute sn and matches with the value "Bar". The default value of dnAttributes is false.

'and'([Filter]) -> filter() -- cgit v1.2.3 From 738c34d4bb8f1a3811acd00af8c6c12107f8315b Mon Sep 17 00:00:00 2001 From: Bruce Yinhe Date: Thu, 18 Jun 2015 11:31:02 +0200 Subject: Change license text to APLv2 --- lib/eldap/doc/src/eldap.xml | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) (limited to 'lib/eldap/doc/src/eldap.xml') diff --git a/lib/eldap/doc/src/eldap.xml b/lib/eldap/doc/src/eldap.xml index 253ba7c2ff..8f4479a730 100644 --- a/lib/eldap/doc/src/eldap.xml +++ b/lib/eldap/doc/src/eldap.xml @@ -8,16 +8,17 @@ Ericsson AB. All Rights Reserved. - The contents of this file are subject to the Erlang Public License, - Version 1.1, (the "License"); you may not use this file except in - compliance with the License. You should have received a copy of the - Erlang Public License along with this software. If not, it can be - retrieved online at http://www.erlang.org/. + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 - Software distributed under the License is distributed on an "AS IS" - basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See - the License for the specific language governing rights and limitations - under the License. + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. -- cgit v1.2.3