directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From elecha...@apache.org
Subject svn commit: r1403764 - in /directory/site/trunk/content/apacheds/basic-ug: ./ images/ resources/
Date Tue, 30 Oct 2012 16:16:56 GMT
Author: elecharny
Date: Tue Oct 30 16:16:55 2012
New Revision: 1403764

URL: http://svn.apache.org/viewvc?rev=1403764&view=rev
Log:
Added the 2.1.2-deleting-entries page, removed two pages we won't use, fixing some links

Added:
    directory/site/trunk/content/apacheds/basic-ug/images/delete-entry.png   (with props)
    directory/site/trunk/content/apacheds/basic-ug/images/import-entry-studio.png   (with
props)
    directory/site/trunk/content/apacheds/basic-ug/images/keystore-configuration.png   (with
props)
    directory/site/trunk/content/apacheds/basic-ug/images/ldif-import-file-select.png   (with
props)
    directory/site/trunk/content/apacheds/basic-ug/resources/captain-hook-hierarchy.ldif
Removed:
    directory/site/trunk/content/apacheds/basic-ug/2.1.3-modifying-entries.mdtext
    directory/site/trunk/content/apacheds/basic-ug/2.1.4-moving-entries.mdtext
Modified:
    directory/site/trunk/content/apacheds/basic-ug/1.4.3-adding-partition.mdtext
    directory/site/trunk/content/apacheds/basic-ug/2.1-data-modification.mdtext
    directory/site/trunk/content/apacheds/basic-ug/2.1.1-adding-entries.mdtext
    directory/site/trunk/content/apacheds/basic-ug/2.1.2-deleting-entries.mdtext
    directory/site/trunk/content/apacheds/basic-ug/3.1-authentication-options.mdtext
    directory/site/trunk/content/apacheds/basic-ug/3.3-enabling-ssl.mdtext

Modified: directory/site/trunk/content/apacheds/basic-ug/1.4.3-adding-partition.mdtext
URL: http://svn.apache.org/viewvc/directory/site/trunk/content/apacheds/basic-ug/1.4.3-adding-partition.mdtext?rev=1403764&r1=1403763&r2=1403764&view=diff
==============================================================================
--- directory/site/trunk/content/apacheds/basic-ug/1.4.3-adding-partition.mdtext (original)
+++ directory/site/trunk/content/apacheds/basic-ug/1.4.3-adding-partition.mdtext Tue Oct 30
16:16:55 2012
@@ -82,6 +82,7 @@ The same o=sevenseas partition can be cr
 
 Here is the sample code to create a new partition o=sevenseas and its context entry programmatically
 
+	:::java
 	// Get the SchemaManager, we need it for this addition
 	SchemaManager schemaManager = directoryService.getSchemaManager();
 	

Modified: directory/site/trunk/content/apacheds/basic-ug/2.1-data-modification.mdtext
URL: http://svn.apache.org/viewvc/directory/site/trunk/content/apacheds/basic-ug/2.1-data-modification.mdtext?rev=1403764&r1=1403763&r2=1403764&view=diff
==============================================================================
--- directory/site/trunk/content/apacheds/basic-ug/2.1-data-modification.mdtext (original)
+++ directory/site/trunk/content/apacheds/basic-ug/2.1-data-modification.mdtext Tue Oct 30
16:16:55 2012
@@ -24,11 +24,19 @@ Notice: Licensed to the Apache Software 
 
 # 2.1 - Data modification
 
-TODO
+We will first expose the way you inject entries in _Apache Directory Server_. There are four
type of operations you can use for that :
+* Addition
+* Deletion
+* Modification
+* Move and/or rename
+
+(The last operation allows a user to move, rename or move and rename entries).
+
+We will show how to add or delete entries in the following chapters, just to show you how
it works with _Apache Directory Server_. There is nothing really different with any other
servers.
+
+For further information about data modifications, you should either check the [Apache LDAP
API documentation](../../api/index.html) documentation, or the [Apache Directory Studio documentation](../../studio/users-guide.html).
 
 ## Table of content
 
 * [2.1.1 - Adding Entries](2.1.1-adding-entries.html)
 * [2.1.2 - Deleting Entries](2.1.2-deleting-entries.html)
-* [2.1.3 - Modifying Entries](2.1.3-modifying-entries.html)
-* [2.1.4 - Moving Entries](2.1.4-moving-entries.html)

Modified: directory/site/trunk/content/apacheds/basic-ug/2.1.1-adding-entries.mdtext
URL: http://svn.apache.org/viewvc/directory/site/trunk/content/apacheds/basic-ug/2.1.1-adding-entries.mdtext?rev=1403764&r1=1403763&r2=1403764&view=diff
==============================================================================
--- directory/site/trunk/content/apacheds/basic-ug/2.1.1-adding-entries.mdtext (original)
+++ directory/site/trunk/content/apacheds/basic-ug/2.1.1-adding-entries.mdtext Tue Oct 30
16:16:55 2012
@@ -24,4 +24,82 @@ Notice: Licensed to the Apache Software 
 
 # 2.1.1 - Adding Entries
 
-TODO
\ No newline at end of file
+We will see how to add new entries into the server. Assuming that we have already created
a partition (see [Adding a partition](1.4.3-adding-partition.html)), we will use this added
partition as a root for the entry addition. We will also create the _ou=people_ entry.
+
+We try to add a new user to the "Seven Seas" partition. The data for the entry is inspired
by "Peter Pan" and provided by this LDIF file ([Captain hook](resources/captain-hook-hierarchy.ldif)):

+
+	# File captain_hook.ldif
+	dn: ou=people,o=sevenSeas
+	objectclass: organizationalUnit
+	objectclass: top
+	ou: people
+
+	dn: cn=James Hook,ou=people,o=sevenSeas
+	objectclass: inetOrgPerson
+	objectclass: organizationalPerson
+	objectclass: person
+	objectclass: top
+	cn: James Hook
+	description: A pirate captain and Peter Pan's nemesis
+	sn: Hook
+	mail: jhook@neverland
+	userpassword: peterPan
+	
+The first entry creates the _ou=people_ container, which is necessary otherwise we can't
inject the second entry.
+
+## Using the command line
+
+You have to use an authorized user to inject the entry, here, _cn=Horatio Nelson,ou=people,o=sevenSeas_
:
+
+	$ ldapmodify -h zanzibar -p 10389 -D "cn=Horatio Nelson,ou=people,o=sevenSeas" -w pass \\
+    	-a -f captain_hook.ldif
+	adding new entry cn=James Hook,ou=people,o=sevenSeas
+	$
+
+Afterwards a new entry is successfully created within the "Seven Seas" partition by user
"Horatio Nelson". The '+' sign in the attributes list of the _ldapsearch_ command causes ApacheDS
to return the operational attributes, which demonstrate this.
+
+	$ ldapsearch -h zanzibar -p 10389 -b "o=sevenSeas" -s sub "(cn=James Hook)" +
+	version: 1
+	dn: cn=James Hook,ou=people,o=sevenSeas
+	accessControlSubentries: cn=sevenSeasAuthorizationRequirementsACISubentry,o=sevenSeas
+	creatorsName: cn=Horatio Nelson,ou=people,o=sevenSeas
+	createTimestamp: 20061203140109Z
+
+## Using Apache Directory Studio
+
+Once connected on the server with studio, you should be able to inject new entries -assuming
you have the sufficent priviledge - :
+
+![Import entry with studio](images/import-entry-studio.png)
+
+Then select the LDIF file containing the entry :
+
+![LDIF import](ldif-import-file-select.png)
+
+When imported, the _log_ windows should contain this message :
+
+	:::
+    #!RESULT OK
+	#!CONNECTION ldap://localhost:10389
+	#!DATE 2012-10-30T14:36:21.294
+	dn: ou=people,o=sevenSeas
+	changetype: add
+	ou: people
+	objectclass: organizationalUnit
+	objectclass: top
+
+	#! RESULT OK
+	#! CONNECTION ldap://localhost:10389
+	#! DATE 2012-10-30T14:36:21.320
+	dn: cn=James Hook,ou=people,o=sevenSeas
+	changetype: add
+	mail: jhook@neverland
+	userpassword: peterPan
+	description: A pirate captain and Peter Pan's nemesis
+	objectclass: inetOrgPerson
+	objectclass: organizationalPerson
+	objectclass: person
+	objectclass: top
+	sn: Hook
+	cn: James Hook
+
+This is it for this basic introduction on how to add entries in the server. There are other
ways, like using and LDAP API, to do the same thing.
\ No newline at end of file

Modified: directory/site/trunk/content/apacheds/basic-ug/2.1.2-deleting-entries.mdtext
URL: http://svn.apache.org/viewvc/directory/site/trunk/content/apacheds/basic-ug/2.1.2-deleting-entries.mdtext?rev=1403764&r1=1403763&r2=1403764&view=diff
==============================================================================
--- directory/site/trunk/content/apacheds/basic-ug/2.1.2-deleting-entries.mdtext (original)
+++ directory/site/trunk/content/apacheds/basic-ug/2.1.2-deleting-entries.mdtext Tue Oct 30
16:16:55 2012
@@ -3,8 +3,8 @@ NavPrev: 2.1.1-adding-entries.html
 NavPrevText: 2.1.1 - Adding Entries
 NavUp: 2.1-data-modification.html
 NavUpText: 2.1 - Data modification
-NavNext: 2.1.3-modifying-entries.html
-NavNextText: 2.1.3 - Modifying Entries
+NavNext: 2.2-searching-data.html
+NavNextText: 2.2 - Searching Data
 Notice: Licensed to the Apache Software Foundation (ASF) under one
     or more contributor license agreements.  See the NOTICE file
     distributed with this work for additional information
@@ -24,4 +24,45 @@ Notice: Licensed to the Apache Software 
 
 # 2.1.2 - Deleting Entries
 
-TODO
\ No newline at end of file
+Deleting entries is quite simple : you just need to provide their _DN_, and require for the
deletion of the associated entry. Although there are a few conditions that must be fulfilled
for this operatio to be successful :
+* The entry must exist;
+* It should not have any children;
+* The user requiring the deletion must have enough priviledge to do so
+
+Assuming those three conditions being fulfilled, you can proceed with the deletion. We will
show how it works on the entry we added in the previous chapter.
+
+
+## Using the command line
+
+You have to use an authorized user to delete the entry, here, _cn=Horatio Nelson,ou=people,o=sevenSeas_
:
+
+With an LDIF file ([Captain hook delete](resources/captain-hook-delete.ldif)) with an appropriate
change entry, this can easily be accomplished, if the bind user is allowed to do so. Here
is the content of this _LDIF_ file :
+
+	# File captain_hook_delete.ldif
+	dn: cn=James Hook,ou=people,o=sevenSeas
+	changetype: delete
+
+and here is the command line to use :
+
+	$ ldapdel -h zanzibar -p 10389 -D "cn=Horatio Nelson,ou=people,o=sevenSeas" -w pass \\
+    	-a -f captain_hook.ldif
+	adding new entry cn=James Hook,ou=people,o=sevenSeas
+	$
+
+
+## Using Apache Directory Studio
+
+With studio, just select the entry you want to delete, and select the "Delete" menu :
+
+![Delete entry with studio](images/delete-entry.png)
+
+When deleteed, the _log_ windows should contain this message :
+
+	:::
+	#!RESULT OK
+	#!CONNECTION ldap://localhost:10389
+	#!DATE 2012-10-30T14:57:47.399
+	dn: cn=James Hook,ou=people,o=SevenSeans,dc=com
+	changetype: delete
+
+Studio allows you to delete entries which have children, but it will first try to delete
all the children recursively. There is no such things when you send an LDAP _DeleteRequest_.
\ No newline at end of file

Modified: directory/site/trunk/content/apacheds/basic-ug/3.1-authentication-options.mdtext
URL: http://svn.apache.org/viewvc/directory/site/trunk/content/apacheds/basic-ug/3.1-authentication-options.mdtext?rev=1403764&r1=1403763&r2=1403764&view=diff
==============================================================================
--- directory/site/trunk/content/apacheds/basic-ug/3.1-authentication-options.mdtext (original)
+++ directory/site/trunk/content/apacheds/basic-ug/3.1-authentication-options.mdtext Tue Oct
30 16:16:55 2012
@@ -76,6 +76,7 @@ If the user provides the correct passwor
 
 Using JNDI, authentication via simple binds is accomplished by appropriate configuration.
One option is to provide the parameters in a Hashtable object like this
 
+	:::java
 	import java.util.Hashtable;
 	
 	import javax.naming.Context;
@@ -156,6 +157,7 @@ The value "{SHA}nU4eI71bcnBGqeO0t9tXvY1u
 
 With some lines of code, it is quite easy to accomplish this task programatically in Java:
 
+	:::java
 	import java.security.MessageDigest;
 	import java.security.NoSuchAlgorithmException;
 	import sun.misc.BASE64Encoder;
@@ -303,6 +305,7 @@ The algorithm described above is impleme
 
 For illustration purposes, here is a simple Java program which performs the steps with the
help of JNDI. It uses anonymous bind for the first step, hence it must be enabled (replace
with a technical user, if it better meets your requirements). 
 
+	:::java
 	import java.util.Hashtable;
 	import javax.naming.Context;
 	import javax.naming.NamingEnumeration;

Modified: directory/site/trunk/content/apacheds/basic-ug/3.3-enabling-ssl.mdtext
URL: http://svn.apache.org/viewvc/directory/site/trunk/content/apacheds/basic-ug/3.3-enabling-ssl.mdtext?rev=1403764&r1=1403763&r2=1403764&view=diff
==============================================================================
--- directory/site/trunk/content/apacheds/basic-ug/3.3-enabling-ssl.mdtext (original)
+++ directory/site/trunk/content/apacheds/basic-ug/3.3-enabling-ssl.mdtext Tue Oct 30 16:16:55
2012
@@ -154,9 +154,10 @@ Another option is to use graphical tools
 
 #### Configuring ApacheDS to use this external keystore
 
-Enabling SSL in Apache Directory Server and using the key pair created as above is quite
easy. Simply put the keystore file in the _conf_ directory of ApacheDS, and enable ldaps.

+Enabling SSL in Apache Directory Server and using the key pair created as above is quite
easy. Simply put the keystore file in the _conf_ directory of ApacheDS, and enable ldaps.
Then you just have to setup the configuration using _Apache Directory Studio_, feeling the
required input boxes, as shown on the following picture :
+
+![Keystore Configuration](images/keystore-configuration.png)
 
-TODO : Studio screen capture
 
 The following properties were used :
 

Added: directory/site/trunk/content/apacheds/basic-ug/images/delete-entry.png
URL: http://svn.apache.org/viewvc/directory/site/trunk/content/apacheds/basic-ug/images/delete-entry.png?rev=1403764&view=auto
==============================================================================
Binary file - no diff available.

Propchange: directory/site/trunk/content/apacheds/basic-ug/images/delete-entry.png
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: directory/site/trunk/content/apacheds/basic-ug/images/import-entry-studio.png
URL: http://svn.apache.org/viewvc/directory/site/trunk/content/apacheds/basic-ug/images/import-entry-studio.png?rev=1403764&view=auto
==============================================================================
Binary file - no diff available.

Propchange: directory/site/trunk/content/apacheds/basic-ug/images/import-entry-studio.png
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: directory/site/trunk/content/apacheds/basic-ug/images/keystore-configuration.png
URL: http://svn.apache.org/viewvc/directory/site/trunk/content/apacheds/basic-ug/images/keystore-configuration.png?rev=1403764&view=auto
==============================================================================
Binary file - no diff available.

Propchange: directory/site/trunk/content/apacheds/basic-ug/images/keystore-configuration.png
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: directory/site/trunk/content/apacheds/basic-ug/images/ldif-import-file-select.png
URL: http://svn.apache.org/viewvc/directory/site/trunk/content/apacheds/basic-ug/images/ldif-import-file-select.png?rev=1403764&view=auto
==============================================================================
Binary file - no diff available.

Propchange: directory/site/trunk/content/apacheds/basic-ug/images/ldif-import-file-select.png
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: directory/site/trunk/content/apacheds/basic-ug/resources/captain-hook-hierarchy.ldif
URL: http://svn.apache.org/viewvc/directory/site/trunk/content/apacheds/basic-ug/resources/captain-hook-hierarchy.ldif?rev=1403764&view=auto
==============================================================================
--- directory/site/trunk/content/apacheds/basic-ug/resources/captain-hook-hierarchy.ldif (added)
+++ directory/site/trunk/content/apacheds/basic-ug/resources/captain-hook-hierarchy.ldif Tue
Oct 30 16:16:55 2012
@@ -0,0 +1,15 @@
+dn: ou=people,o=sevenSeas
+objectclass: organizationalUnit
+objectclass: top
+ou: people
+
+dn: cn=James Hook,ou=people,o=sevenSeas
+objectclass: inetOrgPerson
+objectclass: organizationalPerson
+objectclass: person
+objectclass: top
+cn: James Hook
+description: A pirate captain and Peter Pan's nemesis
+sn: Hook
+mail: jhook@neverland
+userpassword: peterPan



Mime
View raw message